https://bugs.llvm.org/show_bug.cgi?id=41982
Bug ID: 41982
Summary: llvm-mca does not understand x86 zeroing idioms
Product: tools
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: llvm-mca
Assignee: unassignedb...@nondot.org
Reporter: brennan.vinc...@gmail.com
CC: andrea.dibia...@gmail.com, llvm-bugs@lists.llvm.org,
matthew.da...@sony.com
This seems similar: https://bugs.llvm.org/show_bug.cgi?id=36671
It was marked fixed, but llvm-mca is still not recognizing xor as a zeroing
idiom in this simple test case. Note that the second `divl` has to wait for the
first to finish, despite the outputs being zeroed.
```
~ ❯❯❯ cat asm.s
xorl %eax, %eax
xorl %edx, %edx
divl %edi
~ ❯❯❯ ~/clangmr/bin/llvm-mca -timeline -timeline-max-cycles=200 ~/asm.s
✘ 130
<snip>
Timeline view:
0123456789 0123456789 0123456789
0123456789 0123456789 0123456789 0123456789
0123456789
Index 0123456789 0123456789 0123456789
0123456789 0123456789 0123456789 0123456789
0123456789 01
[0,0] DeER . . . . . . . . . . . . .
. . . . . . . . . . . . . . . .
. . .. xorl %eax, %eax
[0,1] DeER . . . . . . . . . . . . .
. . . . . . . . . . . . . . . .
. . .. xorl %edx, %edx
[0,2]
.DeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeER.
. . . . . . . . . . . . . . .
.. divl %edi
[1,0] .
.D=======================================================================eER
. . . . . . . . . . . . . . . ..
xorl %eax, %eax
[1,1] .
.D=======================================================================eER
. . . . . . . . . . . . . . . ..
xorl %edx, %edx
[1,2] . .
D=======================================================================eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeER
.. divl %edi
[2,0] . . .
D==============================================================================================================================================eER
.. xorl %eax, %eax
[2,1] . . .
D==============================================================================================================================================eER
.. xorl %edx, %edx
```
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs