Commit 10a4c2269d

Jacob Young <jacobly0@users.noreply.github.com>
2023-04-29 23:57:23
x86_64: enable normal start/test_runner logic on more targets
1 parent c818789
Changed files (3)
lib/std/start.zig
@@ -18,7 +18,7 @@ const start_sym_name = if (native_arch.isMIPS()) "__start" else "_start";
 // Until then, we have simplified logic here for self-hosted. TODO remove this once
 // self-hosted is capable enough to handle all of the real start.zig logic.
 pub const simplified_logic =
-    (builtin.zig_backend == .stage2_x86_64 and (builtin.link_libc or builtin.os.tag == .plan9)) or
+    (builtin.zig_backend == .stage2_x86_64 and builtin.os.tag == .plan9) or
     builtin.zig_backend == .stage2_x86 or
     builtin.zig_backend == .stage2_aarch64 or
     builtin.zig_backend == .stage2_arm or
lib/test_runner.zig
@@ -13,7 +13,6 @@ var fba = std.heap.FixedBufferAllocator.init(&cmdline_buffer);
 
 pub fn main() void {
     if (builtin.zig_backend == .stage2_wasm or
-        (builtin.zig_backend == .stage2_x86_64 and builtin.os.tag != .linux) or
         builtin.zig_backend == .stage2_aarch64)
     {
         return mainSimple() catch @panic("test failure");
test/src/Cases.zig
@@ -396,6 +396,12 @@ fn addFromDirInner(
                     // Other backends don't support new liveness format
                     continue;
                 }
+                if (backend == .stage2 and target.getOsTag() == .macos and
+                    target.getCpuArch() == .x86_64 and builtin.cpu.arch == .aarch64)
+                {
+                    // Rosetta has issues with ZLD
+                    continue;
+                }
 
                 const next = ctx.cases.items.len;
                 try ctx.cases.append(.{