mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-23 19:23:23 +01:00
400c1358d0
Summary: Before this change, personality directives were not emitted if there was no invoke left in the function (of course until recently this also meant that we couldn't know what the personality actually was). This patch forces personality directives to still be emitted, unless it is known to be a noop in the absence of invokes, or the user explicitly specified `nounwind` (and not `uwtable`) on the function. Reviewers: majnemer, rnk Subscribers: rnk, llvm-commits Differential Revision: http://reviews.llvm.org/D10884 llvm-svn: 242185
13 lines
387 B
LLVM
13 lines
387 B
LLVM
; RUN: llc < %s -mtriple=x86_64-pc-linux | FileCheck %s
|
|
; Test that we emit functions with explicitly specified personality,
|
|
; even if no landing pads are left.
|
|
|
|
declare i32 @__my_personality_v0(...)
|
|
declare void @might_throw()
|
|
|
|
define i32 @foo() personality i32 (...)* @__my_personality_v0 {
|
|
; CHECK: .cfi_personality 3, __my_personality_v0
|
|
call void @might_throw()
|
|
ret i32 0
|
|
}
|