[Bug target/40537] wrong instr. dependency with some SSE intrinsics

2009-06-25 Thread ubizjak at gmail dot com
--- Comment #9 from ubizjak at gmail dot com 2009-06-25 09:03 --- *** This bug has been marked as a duplicate of 21920 *** -- ubizjak at gmail dot com changed: What|Removed |Added --

[Bug target/40537] wrong instr. dependency with some SSE intrinsics

2009-06-24 Thread hjl dot tools at gmail dot com
--- Comment #8 from hjl dot tools at gmail dot com 2009-06-24 13:09 --- (In reply to comment #6) > _mm_load_sd( (const doubleA*)(from) ) > > does not work because the prototype of _mm_load_sd does not have a type > with the may-alias attribute, so it gets stripped again. > I think mov

[Bug target/40537] wrong instr. dependency with some SSE intrinsics

2009-06-24 Thread ubizjak at gmail dot com
--- Comment #7 from ubizjak at gmail dot com 2009-06-24 11:57 --- Adding x86 intrinsic expert... -- ubizjak at gmail dot com changed: What|Removed |Added

[Bug target/40537] wrong instr. dependency with some SSE intrinsics

2009-06-24 Thread rguenth at gcc dot gnu dot org
--- Comment #6 from rguenth at gcc dot gnu dot org 2009-06-24 11:25 --- _mm_load_sd( (const doubleA*)(from) ) does not work because the prototype of _mm_load_sd does not have a type with the may-alias attribute, so it gets stripped again. -- http://gcc.gnu.org/bugzilla/show_bug.cgi

[Bug target/40537] wrong instr. dependency with some SSE intrinsics

2009-06-24 Thread rguenth at gcc dot gnu dot org
--- Comment #5 from rguenth at gcc dot gnu dot org 2009-06-24 11:23 --- There are aliasing issues with your code / the intrinsics implementation: float data[4] = {1, 2, 3, 4}; ... r = _mm_castpd_ps(_mm_load_sd((double*)(from))); ends up loading from float data via a pointer to doub

[Bug target/40537] wrong instr. dependency with some SSE intrinsics

2009-06-24 Thread gael dot guennebaud at gmail dot com
--- Comment #4 from gael dot guennebaud at gmail dot com 2009-06-24 11:12 --- some additional info: - compiling with -fno-strict-aliasing fix the issue, so perhaps this is not a real bug but a feature ? - on the other hand using the may_alias type attribute for casting does not help:

[Bug target/40537] wrong instr. dependency with some SSE intrinsics

2009-06-24 Thread gael dot guennebaud at gmail dot com
--- Comment #3 from gael dot guennebaud at gmail dot com 2009-06-24 10:53 --- There is a compilable example attached to comment #1. Furthermore, I can reproduce the problem with gcc 4.1.3, 4.2.4, 4.3.2, and 4.4.0, so I don't think it is a duplicate of PR40141. FYI, in the meantime I

[Bug target/40537] wrong instr. dependency with some SSE intrinsics

2009-06-24 Thread rguenth at gcc dot gnu dot org
--- Comment #2 from rguenth at gcc dot gnu dot org 2009-06-24 09:48 --- I can't verify it (you do not provide complete source that can be compiled), but I think this is a duplicate of PR40141 which is fixed in GCC 4.4. -- rguenth at gcc dot gnu dot org changed: What|R

[Bug target/40537] wrong instr. dependency with some SSE intrinsics

2009-06-24 Thread gael dot guennebaud at gmail dot com
--- Comment #1 from gael dot guennebaud at gmail dot com 2009-06-24 08:07 --- Created an attachment (id=18055) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=18055&action=view) a complete example showing the problem usage: Works: g++ -O3 instr_dependency.cpp -o instr_dependency