authorgravatar for thatlemon@gmail.comLemonBoy <thatlemon@gmail.com> 2020-01-19 00:10:42+01:00
committergravatar for thatlemon@gmail.comLemonBoy <thatlemon@gmail.com> 2020-01-19 00:12:27+01:00
log5fbc1c28121c1030de5ba8ca106a3dd8516cfd87
treea5ca2b5d1e739e7c52df2609c30d6929c9317f7c
parent3247fd7862bc5277a2c931f56b41f4f7c085611c

Nuke some more code


4 files changed, 62 insertions(+), 70 deletions(-)

lib/std/special/compiler_rt.zig+10-10
......@@ -226,18 +226,18 @@ comptime {
226226 @export(@import("compiler_rt/divsf3.zig").__aeabi_fdiv, .{ .name = "__aeabi_fdiv", .linkage = linkage });
227227 @export(@import("compiler_rt/divdf3.zig").__aeabi_ddiv, .{ .name = "__aeabi_ddiv", .linkage = linkage });
228228
229 @export(@import("compiler_rt/arm/aeabi_fcmp.zig").__aeabi_fcmpeq, .{ .name = "__aeabi_fcmpeq", .linkage = linkage });
230 @export(@import("compiler_rt/arm/aeabi_fcmp.zig").__aeabi_fcmplt, .{ .name = "__aeabi_fcmplt", .linkage = linkage });
231 @export(@import("compiler_rt/arm/aeabi_fcmp.zig").__aeabi_fcmple, .{ .name = "__aeabi_fcmple", .linkage = linkage });
232 @export(@import("compiler_rt/arm/aeabi_fcmp.zig").__aeabi_fcmpge, .{ .name = "__aeabi_fcmpge", .linkage = linkage });
233 @export(@import("compiler_rt/arm/aeabi_fcmp.zig").__aeabi_fcmpgt, .{ .name = "__aeabi_fcmpgt", .linkage = linkage });
229 @export(@import("compiler_rt/compareXf2.zig").__aeabi_fcmpeq, .{ .name = "__aeabi_fcmpeq", .linkage = linkage });
230 @export(@import("compiler_rt/compareXf2.zig").__aeabi_fcmplt, .{ .name = "__aeabi_fcmplt", .linkage = linkage });
231 @export(@import("compiler_rt/compareXf2.zig").__aeabi_fcmple, .{ .name = "__aeabi_fcmple", .linkage = linkage });
232 @export(@import("compiler_rt/compareXf2.zig").__aeabi_fcmpge, .{ .name = "__aeabi_fcmpge", .linkage = linkage });
233 @export(@import("compiler_rt/compareXf2.zig").__aeabi_fcmpgt, .{ .name = "__aeabi_fcmpgt", .linkage = linkage });
234234 @export(@import("compiler_rt/compareXf2.zig").__aeabi_fcmpun, .{ .name = "__aeabi_fcmpun", .linkage = linkage });
235235
236 @export(@import("compiler_rt/arm/aeabi_dcmp.zig").__aeabi_dcmpeq, .{ .name = "__aeabi_dcmpeq", .linkage = linkage });
237 @export(@import("compiler_rt/arm/aeabi_dcmp.zig").__aeabi_dcmplt, .{ .name = "__aeabi_dcmplt", .linkage = linkage });
238 @export(@import("compiler_rt/arm/aeabi_dcmp.zig").__aeabi_dcmple, .{ .name = "__aeabi_dcmple", .linkage = linkage });
239 @export(@import("compiler_rt/arm/aeabi_dcmp.zig").__aeabi_dcmpge, .{ .name = "__aeabi_dcmpge", .linkage = linkage });
240 @export(@import("compiler_rt/arm/aeabi_dcmp.zig").__aeabi_dcmpgt, .{ .name = "__aeabi_dcmpgt", .linkage = linkage });
236 @export(@import("compiler_rt/compareXf2.zig").__aeabi_dcmpeq, .{ .name = "__aeabi_dcmpeq", .linkage = linkage });
237 @export(@import("compiler_rt/compareXf2.zig").__aeabi_dcmplt, .{ .name = "__aeabi_dcmplt", .linkage = linkage });
238 @export(@import("compiler_rt/compareXf2.zig").__aeabi_dcmple, .{ .name = "__aeabi_dcmple", .linkage = linkage });
239 @export(@import("compiler_rt/compareXf2.zig").__aeabi_dcmpge, .{ .name = "__aeabi_dcmpge", .linkage = linkage });
240 @export(@import("compiler_rt/compareXf2.zig").__aeabi_dcmpgt, .{ .name = "__aeabi_dcmpgt", .linkage = linkage });
241241 @export(@import("compiler_rt/compareXf2.zig").__aeabi_dcmpun, .{ .name = "__aeabi_dcmpun", .linkage = linkage });
242242 }
243243
lib/std/special/compiler_rt/arm/aeabi_dcmp.zig deleted-30
......@@ -1,30 +0,0 @@
1// Ported from:
2//
3// https://github.com/llvm/llvm-project/commit/d674d96bc56c0f377879d01c9d8dfdaaa7859cdb/compiler-rt/lib/builtins/arm/aeabi_dcmp.S
4
5const comparedf2 = @import("../comparedf2.zig");
6
7pub fn __aeabi_dcmpeq(a: f64, b: f64) callconv(.AAPCS) i32 {
8 @setRuntimeSafety(false);
9 return @boolToInt(@call(.{ .modifier = .always_inline }, comparedf2.__eqdf2, .{ a, b }) == 0);
10}
11
12pub fn __aeabi_dcmplt(a: f64, b: f64) callconv(.AAPCS) i32 {
13 @setRuntimeSafety(false);
14 return @boolToInt(@call(.{ .modifier = .always_inline }, comparedf2.__ltdf2, .{ a, b }) < 0);
15}
16
17pub fn __aeabi_dcmple(a: f64, b: f64) callconv(.AAPCS) i32 {
18 @setRuntimeSafety(false);
19 return @boolToInt(@call(.{ .modifier = .always_inline }, comparedf2.__ledf2, .{ a, b }) <= 0);
20}
21
22pub fn __aeabi_dcmpge(a: f64, b: f64) callconv(.AAPCS) i32 {
23 @setRuntimeSafety(false);
24 return @boolToInt(@call(.{ .modifier = .always_inline }, comparedf2.__gedf2, .{ a, b }) >= 0);
25}
26
27pub fn __aeabi_dcmpgt(a: f64, b: f64) callconv(.AAPCS) i32 {
28 @setRuntimeSafety(false);
29 return @boolToInt(@call(.{ .modifier = .always_inline }, comparedf2.__gtdf2, .{ a, b }) > 0);
30}
lib/std/special/compiler_rt/arm/aeabi_fcmp.zig deleted-30
......@@ -1,30 +0,0 @@
1// Ported from:
2//
3// https://github.com/llvm/llvm-project/commit/d674d96bc56c0f377879d01c9d8dfdaaa7859cdb/compiler-rt/lib/builtins/arm/aeabi_fcmp.S
4
5const comparesf2 = @import("../comparesf2.zig");
6
7pub fn __aeabi_fcmpeq(a: f32, b: f32) callconv(.AAPCS) i32 {
8 @setRuntimeSafety(false);
9 return @boolToInt(@call(.{ .modifier = .always_inline }, comparesf2.__eqsf2, .{ a, b }) == 0);
10}
11
12pub fn __aeabi_fcmplt(a: f32, b: f32) callconv(.AAPCS) i32 {
13 @setRuntimeSafety(false);
14 return @boolToInt(@call(.{ .modifier = .always_inline }, comparesf2.__ltsf2, .{ a, b }) < 0);
15}
16
17pub fn __aeabi_fcmple(a: f32, b: f32) callconv(.AAPCS) i32 {
18 @setRuntimeSafety(false);
19 return @boolToInt(@call(.{ .modifier = .always_inline }, comparesf2.__lesf2, .{ a, b }) <= 0);
20}
21
22pub fn __aeabi_fcmpge(a: f32, b: f32) callconv(.AAPCS) i32 {
23 @setRuntimeSafety(false);
24 return @boolToInt(@call(.{ .modifier = .always_inline }, comparesf2.__gesf2, .{ a, b }) >= 0);
25}
26
27pub fn __aeabi_fcmpgt(a: f32, b: f32) callconv(.AAPCS) i32 {
28 @setRuntimeSafety(false);
29 return @boolToInt(@call(.{ .modifier = .always_inline }, comparesf2.__gtsf2, .{ a, b }) > 0);
30}
lib/std/special/compiler_rt/compareXf2.zig+52
......@@ -183,11 +183,63 @@ pub fn __unordtf2(a: f128, b: f128) callconv(.C) i32 {
183183 return @call(.{ .modifier = .always_inline }, unordcmp, .{ f128, a, b });
184184}
185185
186// ARM EABI intrinsics
187
188pub fn __aeabi_fcmpeq(a: f32, b: f32) callconv(.AAPCS) i32 {
189 @setRuntimeSafety(false);
190 return @boolToInt(@call(.{ .modifier = .always_inline }, __eqsf2, .{ a, b }) == 0);
191}
192
193pub fn __aeabi_fcmplt(a: f32, b: f32) callconv(.AAPCS) i32 {
194 @setRuntimeSafety(false);
195 return @boolToInt(@call(.{ .modifier = .always_inline }, __ltsf2, .{ a, b }) < 0);
196}
197
198pub fn __aeabi_fcmple(a: f32, b: f32) callconv(.AAPCS) i32 {
199 @setRuntimeSafety(false);
200 return @boolToInt(@call(.{ .modifier = .always_inline }, __lesf2, .{ a, b }) <= 0);
201}
202
203pub fn __aeabi_fcmpge(a: f32, b: f32) callconv(.AAPCS) i32 {
204 @setRuntimeSafety(false);
205 return @boolToInt(@call(.{ .modifier = .always_inline }, __gesf2, .{ a, b }) >= 0);
206}
207
208pub fn __aeabi_fcmpgt(a: f32, b: f32) callconv(.AAPCS) i32 {
209 @setRuntimeSafety(false);
210 return @boolToInt(@call(.{ .modifier = .always_inline }, __gtsf2, .{ a, b }) > 0);
211}
212
186213pub fn __aeabi_fcmpun(a: f32, b: f32) callconv(.AAPCS) i32 {
187214 @setRuntimeSafety(false);
188215 return @call(.{ .modifier = .always_inline }, __unordsf2, .{ a, b });
189216}
190217
218pub fn __aeabi_dcmpeq(a: f64, b: f64) callconv(.AAPCS) i32 {
219 @setRuntimeSafety(false);
220 return @boolToInt(@call(.{ .modifier = .always_inline }, __eqdf2, .{ a, b }) == 0);
221}
222
223pub fn __aeabi_dcmplt(a: f64, b: f64) callconv(.AAPCS) i32 {
224 @setRuntimeSafety(false);
225 return @boolToInt(@call(.{ .modifier = .always_inline }, __ltdf2, .{ a, b }) < 0);
226}
227
228pub fn __aeabi_dcmple(a: f64, b: f64) callconv(.AAPCS) i32 {
229 @setRuntimeSafety(false);
230 return @boolToInt(@call(.{ .modifier = .always_inline }, __ledf2, .{ a, b }) <= 0);
231}
232
233pub fn __aeabi_dcmpge(a: f64, b: f64) callconv(.AAPCS) i32 {
234 @setRuntimeSafety(false);
235 return @boolToInt(@call(.{ .modifier = .always_inline }, __gedf2, .{ a, b }) >= 0);
236}
237
238pub fn __aeabi_dcmpgt(a: f64, b: f64) callconv(.AAPCS) i32 {
239 @setRuntimeSafety(false);
240 return @boolToInt(@call(.{ .modifier = .always_inline }, __gtdf2, .{ a, b }) > 0);
241}
242
191243pub fn __aeabi_dcmpun(a: f64, b: f64) callconv(.AAPCS) i32 {
192244 @setRuntimeSafety(false);
193245 return @call(.{ .modifier = .always_inline }, __unorddf2, .{ a, b });