1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 03:02:36 +01:00
llvm-mirror/test/CodeGen/ARM/gnu_mcount_nc.ll
Arthur Eubanks 9edc5021eb Move EntryExitInstrumentation pass location
This seems to be more of a Clang thing rather than a generic LLVM thing,
so this moves it out of LLVM pipelines and as Clang extension hooks into
LLVM pipelines.

Move the post-inline EEInstrumentation out of the backend pipeline and
into a late pass, similar to other sanitizer passes. It doesn't fit
into the codegen pipeline.

Also fix up EntryExitInstrumentation not running at -O0 under the new
PM. PR49143

Reviewed By: hans

Differential Revision: https://reviews.llvm.org/D97608
2021-03-01 10:08:10 -08:00

47 lines
2.3 KiB
LLVM

; RUN: llc -mtriple=armv7a-linux-gnueabihf -verify-machineinstrs %s -o - | FileCheck %s --check-prefix=CHECK-ARM
; RUN: llc -mtriple=armv7a-linux-gnueabihf -verify-machineinstrs -fast-isel %s -o - | FileCheck %s --check-prefix=CHECK-ARM-FAST-ISEL
; RUN: llc -mtriple=armv7a-linux-gnueabihf -verify-machineinstrs -global-isel -global-isel-abort=2 %s -o - | FileCheck %s --check-prefix=CHECK-ARM-GLOBAL-ISEL
; RUN: llc -mtriple=thumbv7a-linux-gnueabihf -verify-machineinstrs %s -o - | FileCheck %s --check-prefix=CHECK-THUMB
; RUN: llc -mtriple=thumbv7a-linux-gnueabihf -verify-machineinstrs -fast-isel %s -o - | FileCheck %s --check-prefix=CHECK-THUMB-FAST-ISEL
; RUN: llc -mtriple=thumbv7a-linux-gnueabihf -verify-machineinstrs -global-isel -global-isel-abort=2 %s -o - | FileCheck %s --check-prefix=CHECK-THUMB-GLOBAL-ISEL
define dso_local void @callee() #0 {
; CHECK-ARM: stmdb sp!, {lr}
; CHECK-ARM-NEXT: bl __gnu_mcount_nc
; CHECK-ARM-FAST-ISEL: stmdb sp!, {lr}
; CHECK-ARM-FAST-ISEL-NEXT: bl __gnu_mcount_nc
; CHECK-ARM-GLOBAL-ISEL: stmdb sp!, {lr}
; CHECK-ARM-GLOBAL-ISEL-NEXT: bl __gnu_mcount_nc
; CHECK-THUMB: push {lr}
; CHECK-THUMB-NEXT: bl __gnu_mcount_nc
; CHECK-THUMB-FAST-ISEL: push {lr}
; CHECK-THUMB-FAST-ISEL-NEXT: bl __gnu_mcount_nc
; CHECK-THUMB-GLOBAL-ISEL: push {lr}
; CHECK-THUMB-GLOBAL-ISEL-NEXT: bl __gnu_mcount_nc
call void @llvm.arm.gnu.eabi.mcount()
ret void
}
define dso_local void @caller() #0 {
; CHECK-ARM: stmdb sp!, {lr}
; CHECK-ARM-NEXT: bl __gnu_mcount_nc
; CHECK-ARM-FAST-ISEL: stmdb sp!, {lr}
; CHECK-ARM-FAST-ISEL-NEXT: bl __gnu_mcount_nc
; CHECK-ARM-GLOBAL-ISEL: stmdb sp!, {lr}
; CHECK-ARM-GLOBAL-ISEL-NEXT: bl __gnu_mcount_nc
; CHECK-THUMB: push {lr}
; CHECK-THUMB-NEXT: bl __gnu_mcount_nc
; CHECK-THUMB-FAST-ISEL: push {lr}
; CHECK-THUMB-FAST-ISEL-NEXT: bl __gnu_mcount_nc
; CHECK-THUMB-GLOBAL-ISEL: push {lr}
; CHECK-THUMB-GLOBAL-ISEL-NEXT: bl __gnu_mcount_nc
call void @llvm.arm.gnu.eabi.mcount()
call void @callee()
ret void
}
declare void @llvm.arm.gnu.eabi.mcount() #1
attributes #0 = { nofree nounwind }
attributes #1 = { nounwind }