aboutsummaryrefslogtreecommitdiff
path: root/src/Compilation.zig
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2020-09-29 00:34:53 -0700
committerAndrew Kelley <andrew@ziglang.org>2020-09-29 00:34:53 -0700
commitcfbcb4116017a27a403f8be11a32f25f6c1c8671 (patch)
tree2f4e7267a066e70adf4f1f17520220e5e42bfce5 /src/Compilation.zig
parent750b00c642782127736eb378ec9583db2d680bb6 (diff)
downloadzig-cfbcb4116017a27a403f8be11a32f25f6c1c8671.tar.gz
zig-cfbcb4116017a27a403f8be11a32f25f6c1c8671.zip
stage2: add CLI option for -fstack-report
Diffstat (limited to 'src/Compilation.zig')
-rw-r--r--src/Compilation.zig5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Compilation.zig b/src/Compilation.zig
index c636ccb0b2..aa6ab94415 100644
--- a/src/Compilation.zig
+++ b/src/Compilation.zig
@@ -61,6 +61,7 @@ verbose_cimport: bool,
verbose_llvm_cpu_features: bool,
disable_c_depfile: bool,
time_report: bool,
+stack_report: bool,
c_source_files: []const CSourceFile,
clang_argv: []const []const u8,
@@ -348,6 +349,7 @@ pub const InitOptions = struct {
single_threaded: bool = false,
is_native_os: bool,
time_report: bool = false,
+ stack_report: bool = false,
link_eh_frame_hdr: bool = false,
linker_script: ?[]const u8 = null,
version_script: ?[]const u8 = null,
@@ -821,6 +823,7 @@ pub fn create(gpa: *Allocator, options: InitOptions) !*Compilation {
.owned_link_dir = owned_link_dir,
.color = options.color,
.time_report = options.time_report,
+ .stack_report = options.stack_report,
.test_filter = options.test_filter,
.test_name_prefix = options.test_name_prefix,
.test_evented_io = options.test_evented_io,
@@ -2670,7 +2673,7 @@ fn updateStage1Module(comp: *Compilation) !void {
.function_sections = comp.bin_file.options.function_sections,
.enable_stack_probing = comp.bin_file.options.stack_check,
.enable_time_report = comp.time_report,
- .enable_stack_report = false,
+ .enable_stack_report = comp.stack_report,
.test_is_evented = comp.test_evented_io,
.verbose_tokenize = comp.verbose_tokenize,
.verbose_ast = comp.verbose_ast,