mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-25 16:24:23 +00:00
UseListOrder: Handle self-users
Correctly sort self-users (such as PHI nodes). I added a targeted test in `test/Bitcode/use-list-order.ll` and the final missing RUN line to tests in `test/Assembly`. This is part of PR5680. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@214417 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -118,3 +118,16 @@ entry:
|
||||
%local = load i4* @globalAndFunction
|
||||
ret i4 %local
|
||||
}
|
||||
|
||||
; Check for when an instruction is its own user.
|
||||
define void @selfUser() {
|
||||
entry:
|
||||
ret void
|
||||
|
||||
loop1:
|
||||
br label %loop2
|
||||
|
||||
loop2:
|
||||
%var = phi i32 [ %var, %loop1 ], [ %var, %loop2 ]
|
||||
br label %loop1
|
||||
}
|
||||
|
Reference in New Issue
Block a user