aboutsummaryrefslogtreecommitdiff
path: root/src/main.zig
diff options
context:
space:
mode:
authorAli Cheraghi <alichraghi@proton.me>2025-04-20 20:45:01 +0330
committerAlex Rønne Petersen <alex@alexrp.com>2025-04-21 10:45:05 +0200
commitffd85ffcda3c36b2cda0783ab285ede8b0fc55af (patch)
tree2fcb918dd1f88dbb34cf75916f778709c9a0fcbd /src/main.zig
parent13541bc1c0f97c39591c2ba82e9a8c7979ce7b63 (diff)
downloadzig-ffd85ffcda3c36b2cda0783ab285ede8b0fc55af.tar.gz
zig-ffd85ffcda3c36b2cda0783ab285ede8b0fc55af.zip
revive nvptx linkage
Diffstat (limited to 'src/main.zig')
-rw-r--r--src/main.zig6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main.zig b/src/main.zig
index 2605b089eb..740cea1cdb 100644
--- a/src/main.zig
+++ b/src/main.zig
@@ -3081,6 +3081,12 @@ fn buildOutputType(
const target = main_mod.resolved_target.result;
+ if (target.cpu.arch.isNvptx()) {
+ if (emit_bin != .no and create_module.resolved_options.use_llvm) {
+ fatal("cannot emit PTX binary with the LLVM backend; only '-femit-asm' is supported", .{});
+ }
+ }
+
if (target.os.tag == .windows and major_subsystem_version == null and minor_subsystem_version == null) {
major_subsystem_version, minor_subsystem_version = switch (target.os.version_range.windows.min) {
.nt4 => .{ 4, 0 },