File tree 4 files changed +15
-2
lines changed
4 files changed +15
-2
lines changed Original file line number Diff line number Diff line change @@ -62,6 +62,7 @@ comptime {
62
62
_ = @import ("compiler_rt/emutls.zig" );
63
63
_ = @import ("compiler_rt/arm.zig" );
64
64
_ = @import ("compiler_rt/aulldiv.zig" );
65
+ _ = @import ("compiler_rt/aullrem.zig" );
65
66
_ = @import ("compiler_rt/sparc.zig" );
66
67
_ = @import ("compiler_rt/clear_cache.zig" );
67
68
Original file line number Diff line number Diff line change @@ -10,8 +10,6 @@ comptime {
10
10
// Don't let LLVM apply the stdcall name mangling on those MSVC builtins
11
11
@export (_alldiv , .{ .name = "\x01 __alldiv" , .linkage = linkage });
12
12
@export (_aulldiv , .{ .name = "\x01 __aulldiv" , .linkage = linkage });
13
- @export (_allrem , .{ .name = "\x01 __allrem" , .linkage = linkage });
14
- @export (_aullrem , .{ .name = "\x01 __aullrem" , .linkage = linkage });
15
13
}
16
14
}
17
15
Original file line number Diff line number Diff line change
1
+ const std = @import ("std" );
1
2
const builtin = @import ("builtin" );
3
+ const arch = builtin .cpu .arch ;
4
+ const abi = builtin .abi ;
5
+ const linkage : std.builtin.GlobalLinkage = if (builtin .is_test ) .Internal else .Strong ;
6
+ pub const panic = @import ("common.zig" ).panic ;
7
+
8
+ comptime {
9
+ if (arch == .i386 and abi == .msvc ) {
10
+ // Don't let LLVM apply the stdcall name mangling on those MSVC builtins
11
+ @export (_allrem , .{ .name = "\x01 __allrem" , .linkage = linkage });
12
+ @export (_aullrem , .{ .name = "\x01 __aullrem" , .linkage = linkage });
13
+ }
14
+ }
2
15
3
16
pub fn _allrem (a : i64 , b : i64 ) callconv (.Stdcall ) i64 {
4
17
@setRuntimeSafety (builtin .is_test );
Original file line number Diff line number Diff line change @@ -227,6 +227,7 @@ const sources = &[_][]const u8{
227
227
"compiler_rt/emutls.zig" ,
228
228
"compiler_rt/arm.zig" ,
229
229
"compiler_rt/aulldiv.zig" ,
230
+ "compiler_rt/aullrem.zig" ,
230
231
"compiler_rt/sparc.zig" ,
231
232
"compiler_rt/clear_cache.zig" ,
232
233
};
You can’t perform that action at this time.
0 commit comments