[BOLT] Fix tailcall-traps and basic-instr tests on ubuntu

Summary: These tests are failing on opensource ubuntu.

(cherry picked from FBD32514489)
This commit is contained in:
Rafael Auler 2021-11-17 15:38:36 -08:00 committed by Maksim Panchenko
parent c7f8adb87f
commit 2f3285989e
4 changed files with 13 additions and 3 deletions

View File

@ -15,3 +15,4 @@ bar:
.globl moo
moo:
nop

View File

@ -1,6 +1,6 @@
# Tests the peephole that adds trap instructions following indirect tail calls.
RUN: %clang %p/Inputs/tailcall_traps.s -o %t.exe
RUN: %clang %cflags %p/Inputs/tailcall_traps.s -o %t.exe
RUN: llvm-bolt %t.exe -o %t -peepholes=tailcall-traps \
RUN: -print-peepholes -funcs=foo,bar 2>&1 | FileCheck %s

View File

@ -0,0 +1,9 @@
.globl main
.type main, %function
main:
pushq %rbp
movq %rsp, %rbp
movl $0x0, %eax
popq %rbp
retq
.size main, .-main

View File

@ -1,8 +1,8 @@
# Try to instrument a very fast test. varargs will not execute any code during
# Try to instrument a very fast test. Input bin will not execute any code during
# runtime besides returning zero in main, so it is a good trivial case.
REQUIRES: system-linux
RUN: %clang %p/../../Inputs/vararg.s -Wl,-q -o %t.exe
RUN: %clang %p/Inputs/basic-instrumentation.s -Wl,-q -o %t.exe
RUN: llvm-bolt %t.exe -o %t -instrument \
RUN: -instrumentation-file=%t \
RUN: -instrumentation-file-append-pid