brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.1 KiB · 3ea22a9 Raw
43 lines · plain
1## This test checks that inline is properly handled by BOLT on aarch64.2 3# REQUIRES: system-linux4 5# RUN: llvm-mc -filetype=obj -triple aarch64-unknown-unknown %s -o %t.o6# RUN: %clang %cflags -O0 %t.o -o %t.exe -Wl,-q7# RUN: llvm-bolt --inline-small-functions --print-inline  --print-only=_Z3barP1A  \8# RUN: %t.exe -o %t.bolt  | FileCheck %s9 10# CHECK: BOLT-INFO: inlined 0 calls at 1 call sites in 2 iteration(s). Change in binary size: 4 bytes.11# CHECK: Binary Function "_Z3barP1A" after inlining {12# CHECK-NOT: bl	_Z3fooP1A13# CHECK: ldr	x8, [x0]14# CHECK-NEXT: ldr	w0, [x8]15 16	.text17	.globl	_Z3fooP1A                      18	.type	_Z3fooP1A,@function19_Z3fooP1A:                              20	ldr	x8, [x0]21	ldr	w0, [x8]22	ret23	.size	_Z3fooP1A, .-_Z3fooP1A24 25	.globl	_Z3barP1A                       26	.type	_Z3barP1A,@function27_Z3barP1A:                              28	stp	x29, x30, [sp, #-16]!           29	mov	x29, sp30	bl	_Z3fooP1A31	mul	w0, w0, w032	ldp	x29, x30, [sp], #16             33	ret34	.size	_Z3barP1A, .-_Z3barP1A35 36	.globl	main                            37	.p2align	238	.type	main,@function39main:                                   40	mov	w0, wzr41	ret42	.size	main, .-main43