mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
Fixes a bug in the DAGCombiner. LoadSDNodes have two values (data, chain).
If there is a store after the load node, then there is a chain, which means that there is another user. Thus, asking hasOneUser would fail. Instead we ask hasNUsesOfValue on the 'data' value. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131183 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
13
test/CodeGen/X86/2011-05-09-loaduse.ll
Normal file
13
test/CodeGen/X86/2011-05-09-loaduse.ll
Normal file
@@ -0,0 +1,13 @@
|
||||
; RUN: llc < %s -march=x86 -mcpu=corei7 | FileCheck %s
|
||||
|
||||
;CHECK: test
|
||||
;CHECK-not: pshufd
|
||||
;CHECK: ret
|
||||
define float @test(<4 x float>* %A) nounwind {
|
||||
entry:
|
||||
%T = load <4 x float>* %A
|
||||
%R = extractelement <4 x float> %T, i32 3
|
||||
store <4 x float><float 0.0, float 0.0, float 0.0, float 0.0>, <4 x float>* %A
|
||||
ret float %R
|
||||
}
|
||||
|
Reference in New Issue
Block a user