2018-07-12 22:36:43 +08:00
|
|
|
; RUN: llc -verify-machineinstrs -filetype=asm -o - -mtriple=x86_64-unknown-linux-gnu -function-sections < %s | FileCheck %s
|
|
|
|
; RUN: llc -verify-machineinstrs -filetype=obj -o %t -mtriple=x86_64-unknown-linux-gnu -function-sections < %s
|
2016-08-09 18:42:11 +08:00
|
|
|
; RUN: llvm-objdump -triple x86_64-unknown-linux-gnu -disassemble-all %t | FileCheck %s --check-prefix=CHECK-OBJ
|
2016-08-03 15:21:55 +08:00
|
|
|
|
|
|
|
define i32 @foo() nounwind noinline uwtable "function-instrument"="xray-always" {
|
|
|
|
; CHECK: .section .text.foo,"ax",@progbits
|
|
|
|
ret i32 0
|
2017-09-14 15:08:23 +08:00
|
|
|
; CHECK: .section xray_instr_map,"awo",@progbits,foo,unique,1
|
2016-08-03 15:21:55 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
$bar = comdat any
|
2016-08-09 18:42:11 +08:00
|
|
|
define i32 @bar() nounwind noinline uwtable "function-instrument"="xray-always" comdat($bar) {
|
|
|
|
; CHECK: .section .text.bar,"axG",@progbits,bar,comdat
|
2016-08-03 15:21:55 +08:00
|
|
|
ret i32 1
|
2017-09-14 15:08:23 +08:00
|
|
|
; CHECK: .section xray_instr_map,"aGwo",@progbits,bar,comdat,bar,unique,2
|
2016-08-03 15:21:55 +08:00
|
|
|
}
|
2016-08-09 18:42:11 +08:00
|
|
|
|
|
|
|
; CHECK-OBJ: section xray_instr_map:
|