Quantcast
Channel: GameDev.net
Viewing all articles
Browse latest Browse all 16874

bits as float - "MOVD xmm0, eax" and MSVC nonsense

$
0
0

While checking out something'n'other via compiler explorer i noticed that MSVC does

mov [temp], eax
movss xmm0, [temp]

… instead of just …

movd xmm0, eax

Won't really matter performance wise for me, but still - is there some way to stop MSVC from being an absolute idiot and do the sane thing like every other darn compiler i can find? _castu32_f32 seems to be perfect fit - but is not available in MSVC. Is there something else that could work?

--------------------------------------------

Thought about it a bit more before pressing "post" … and got an idea to solve it. Hm, why not include …


Viewing all articles
Browse latest Browse all 16874

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>