compiler-rt: do not export complex arithmetic on ofmt=c

These functions cannot be properly implemented without #8465

Closes #13800
This commit is contained in:
Veikka Tuominen 2022-12-07 14:54:29 +02:00
parent dff32a2cd7
commit 4fb9c75fc9
10 changed files with 30 additions and 10 deletions

View File

@ -3,7 +3,9 @@ const divc3 = @import("./divc3.zig");
const Complex = @import("./mulc3.zig").Complex;
comptime {
@export(__divdc3, .{ .name = "__divdc3", .linkage = common.linkage });
if (@import("builtin").zig_backend != .stage2_c) {
@export(__divdc3, .{ .name = "__divdc3", .linkage = common.linkage });
}
}
pub fn __divdc3(a: f64, b: f64, c: f64, d: f64) callconv(.C) Complex(f64) {

View File

@ -3,7 +3,9 @@ const divc3 = @import("./divc3.zig");
const Complex = @import("./mulc3.zig").Complex;
comptime {
@export(__divhc3, .{ .name = "__divhc3", .linkage = common.linkage });
if (@import("builtin").zig_backend != .stage2_c) {
@export(__divhc3, .{ .name = "__divhc3", .linkage = common.linkage });
}
}
pub fn __divhc3(a: f16, b: f16, c: f16, d: f16) callconv(.C) Complex(f16) {

View File

@ -3,7 +3,9 @@ const divc3 = @import("./divc3.zig");
const Complex = @import("./mulc3.zig").Complex;
comptime {
@export(__divsc3, .{ .name = "__divsc3", .linkage = common.linkage });
if (@import("builtin").zig_backend != .stage2_c) {
@export(__divsc3, .{ .name = "__divsc3", .linkage = common.linkage });
}
}
pub fn __divsc3(a: f32, b: f32, c: f32, d: f32) callconv(.C) Complex(f32) {

View File

@ -3,7 +3,9 @@ const divc3 = @import("./divc3.zig");
const Complex = @import("./mulc3.zig").Complex;
comptime {
@export(__divtc3, .{ .name = "__divtc3", .linkage = common.linkage });
if (@import("builtin").zig_backend != .stage2_c) {
@export(__divtc3, .{ .name = "__divtc3", .linkage = common.linkage });
}
}
pub fn __divtc3(a: f128, b: f128, c: f128, d: f128) callconv(.C) Complex(f128) {

View File

@ -3,7 +3,9 @@ const divc3 = @import("./divc3.zig");
const Complex = @import("./mulc3.zig").Complex;
comptime {
@export(__divxc3, .{ .name = "__divxc3", .linkage = common.linkage });
if (@import("builtin").zig_backend != .stage2_c) {
@export(__divxc3, .{ .name = "__divxc3", .linkage = common.linkage });
}
}
pub fn __divxc3(a: f80, b: f80, c: f80, d: f80) callconv(.C) Complex(f80) {

View File

@ -4,7 +4,9 @@ const mulc3 = @import("./mulc3.zig");
pub const panic = common.panic;
comptime {
@export(__muldc3, .{ .name = "__muldc3", .linkage = common.linkage });
if (@import("builtin").zig_backend != .stage2_c) {
@export(__muldc3, .{ .name = "__muldc3", .linkage = common.linkage });
}
}
pub fn __muldc3(a: f64, b: f64, c: f64, d: f64) callconv(.C) mulc3.Complex(f64) {

View File

@ -4,7 +4,9 @@ const mulc3 = @import("./mulc3.zig");
pub const panic = common.panic;
comptime {
@export(__mulhc3, .{ .name = "__mulhc3", .linkage = common.linkage });
if (@import("builtin").zig_backend != .stage2_c) {
@export(__mulhc3, .{ .name = "__mulhc3", .linkage = common.linkage });
}
}
pub fn __mulhc3(a: f16, b: f16, c: f16, d: f16) callconv(.C) mulc3.Complex(f16) {

View File

@ -4,7 +4,9 @@ const mulc3 = @import("./mulc3.zig");
pub const panic = common.panic;
comptime {
@export(__mulsc3, .{ .name = "__mulsc3", .linkage = common.linkage });
if (@import("builtin").zig_backend != .stage2_c) {
@export(__mulsc3, .{ .name = "__mulsc3", .linkage = common.linkage });
}
}
pub fn __mulsc3(a: f32, b: f32, c: f32, d: f32) callconv(.C) mulc3.Complex(f32) {

View File

@ -4,7 +4,9 @@ const mulc3 = @import("./mulc3.zig");
pub const panic = common.panic;
comptime {
@export(__multc3, .{ .name = "__multc3", .linkage = common.linkage });
if (@import("builtin").zig_backend != .stage2_c) {
@export(__multc3, .{ .name = "__multc3", .linkage = common.linkage });
}
}
pub fn __multc3(a: f128, b: f128, c: f128, d: f128) callconv(.C) mulc3.Complex(f128) {

View File

@ -4,7 +4,9 @@ const mulc3 = @import("./mulc3.zig");
pub const panic = common.panic;
comptime {
@export(__mulxc3, .{ .name = "__mulxc3", .linkage = common.linkage });
if (@import("builtin").zig_backend != .stage2_c) {
@export(__mulxc3, .{ .name = "__mulxc3", .linkage = common.linkage });
}
}
pub fn __mulxc3(a: f80, b: f80, c: f80, d: f80) callconv(.C) mulc3.Complex(f80) {