Mercurial > hg > Members > tobaru > cbc > CbC_llvm
view test/CodeGen/Mips/lazy-binding.ll @ 33:e4204d083e25
LLVM 3.5
author | Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp> |
---|---|
date | Thu, 12 Dec 2013 14:32:10 +0900 |
parents | 95c75e76d11b |
children | 1172e4bd9c6f |
line wrap: on
line source
; RUN: llc -march=mipsel < %s | FileCheck %s ; CHECK-LABEL: foo6: ; CHECK: %while.body ; CHECK: lw $25, %call16(foo2)(${{[0-9]+}}) ; CHECK: jalr $25 ; CHECK: %while.end define void @foo6(i32 %n) { entry: %tobool1 = icmp eq i32 %n, 0 br i1 %tobool1, label %while.end, label %while.body while.body: ; preds = %entry, %while.body %n.addr.02 = phi i32 [ %dec, %while.body ], [ %n, %entry ] %dec = add nsw i32 %n.addr.02, -1 tail call void @foo2() %tobool = icmp eq i32 %dec, 0 br i1 %tobool, label %while.end, label %while.body while.end: ; preds = %while.body, %entry ret void } declare void @foo2() ; CHECK-LABEL: foo1: ; CHECK: lw $25, %call16(foo2)(${{[0-9]+}}) ; CHECK: jalr $25 ; CHECK: lw $25, %call16(foo2)(${{[0-9]+}}) ; CHECK: jalr $25 ; CHECK: lw $25, %call16(foo2)(${{[0-9]+}}) ; CHECK: jalr $25 define void @foo1() { entry: tail call void @foo2() tail call void @foo2() tail call void @foo2() ret void }