iurly at writeme.com
Mon Jun 30 03:52:01 PDT 2003
(especially the JIT back-end coders)
does anyone have any idea why _slot_slot_fconst is declared
void _slot_slot_fconst(SlotInfo*, SlotInfo*, double, ifunc, int)
shouldn't there be a float instead?
I took a quick look at the back-ends who actually use it (alpha, arm,
i386, ia64), and they are all restricted to a few wired values (like 1.0,
2.0, 10.0 and so on) so this is never a problem for them.
However, since my architecture does not provide native floating
point support, I can move any fp constant to any register as an immediate.
This casting from float to double, though, messes everything up when I
get the const value with const_float(2) if the constant is not some "nice"
value. Note that the ARM, i386 and ia64 ports also use const_float(2) and
that IMHO is an inconsistency.
So I am going to change _slot_slot_fconst to (SlotInfo*, SlotInfo*, float,
ifunc, int). Please let me know if I should send a patch (for jit, jit3
and alpha) or if I am just insane.
More information about the kaffe