mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-08-18 12:29:21 +00:00
Eliminate explicit control flow in tests
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6961 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
ecf2628cc6
commit
d808e45658
@ -1,10 +1,7 @@
|
||||
; -simplifycfg is not folding blocks if there is a PHI node involved. This
|
||||
; should be fixed eventually
|
||||
|
||||
; RUN: if as < %s | opt -simplifycfg | dis | grep br
|
||||
; RUN: then exit 1
|
||||
; RUN: else exit 0
|
||||
; RUN: fi
|
||||
; RUN: as < %s | opt -simplifycfg | dis | not grep br
|
||||
|
||||
int %main(int %argc) {
|
||||
br label %InlinedFunctionReturnNode
|
||||
|
@ -1,9 +1,6 @@
|
||||
; Test merging of blocks with phi nodes.
|
||||
;
|
||||
; RUN: if as < %s | opt -simplifycfg | dis | grep 'N:'
|
||||
; RUN: then exit 1
|
||||
; RUN: else exit 0
|
||||
; RUN: fi
|
||||
; RUN: as < %s | opt -simplifycfg | dis | not grep 'N:'
|
||||
;
|
||||
|
||||
int %test(bool %a) {
|
||||
|
@ -1,9 +1,6 @@
|
||||
; Test merging of blocks that only have PHI nodes in them
|
||||
;
|
||||
; RUN: if as < %s | opt -simplifycfg | dis | grep 'N:'
|
||||
; RUN: then exit 1
|
||||
; RUN: else exit 0
|
||||
; RUN: fi
|
||||
; RUN: as < %s | opt -simplifycfg | dis | not grep 'N:'
|
||||
;
|
||||
|
||||
int %test(bool %a, bool %b) {
|
||||
|
@ -2,10 +2,7 @@
|
||||
; where the mergedinto block doesn't have any PHI nodes, and is in fact
|
||||
; dominated by the block-to-be-eliminated
|
||||
;
|
||||
; RUN: if as < %s | opt -simplifycfg | dis | grep 'N:'
|
||||
; RUN: then exit 1
|
||||
; RUN: else exit 0
|
||||
; RUN: fi
|
||||
; RUN: as < %s | opt -simplifycfg | dis | not grep 'N:'
|
||||
;
|
||||
|
||||
int %test(bool %a, bool %b) {
|
||||
|
@ -1,9 +1,6 @@
|
||||
; Test CFG simplify removal of branch instructions...
|
||||
;
|
||||
; RUN: if as < %s | opt -simplifycfg | dis | grep br
|
||||
; RUN: then exit 1
|
||||
; RUN: else exit 0
|
||||
; RUN: fi
|
||||
; RUN: as < %s | opt -simplifycfg | dis | not grep br
|
||||
|
||||
|
||||
void "test1"() {
|
||||
|
@ -1,10 +1,7 @@
|
||||
; This test ensures that the simplifycfg pass continues to constant fold
|
||||
; terminator instructions.
|
||||
|
||||
; RUN: if as < %s | opt -simplifycfg | grep br
|
||||
; RUN: then exit 1
|
||||
; RUN: else exit 0
|
||||
; RUN: fi
|
||||
; RUN: as < %s | opt -simplifycfg | not grep br
|
||||
|
||||
int %test(int %A, int %B) {
|
||||
J:
|
||||
|
Loading…
Reference in New Issue
Block a user