diff options
author | Marek Olšák <[email protected]> | 2016-07-01 20:09:47 +0200 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2016-07-11 19:06:05 +0200 |
commit | d7b6f90684e415b8e9f2d5cd30b9503a7e39a00e (patch) | |
tree | f12e7a39e234a5c45f9b23bc7b98600482ad13a8 | |
parent | 3c446291422873722e358a943081c3940a2e98c5 (diff) |
gallivm: set LLVMNoUnwindAttribute on all intrinsics
RadeonSI stats: Mostly 0% difference, but Valley shows a small improvement:
Application Files SGPRs VGPRs SpillSGPR SpillVGPR Code Size LDS Max Waves Waits
unigine_valley 278 0.00 % -0.29 % 0.00 % 0.00 % 0.01 % 0.00 % 0.17 % 0.00 %
Reviewed-by: Jose Fonseca <[email protected]>
-rw-r--r-- | src/gallium/auxiliary/gallivm/lp_bld_intr.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/gallium/auxiliary/gallivm/lp_bld_intr.c b/src/gallium/auxiliary/gallivm/lp_bld_intr.c index 0a8f996a63e..f12e735b5ee 100644 --- a/src/gallium/auxiliary/gallivm/lp_bld_intr.c +++ b/src/gallium/auxiliary/gallivm/lp_bld_intr.c @@ -145,8 +145,10 @@ lp_build_intrinsic(LLVMBuilderRef builder, function = lp_declare_intrinsic(module, name, ret_type, arg_types, num_args); - if (attr) - LLVMAddFunctionAttr(function, attr); + /* NoUnwind indicates that the intrinsic never raises a C++ exception. + * Set it for all intrinsics. + */ + LLVMAddFunctionAttr(function, attr | LLVMNoUnwindAttribute); if (gallivm_debug & GALLIVM_DEBUG_IR) { lp_debug_dump_value(function); |