llvm.org GIT mirror llvm / release_35 test / CodeGen / X86 / simple-zext.ll

Tree @release_35 (Download .tar.gz)

simple-zext.ll @release_35raw · history · blame

; RUN: llc -mtriple=x86_64-apple-darwin < %s| FileCheck %s

; A bug in DAGCombiner prevented it forming a zextload in this simple case
; because it counted both the chain user and the real user against the
; profitability total.

define void @load_zext(i32* nocapture %p){
  %0 = load i32* %p, align 4
  %and = and i32 %0, 255
  tail call void @use(i32 %and)
  ret void
; CHECK: movzbl ({{%r[a-z]+}}), {{%e[a-z]+}}

declare void @use(i32)