zig

fork of https://codeberg.org/ziglang/zig
Log | Files | Refs | README | LICENSE

unordsf2.zig (634B) - Raw


      1 const common = @import("./common.zig");
      2 const comparef = @import("./comparef.zig");
      3 
      4 pub const panic = common.panic;
      5 
      6 comptime {
      7     if (common.want_aeabi) {
      8         @export(&__aeabi_fcmpun, .{ .name = "__aeabi_fcmpun", .linkage = common.linkage, .visibility = common.visibility });
      9     } else {
     10         @export(&__unordsf2, .{ .name = "__unordsf2", .linkage = common.linkage, .visibility = common.visibility });
     11     }
     12 }
     13 
     14 pub fn __unordsf2(a: f32, b: f32) callconv(.c) i32 {
     15     return comparef.unordcmp(f32, a, b);
     16 }
     17 
     18 fn __aeabi_fcmpun(a: f32, b: f32) callconv(.{ .arm_aapcs = .{} }) i32 {
     19     return comparef.unordcmp(f32, a, b);
     20 }