• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; RUN: llc < %s -march=ptx32 | FileCheck %s
2
3define ptx_device void @test_bra_direct() {
4; CHECK: bra $L__BB0_1;
5entry:
6	br label %loop
7loop:
8	br label %loop
9}
10
11define ptx_device i32 @test_bra_cond_direct(i32 %x, i32 %y) {
12entry:
13; CHECK: setp.le.u32 %p0, %r[[R0:[0-9]+]], %r[[R1:[0-9]+]]
14	%p = icmp ugt i32 %x, %y
15; CHECK-NEXT: @%p0 bra
16; CHECK-NOT: bra
17	br i1 %p, label %clause.if, label %clause.else
18clause.if:
19; CHECK: mov.u32 %ret{{[0-9]+}}, %r[[R0]]
20	ret i32 %x
21clause.else:
22; CHECK: mov.u32 %ret{{[0-9]+}}, %r[[R1]]
23	ret i32 %y
24}
25