Files
Wei Ding 2e3d9f4dbc AMDGPU : Add trap handler support.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@292893 91177308-0d34-0410-b5e6-96231b3b80d8
2017-01-24 06:41:21 +00:00

15 lines
329 B
LLVM

; RUN: llc -mtriple=amdgcn--amdhsa -verify-machineinstrs < %s 2>&1 | FileCheck -check-prefix=GCN %s
declare void @llvm.trap() #0
; GCN-LABEL: {{^}}trap:
; GCN: v_mov_b32_e32 v0, 1
; GCN: s_mov_b64 s[0:1], s[4:5]
; GCN: s_trap 1
define void @trap() {
call void @llvm.trap()
ret void
}
attributes #0 = { nounwind noreturn }