mirror of
https://github.com/RPCSX/llvm.git
synced 2024-11-24 20:29:53 +00:00
remove a silly condition that doesn't make a lot of sense anymore.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@89601 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
92e803c2a4
commit
4723303c97
@ -275,11 +275,6 @@ bool BasicAliasAnalysis::pointsToConstantMemory(const Value *P) {
|
||||
//
|
||||
AliasAnalysis::ModRefResult
|
||||
BasicAliasAnalysis::getModRefInfo(CallSite CS, Value *P, unsigned Size) {
|
||||
// Don't do anything smart for constant pointers.
|
||||
// FIXME: WHY?
|
||||
if (isa<Constant>(P))
|
||||
return AliasAnalysis::getModRefInfo(CS, P, Size);
|
||||
|
||||
const Value *Object = P->getUnderlyingObject();
|
||||
|
||||
// If this is a tail call and P points to a stack location, we know that
|
||||
|
@ -90,3 +90,20 @@ define void @test3a(i8* %P, i8 %X) {
|
||||
ret void
|
||||
; CHECK: ret void
|
||||
}
|
||||
|
||||
@G1 = external global i32
|
||||
@G2 = external global [4000 x i32]
|
||||
|
||||
define i32 @test4(i8* %P, i8 %X) {
|
||||
%tmp = load i32* @G1
|
||||
call void @llvm.memset.i32(i8* bitcast ([4000 x i32]* @G2 to i8*), i8 0, i32 4000, i32 1)
|
||||
%tmp2 = load i32* @G1
|
||||
%sub = sub i32 %tmp2, %tmp
|
||||
ret i32 %sub
|
||||
; CHECK: @test4
|
||||
; CHECK: load i32* @G
|
||||
; CHECK: memset.i32
|
||||
; CHECK-NOT: load
|
||||
; CHECK: sub i32 %tmp, %tmp
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user