1; RUN: llc -march=ppc64le -mcpu=pwr8 < %s | FileCheck %s
2; RUN: llc -march=ppc64le < %s | FileCheck %s
3
4; The second run of the test case is to ensure the behaviour is the same
5; without specifying -mcpu=pwr8 as that is now the baseline for ppc64le.
6
7target datalayout = "e-m:e-i64:64-n32:64"
8target triple = "powerpc64le-unknown-linux-gnu"
9
10; Indirect calls requires a full stub creation
11define void @test_indirect(void ()* nocapture %fp) {
12; CHECK-LABEL: @test_indirect
13  tail call void %fp()
14; CHECK-DAG: std 2, 24(1)
15; CHECK-DAG: mr 12, 3
16; CHECK-DAG: mtctr 3
17; CHECK: bctrl
18; CHECK-NEXT: ld 2, 24(1)
19  ret void
20}
21
22