mirror of
https://github.com/ziglang/zig.git
synced 2025-12-06 06:13:07 +00:00
Compilation: Disable LTO by default.
LLD has too many LTO bugs, and we're dropping the LLD dependency soon anyway.
This commit is contained in:
parent
9f116d38b8
commit
b60e39fe8f
@ -295,27 +295,8 @@ pub fn resolve(options: Options) ResolveError!Config {
|
||||
}
|
||||
|
||||
if (options.lto) |x| break :b x;
|
||||
if (!options.any_c_source_files) break :b .none;
|
||||
|
||||
// https://github.com/llvm/llvm-project/pull/116537
|
||||
switch (target.abi) {
|
||||
.gnuabin32,
|
||||
.gnuilp32,
|
||||
.gnux32,
|
||||
.ilp32,
|
||||
.muslabin32,
|
||||
.muslx32,
|
||||
=> break :b .none,
|
||||
else => {},
|
||||
}
|
||||
|
||||
break :b switch (options.output_mode) {
|
||||
.Lib, .Obj => .none,
|
||||
.Exe => switch (root_optimize_mode) {
|
||||
.Debug => .none,
|
||||
.ReleaseSafe, .ReleaseFast, .ReleaseSmall => .full,
|
||||
},
|
||||
};
|
||||
break :b .none;
|
||||
};
|
||||
|
||||
const link_libcpp = b: {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user