You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
436 B
19 lines
436 B
7 months ago
|
; RUN: llc -mtriple=x86_64-linux-gnu %s -o - | FileCheck %s
|
||
|
|
||
|
define void @test_ubsantrap() {
|
||
|
; CHECK-LABEL: test_ubsantrap
|
||
|
; CHECK: ud1l 12(%eax), %eax
|
||
|
call void @llvm.ubsantrap(i8 12)
|
||
|
ret void
|
||
|
}
|
||
|
|
||
|
define void @test_ubsantrap_function() {
|
||
|
; CHECK-LABEL: test_ubsantrap_function:
|
||
|
; CHECK: movl $12, %edi
|
||
|
; CHECK: callq wibble
|
||
|
call void @llvm.ubsantrap(i8 12) "trap-func-name"="wibble"
|
||
|
ret void
|
||
|
}
|
||
|
|
||
|
declare void @llvm.ubsantrap(i8)
|