brintos

brintos / llvm-project-archived public Read only

0
0
Text · 702 B · 1859d2d Raw
22 lines · plain
1; This testcase can be simplified by "realizing" that alloca can never return2; null.3; RUN: opt < %s -passes=instcombine,simplifycfg -simplifycfg-require-and-preserve-domtree=1 -S | FileCheck %s4; CHECK-NOT: br5 6declare i32 @bitmap_clear(...)7 8define i32 @oof() {9entry:10        %live_head = alloca i32         ; <ptr> [#uses=2]11        %tmp.1 = icmp ne ptr %live_head, null          ; <i1> [#uses=1]12        br i1 %tmp.1, label %then, label %UnifiedExitNode13 14then:           ; preds = %entry15        %tmp.4 = call i32 (...) @bitmap_clear( ptr %live_head )               ; <i32> [#uses=0]16        br label %UnifiedExitNode17 18UnifiedExitNode:                ; preds = %then, %entry19        ret i32 020}21 22