| ... | @@ -98,12 +98,12 @@ pub fn wantsLiveness(pt: Zcu.PerThread, nav_index: InternPool.Nav.Index) bool { | ... | @@ -98,12 +98,12 @@ pub fn wantsLiveness(pt: Zcu.PerThread, nav_index: InternPool.Nav.Index) bool { |
| 98 | /// MIR from codegen to the linker *regardless* of which backend is in use. So, we use this: a | 98 | /// MIR from codegen to the linker *regardless* of which backend is in use. So, we use this: a |
| 99 | /// union of all MIR types. The active tag is known from the backend in use; see `AnyMir.tag`. | 99 | /// union of all MIR types. The active tag is known from the backend in use; see `AnyMir.tag`. |
| 100 | pub const AnyMir = union { | 100 | pub const AnyMir = union { |
| 101 | aarch64: @import("codegen/aarch64/Mir.zig"), | 101 | aarch64: if (dev.env.supports(.aarch64_backend)) @import("codegen/aarch64/Mir.zig") else noreturn, |
| 102 | riscv64: @import("arch/riscv64/Mir.zig"), | 102 | riscv64: if (dev.env.supports(.riscv64_backend)) @import("arch/riscv64/Mir.zig") else noreturn, |
| 103 | sparc64: @import("arch/sparc64/Mir.zig"), | 103 | sparc64: if (dev.env.supports(.sparc64_backend)) @import("arch/sparc64/Mir.zig") else noreturn, |
| 104 | x86_64: @import("arch/x86_64/Mir.zig"), | 104 | x86_64: if (dev.env.supports(.x86_64_backend)) @import("arch/x86_64/Mir.zig") else noreturn, |
| 105 | wasm: @import("arch/wasm/Mir.zig"), | 105 | wasm: if (dev.env.supports(.wasm_backend)) @import("arch/wasm/Mir.zig") else noreturn, |
| 106 | c: @import("codegen/c.zig").Mir, | 106 | c: if (dev.env.supports(.c_backend)) @import("codegen/c.zig").Mir else noreturn, |
| 107 | | 107 | |
| 108 | pub inline fn tag(comptime backend: std.builtin.CompilerBackend) []const u8 { | 108 | pub inline fn tag(comptime backend: std.builtin.CompilerBackend) []const u8 { |
| 109 | return switch (backend) { | 109 | return switch (backend) { |