Contact/support | Changelog

.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
decodeFloatzuIntzh_fast
{
    W_ p;
    F_ arg;
    W_ tmp1, tmp2;

    /* arguments: F1 = Float# */
    arg = F1;

    tmp1 = Sp - 4;
    tmp2 = Sp - 8;
    Sp = Sp - 8;

    /* Perform the operation */
    foreign "C" __decodeFloat_Int(tmp1 "ptr", tmp2 "ptr", arg) [];

    Sp = Sp + 8;

    /* returns: (Int# (mantissa), Int# (exponent)) */
    RET_NN(W_[tmp1], W_[tmp2]);
}


decodeDoublezu2Intzh_fast
{
    D_ arg;
    W_ p;
    W_ tmp1, tmp2, tmp3, tmp4;

    /* arguments: D1 = Double# */
    arg = D1;

    tmp1 = Sp - 16;
    tmp2 = Sp - 12;
    tmp3 = Sp - 8;
    tmp4 = Sp - 4;
    Sp = Sp - 16;

    /* Perform the operation */
    foreign "C" __decodeDouble_2Int(tmp1 "ptr", tmp2 "ptr",
                                    tmp3 "ptr", tmp4 "ptr",
                                    arg) [];

    Sp = Sp + 16;

    /* returns:
       (Int# (mant sign), Word# (mant high), Word# (mant low), Int# (expn)) */
    RET_NNNN(W_[tmp1], W_[tmp2], W_[tmp3], W_[tmp4]);
}