[gc.statepoint] Change gc.statepoint intrinsic's return type to token type instead...
[oota-llvm.git] / test / CodeGen / X86 / statepoint-far-call.ll
1 ; RUN: llc < %s | FileCheck %s\r
2 ; Test to check that Statepoints with X64 far-immediate targets\r
3 ; are lowered correctly to an indirect call via a scratch register.\r
4 \r
5 target datalayout = "e-i64:64-f80:128-n8:16:32:64-S128"\r
6 target triple = "x86_64-pc-win64"\r
7 \r
8 define void @test_far_call() gc "statepoint-example" {\r
9 ; CHECK-LABEL: test_far_call\r
10 ; CHECK: pushq %rax\r
11 ; CHECK: movabsq $140727162896504, %rax \r
12 ; CHECK: callq *%rax\r
13 ; CHECK: popq %rax\r
14 ; CHECK: retq\r
15 \r
16 entry:\r
17   %safepoint_token = call token (i64, i32, void ()*, i32, i32, ...) @llvm.experimental.gc.statepoint.p0f_isVoidf(i64 0, i32 0, void ()* inttoptr (i64 140727162896504 to void ()*), i32 0, i32 0, i32 0, i32 0)  \r
18   ret void\r
19 }\r
20 \r
21 declare token @llvm.experimental.gc.statepoint.p0f_isVoidf(i64, i32, void ()*, i32, i32, ...)\r
22 \r