Quantcast
Channel: Active questions tagged gcc - Stack Overflow
Viewing all articles
Browse latest Browse all 22259

gcc -O3 optimize :: xmm0 register?

$
0
0

I was writing a vsprintf function to use my 64-bit OS kernel (written by C), and checked that it works well in Visual Studio and Cygwin gcc.Then, I put to my kernel and run... but kernel doesn't works well

I debugged and figured out the problem: vsprintf contains next assembly code

movdqa xmm0,XMMWORD PTR [rip+0x0]

The real problem is that I NEVER use floating point!

I guess that was gcc's optimization, and It seems to be correct because It works well without optimization.

Is there any solution, so to speak, gcc option that disable optimization with xmm registers?


Viewing all articles
Browse latest Browse all 22259

Trending Articles



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