diff options
Diffstat (limited to 'src/codegen/llvm.zig')
| -rw-r--r-- | src/codegen/llvm.zig | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/codegen/llvm.zig b/src/codegen/llvm.zig index ff1e679898..b94ea07995 100644 --- a/src/codegen/llvm.zig +++ b/src/codegen/llvm.zig @@ -3141,8 +3141,11 @@ pub const Object = struct { } }, &o.builder); } try attributes.addFnAttr(.nounwind, &o.builder); - if (owner_mod.unwind_tables) { - try attributes.addFnAttr(.{ .uwtable = Builder.Attribute.UwTable.default }, &o.builder); + if (owner_mod.unwind_tables != .none) { + try attributes.addFnAttr( + .{ .uwtable = if (owner_mod.unwind_tables == .@"async") .@"async" else .sync }, + &o.builder, + ); } if (owner_mod.no_builtin) { // The intent here is for compiler-rt and libc functions to not generate |
