[PATCH] D32352: Go to eleven

Lama via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 27 01:41:33 PDT 2017


lsaba added inline comments.


================
Comment at: test/CodeGen/X86/mul-constant-i64.ll:1872
+; HSW-NOOPT:       # BB#0:
+; HSW-NOOPT-NEXT:    leaq 42(%rdi,%rdi,8), %rcx # sched: [1:0.50]
+; HSW-NOOPT-NEXT:    leaq 2(%rdi,%rdi,4), %rax # sched: [1:0.50]
----------------
zvi wrote:
> Thanks for adding this test-case. Now that there is a case where 3-operand LEA's are selected,
> @lsaba: which of the following is fastest?
> 1. 2 x (3-op LEA) + 1 x imul
> 2. 3 x imul + 2 x add
> 3. 2 x (2-op LEA) + 2 x add + 1 imul
> 
> Will D32277 change this case from 1. to 3.?
latency wise and generally speaking, the third option is the fastest, the second option is the slowest.
D32277 will change case 1 to 3, but there will be increase in code size


https://reviews.llvm.org/D32352





More information about the llvm-commits mailing list