This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/17127] -fexpensive-optimizations causes output of wrong code


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-08-20 21:37 -------
No what you telling the compiler that the inline-asm only does one byte memory store but really you 
are doing more (8 bytes) which is what the problem so this is invalid.

Try the following (which works for me):
		asm volatile(
			"movq %[input],%%mm0  \n"
			"movq %%mm0,%[output] \n"
			"emms                  \n"
			:[output]"=m"(*(long long *)output):[input]"m"(*(long long *)input):"mm0", "cc"
		);

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |INVALID


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17127


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]