1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 19:23:23 +01:00

Fix a typo that was killing GVNPRE of select instructions.

llvm-svn: 37871
This commit is contained in:
Owen Anderson 2007-07-04 18:26:18 +00:00
parent 06dd016177
commit ac8fe6b8ca
2 changed files with 10 additions and 1 deletions

View File

@ -1040,7 +1040,7 @@ void GVNPRE::topo_sort(SmallPtrSet<Value*, 16>& set, std::vector<Value*>& vec) {
stack.push_back(r);
else if (m != 0 && isa<Instruction>(m) &&
visited.count(m) == 0)
stack.push_back(r);
stack.push_back(m);
else {
vec.push_back(e);
visited.insert(e);

View File

@ -0,0 +1,9 @@
; RUN: llvm-as < %s | opt -gvnpre | llvm-dis
define i32* @_ZN6Solver9propagateEv(i32* %this) {
entry:
%tmp15.i48 = load i8* null ; <i8> [#uses=2]
%tmp64.i.i51 = sub i8 0, %tmp15.i48 ; <i8> [#uses=1]
%tmp231.i52 = select i1 false, i8 %tmp15.i48, i8 %tmp64.i.i51 ; <i8> [#uses=0]
ret i32* null
}