[Bug tree-optimization/50849] New: long long right shift not vectorized
vincenzo.innocente at cern dot ch
gcc-bugzilla@gcc.gnu.org
Mon Oct 24 10:32:00 GMT 2011
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50849
Bug #: 50849
Summary: long long right shift not vectorized
Classification: Unclassified
Product: gcc
Version: 4.7.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: vincenzo.innocente@cern.ch
Any reason why left shift is vectorized and right shift not?
long long l1[1024], l2[1024];
void sl() {
for (int i=0;i!=1024;++i)
l1[i] = l2[i]<<52;
}
void rl() {
for (int i=0;i!=1024;++i)
l1[i] = l2[i]>>52;
}
sl():
leaq _l1(%rip),%rcx
xorl %eax,%eax
leaq _l2(%rip),%rdx
movdqa (%rdx,%rax),%xmm0
psllq $0x34,%xmm0
movdqa %xmm0,(%rcx,%rax)
addq $0x10,%rax
cmpq $0x00002000,%eax
jne 0x00000010
repz/ret
nopl (%rax)
rl():
leaq _l1(%rip),%rsi
xorl %eax,%eax
leaq _l2(%rip),%rcx
movq (%rcx,%rax),%rdx
sarq $0x34,%rdx
movq %rdx,(%rsi,%rax)
addq $0x08,%rax
cmpq $0x00002000,%eax
jne 0x00000040
repz/ret
More information about the Gcc-bugs
mailing list