Dan Gohman | 3c7d308 | 2009-09-11 18:01:28 +0000 | [diff] [blame^] | 1 | ; RUN: opt < %s -loopsimplify |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 2 | |
| 3 | ; This function should get a preheader inserted before BB3, that is jumped |
| 4 | ; to by BB1 & BB2 |
| 5 | ; |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 6 | |
Tanya Lattner | 348c618 | 2008-03-25 04:26:08 +0000 | [diff] [blame] | 7 | define void @test() { |
| 8 | br i1 true, label %BB1, label %BB2 |
| 9 | BB1: ; preds = %0 |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 10 | br label %BB3 |
Tanya Lattner | 348c618 | 2008-03-25 04:26:08 +0000 | [diff] [blame] | 11 | BB2: ; preds = %0 |
| 12 | br label %BB3 |
| 13 | BB3: ; preds = %BB3, %BB2, %BB1 |
| 14 | br label %BB3 |
| 15 | } |
| 16 | |