News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

lost variable

Started by dusty, February 27, 2013, 02:11:37 AM

Previous topic - Next topic

dusty

c++ function = void tryme(struct * astruct, char * cpnt, char* cdesc, double d1, double d2, double d3)

astruct is in rcx
cpnt is in rdx
cdest is in R8

but

d1 is in xmm3
d2 is in xmm0
what the heck happened to d3 ?

I looked in my pockets and under the bed  ::)


qWord

assuming M$ FASTCALL, only the first 4 arguments are passed in registers. Therefore d2 is passed on the stack and xmm0 "accidentally" contain that value (probably it was used to store/copy the value). d1 is placed as 4. FP argument in xmm3.
MREAL macros - when you need floating point arithmetic while assembling!