mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-09-01 19:29:22 +00:00
If a function is just an unreachable, this would hit a "this is not a MachO target" assertion because of setting HasSubsectionViaSymbols. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@221920 91177308-0d34-0410-b5e6-96231b3b80d8
21 lines
455 B
LLVM
21 lines
455 B
LLVM
; RUN: llc -march=r600 -mcpu=SI -verify-machineinstrs < %s | FileCheck -check-prefix=SI %s
|
|
|
|
; Make sure we don't assert on empty functions
|
|
|
|
; SI-LABEL: {{^}}empty_function_ret:
|
|
; SI: .text
|
|
; SI: s_endpgm
|
|
; SI: codeLenInByte = 4
|
|
define void @empty_function_ret() #0 {
|
|
ret void
|
|
}
|
|
|
|
; SI-LABEL: {{^}}empty_function_unreachable:
|
|
; SI: .text
|
|
; SI: codeLenInByte = 0
|
|
define void @empty_function_unreachable() #0 {
|
|
unreachable
|
|
}
|
|
|
|
attributes #0 = { nounwind }
|