https://llvm.org/bugs/show_bug.cgi?id=23100
Bug ID: 23100
Summary: Suboptimal encoding of 64 bit and with small immediate
Product: libraries
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: Backend: X86
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected]
Classification: Unclassified
$ cat t.c
long long foo(long long x) { return x & 42; }
$ clang -S -o - t.c -O3|grep and|llvm-mc -show-encoding
andq $42, %rdi # encoding: [0x48,0x83,0xe7,0x2a]
$ gcc -S -o - t.c -O3|grep and|llvm-mc -show-encoding
andl $42, %eax # encoding: [0x83,0xe0,0x2a]
We have a pattern for this in X86InstrCompiler.td but it's not getting selected
for some reason.
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs