On 2010-08-26, at 8:37 AM, chevalma@iro.umontreal.ca wrote:
I don't understand your point. Can you elaborate?
There are currently 4 add instructions in the IR (and 3 of each other arithmetic instruction). One for untyped values, one for integer values, one for floating-point, and one for integer add with overflow.
I am considering merging the untyped, integer and floating-point instructions (but not the add with overflow) into a single IR instruction. This would simplify the IR itself, and the production of IIR code.
- Maxime
So there will only be an "untyped add" instruction, and that instruction will dispatch at runtime to do the right thing? That seems fine for the "high level" IR (because it directly corresponds to the JS semantics).
I have an unrelated question. What are the allowed operands of IR operations like "add"? Is it always a temporary, or can it also be a constant? Anything else?
Marc