X-Git-Url: http://plrg.eecs.uci.edu/git/?a=blobdiff_plain;f=test%2FCodeGen%2FBlackfin%2Fcycles.ll;h=6451c747bd709a7f9c377338bbab3dc0c1c9fbba;hb=29074ccf6cb00a3cbe32a3b7809d970ecaf8c9bf;hp=042cb57ffc9ea3282b9ee7b02f4768c9a7072670;hpb=d950941e138455ebcd7a5f55805dcb977892e3e3;p=oota-llvm.git diff --git a/test/CodeGen/Blackfin/cycles.ll b/test/CodeGen/Blackfin/cycles.ll index 042cb57ffc9..6451c747bd7 100644 --- a/test/CodeGen/Blackfin/cycles.ll +++ b/test/CodeGen/Blackfin/cycles.ll @@ -1,11 +1,17 @@ -; RUN: llvm-as < %s | llc -march=bfin | grep cycles -; XFAIL: * -; ExpandIntegerResult #0: 0x181a60c: i64,ch = ReadCycleCounter 0x1104b08 -; Do not know how to expand the result of this operator! +; RUN: llc < %s -march=bfin | FileCheck %s declare i64 @llvm.readcyclecounter() -define i64 @foo() { +; CHECK: cycles +; CHECK: cycles2 +define i64 @cyc64() { %tmp.1 = call i64 @llvm.readcyclecounter() ret i64 %tmp.1 } + +; CHECK: cycles +define i32@cyc32() { + %tmp.1 = call i64 @llvm.readcyclecounter() + %s = trunc i64 %tmp.1 to i32 + ret i32 %s +}