![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Game engine designer
Join Date: May 2005
Location: Sweden
Posts: 301
Rep Power: 4
![]() |
[x86]How to use fsqrt
Where shall I put the value I want to apply the fsqrt instruction on?
int main()
{
float x = 2.0f;
_asm
{
mov eax, x
fsqrt ; Which register does this one use?
mov x, eax ; Where is the answear put? eax?
}
std::cout << x;
return 0;
}As you might guess I want the program to print 1.4142... But how? /Klarre |
|
|
|
|
|
#2 |
|
Game engine designer
Join Date: May 2005
Location: Sweden
Posts: 301
Rep Power: 4
![]() |
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|