1; RUN: llc < %s -mtriple=ve | FileCheck %s
2
3define i8* @test1() nounwind {
4; CHECK-LABEL: test1:
5; CHECK:       .LBB{{[0-9]+}}_2:
6; CHECK-NEXT:    or %s0, 0, %s9
7; CHECK-NEXT:    or %s11, 0, %s9
8entry:
9  %ret = tail call i8* @llvm.frameaddress(i32 0)
10  ret i8* %ret
11}
12
13define i8* @test2() nounwind {
14; CHECK-LABEL: test2:
15; CHECK:       .LBB{{[0-9]+}}_2:
16; CHECK-NEXT:    ld %s0, (, %s9)
17; CHECK-NEXT:    ld %s0, (, %s0)
18; CHECK-NEXT:    or %s11, 0, %s9
19entry:
20  %ret = tail call i8* @llvm.frameaddress(i32 2)
21  ret i8* %ret
22}
23
24declare i8* @llvm.frameaddress(i32) nounwind readnone
25