diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2023-01-31 23:15:59 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-01-31 23:15:59 -0500 |
| commit | efa25e7d5bca63e83f6a653058c05dacc771d19e (patch) | |
| tree | 56b34421822584702b1647ab0eb38aec160386b4 /src/codegen | |
| parent | 6f13a725a3249c7f0a0f5258ac00003cd132bf15 (diff) | |
| parent | 8d37c6f71c790faecdb6acdd2868823be2bd2496 (diff) | |
| download | zig-efa25e7d5bca63e83f6a653058c05dacc771d19e.tar.gz zig-efa25e7d5bca63e83f6a653058c05dacc771d19e.zip | |
Merge pull request #14498 from ziglang/zig-build-api
Several enhancements to the build system. Many breaking changes to the API.
* combine `std.build` and `std.build.Builder` into `std.Build`
* eliminate `setTarget` and `setBuildMode`; use an options struct for `b.addExecutable` and friends
* implement passing options to dependency packages. closes #14285
* rename `LibExeObjStep` to `CompileStep`
* move src.type.CType to std lib, use it from std.Build, this helps with populating config.h files.
Diffstat (limited to 'src/codegen')
| -rw-r--r-- | src/codegen/c.zig | 1 | ||||
| -rw-r--r-- | src/codegen/llvm.zig | 5 |
2 files changed, 2 insertions, 4 deletions
diff --git a/src/codegen/c.zig b/src/codegen/c.zig index eb0ae1b1f6..2f721e1b4b 100644 --- a/src/codegen/c.zig +++ b/src/codegen/c.zig @@ -16,7 +16,6 @@ const trace = @import("../tracy.zig").trace; const LazySrcLoc = Module.LazySrcLoc; const Air = @import("../Air.zig"); const Liveness = @import("../Liveness.zig"); -const CType = @import("../type.zig").CType; const target_util = @import("../target.zig"); const libcFloatPrefix = target_util.libcFloatPrefix; diff --git a/src/codegen/llvm.zig b/src/codegen/llvm.zig index c528abdd7c..e19c70f322 100644 --- a/src/codegen/llvm.zig +++ b/src/codegen/llvm.zig @@ -19,7 +19,6 @@ const Liveness = @import("../Liveness.zig"); const Value = @import("../value.zig").Value; const Type = @import("../type.zig").Type; const LazySrcLoc = Module.LazySrcLoc; -const CType = @import("../type.zig").CType; const x86_64_abi = @import("../arch/x86_64/abi.zig"); const wasm_c_abi = @import("../arch/wasm/abi.zig"); const aarch64_c_abi = @import("../arch/aarch64/abi.zig"); @@ -11043,8 +11042,8 @@ fn backendSupportsF128(target: std.Target) bool { fn intrinsicsAllowed(scalar_ty: Type, target: std.Target) bool { return switch (scalar_ty.tag()) { .f16 => backendSupportsF16(target), - .f80 => (CType.longdouble.sizeInBits(target) == 80) and backendSupportsF80(target), - .f128 => (CType.longdouble.sizeInBits(target) == 128) and backendSupportsF128(target), + .f80 => (target.c_type_bit_size(.longdouble) == 80) and backendSupportsF80(target), + .f128 => (target.c_type_bit_size(.longdouble) == 128) and backendSupportsF128(target), else => true, }; } |
