diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2021-01-11 22:07:47 -0700 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2021-01-11 22:07:47 -0700 |
| commit | 0edde40c25c033aec67f235365593ee26ff52740 (patch) | |
| tree | dfdd8caf259e2d03ba89d4c0211d9cafb45c6064 /src/stage1/codegen.cpp | |
| parent | 56c03881ebd8617e6506bfad01bf9cfdd4d3df7e (diff) | |
| parent | 5b2a79848ced20db80f3f4ce46b3ef7f4a051d53 (diff) | |
| download | zig-0edde40c25c033aec67f235365593ee26ff52740.tar.gz zig-0edde40c25c033aec67f235365593ee26ff52740.zip | |
Merge 'Add support for no red zone'
Merges #7511
Diffstat (limited to 'src/stage1/codegen.cpp')
| -rw-r--r-- | src/stage1/codegen.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/stage1/codegen.cpp b/src/stage1/codegen.cpp index 386bc43086..10943483f4 100644 --- a/src/stage1/codegen.cpp +++ b/src/stage1/codegen.cpp @@ -514,6 +514,10 @@ static LLVMValueRef make_fn_llvm_value(CodeGen *g, ZigFn *fn) { maybe_import_dll(g, llvm_fn, linkage); } + if (!g->red_zone) { + addLLVMFnAttr(llvm_fn, "noredzone"); + } + if (fn->alignstack_value != 0) { addLLVMFnAttrInt(llvm_fn, "alignstack", fn->alignstack_value); } |
