llvm-project/llvm/test/CodeGen/X86/pr22473.ll

23 lines
666 B
LLVM
Raw Normal View History

; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
; RUN: llc < %s -mtriple=i686-unknown | FileCheck %s --check-prefixes=X86
; RUN: llc < %s -mtriple=x86_64-unknown | FileCheck %s --check-prefixes=X64
define zeroext i1 @PR22473(i8*, i8) {
; X86-LABEL: PR22473:
; X86: # %bb.0:
; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
; X86-NEXT: movb (%eax), %al
; X86-NEXT: cmpb {{[0-9]+}}(%esp), %al
; X86-NEXT: sete %al
; X86-NEXT: retl
;
; X64-LABEL: PR22473:
; X64: # %bb.0:
; X64-NEXT: cmpb %sil, (%rdi)
; X64-NEXT: sete %al
; X64-NEXT: retq
%3 = load i8, i8* %0, align 1
%4 = icmp eq i8 %3, %1
ret i1 %4
}