From 98f503a326e343326fa249f8baeceeb49be6915a Mon Sep 17 00:00:00 2001 From: Simon Pilgrim Date: Thu, 27 Sep 2018 12:28:47 +0000 Subject: [PATCH] [X86][Btver2] TZCNT instructions take 2uops not 1 llvm-svn: 343200 --- llvm/lib/Target/X86/X86ScheduleBtVer2.td | 2 +- llvm/test/tools/llvm-mca/X86/BtVer2/resources-bmi1.s | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/llvm/lib/Target/X86/X86ScheduleBtVer2.td b/llvm/lib/Target/X86/X86ScheduleBtVer2.td index d4edbc4046f6..450b18fc5830 100644 --- a/llvm/lib/Target/X86/X86ScheduleBtVer2.td +++ b/llvm/lib/Target/X86/X86ScheduleBtVer2.td @@ -210,7 +210,7 @@ defm : JWriteResIntPair; defm : JWriteResIntPair; defm : JWriteResIntPair; defm : JWriteResIntPair; -defm : JWriteResIntPair; +defm : JWriteResIntPair; // BMI1 BEXTR/BLS, BMI2 BZHI defm : JWriteResIntPair; diff --git a/llvm/test/tools/llvm-mca/X86/BtVer2/resources-bmi1.s b/llvm/test/tools/llvm-mca/X86/BtVer2/resources-bmi1.s index 4d9cdcf7c1cc..54db08b810ca 100644 --- a/llvm/test/tools/llvm-mca/X86/BtVer2/resources-bmi1.s +++ b/llvm/test/tools/llvm-mca/X86/BtVer2/resources-bmi1.s @@ -66,10 +66,10 @@ tzcnt (%rax), %rcx # CHECK-NEXT: 1 5 1.00 * blsrl (%rax), %ecx # CHECK-NEXT: 1 2 1.00 blsrq %rax, %rcx # CHECK-NEXT: 1 5 1.00 * blsrq (%rax), %rcx -# CHECK-NEXT: 1 2 1.00 tzcntl %eax, %ecx -# CHECK-NEXT: 1 5 1.00 * tzcntl (%rax), %ecx -# CHECK-NEXT: 1 2 1.00 tzcntq %rax, %rcx -# CHECK-NEXT: 1 5 1.00 * tzcntq (%rax), %rcx +# CHECK-NEXT: 2 2 1.00 tzcntl %eax, %ecx +# CHECK-NEXT: 2 5 1.00 * tzcntl (%rax), %ecx +# CHECK-NEXT: 2 2 1.00 tzcntq %rax, %rcx +# CHECK-NEXT: 2 5 1.00 * tzcntq (%rax), %rcx # CHECK: Resources: # CHECK-NEXT: [0] - JALU0