c++ - Sign extension on x64 assembly dword -


i'm doing programming x64 assembly using masm in vs2013. know when provide integer assembly procedure (defined extern "c" in c++) integer goes rcx register. in case, integer 32 bits, size of dword. thing i'm not sure if compiler performs sign extension when placing dword rcx or 0 extension (zero'ing upper 32 bits , losing sign of dword). if can confirm compiler in instance (since cannot manually use movsxd , preserve sign myself) appreciated.

32bit integers passed in 32bit part of register (ecx etc), meaning upper half zeroed. doesn't matter, sign not lost, it's not uselessly copied 32 high bits. if work 32bit part of register (which normal when operating on 32bit data), should be. when upcasting 64bit need sign extension.


Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

Rendering JButton to get the JCheckBox behavior in a JTable by using images does not update my table -