zig

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

extendsfdf2.zig (644B) - Raw


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