
The first commit is identical to 69bec0afbb8f2aa0021d18ea38768360b16583a9. The second commit fixes the instruction verification failures by replacing the erroneous instruction with a trap after the error is reported and adds `-verify-machineinstrs` to the tests added in the original PR to catch the issue sooner. After that change, all tests pass with both `LLVM_ENABLE_EXPENSIVE_CHECKS={On,Off}`. cc @RKSimon @e-kud @phoebewang @arsenm as reviewers on the original PR
24 lines
965 B
LLVM
24 lines
965 B
LLVM
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --no_x86_scrub_sp --version 4
|
|
; RUN: llc -O0 -mtriple=x86_64 -mattr=+avx512f -verify-machineinstrs < %s | FileCheck %s --check-prefix=CHECK
|
|
define void @f(i16 %LGV2, i1 %LGV3) {
|
|
; CHECK-LABEL: f:
|
|
; CHECK: # %bb.0: # %BB
|
|
; CHECK-NEXT: subq $2147483528, %rsp # imm = 0x7FFFFF88
|
|
; CHECK-NEXT: .cfi_def_cfa_offset 2147483536
|
|
; CHECK-NEXT: movb %sil, %cl
|
|
; CHECK-NEXT: movw %di, %ax
|
|
; CHECK-NEXT: movswq %ax, %rax
|
|
; CHECK-NEXT: andb $1, %cl
|
|
; CHECK-NEXT: movabsq $-2147483768, %rdx # imm = 0xFFFFFFFF7FFFFF88
|
|
; CHECK-NEXT: movb %cl, (%rsp,%rdx)
|
|
; CHECK-NEXT: addq $2147483528, %rsp # imm = 0x7FFFFF88
|
|
; CHECK-NEXT: .cfi_def_cfa_offset 8
|
|
; CHECK-NEXT: retq
|
|
BB:
|
|
%A = alloca i1, i33 2147483648, align 1
|
|
%G = getelementptr i1, ptr %A, i16 %LGV2
|
|
%G4 = getelementptr i1, ptr %G, i32 -2147483648
|
|
store i1 %LGV3, ptr %G4, align 1
|
|
ret void
|
|
}
|