harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Egor Pasko <egor.pa...@gmail.com>
Subject Re: [jitrino]HIR instructions
Date Thu, 01 Mar 2007 11:46:24 GMT
On the 0x28C day of Apache Harmony Estelle Liu wrote:
> hi,
> there are some tau instructions of HIR such as Op_TauDiv and Op_TauLdInd,
> what do they stand for?
> How can I get descriptions about HIR instructions?


there is no complete reference guide for HIR instructions yet. How do
we tell what operations' semantics are?  The
jitrino/src/optimizer/Opcode.cpp file helps. For example:

    { Op_TauDiv,                false, MB::Movable,       MK::Signed_and_Strict,         
           "div   ",        "div%m   %0,%1 ((%2)) -) %l",             }, // (opnds must already
be checked for 0/overflow)

"div" says it is division. On printing it tells about 3 source
operands (%0, %1, %2) and one destination operand (%l). Operand ((%2))
is a "tau-operand" (because in double-brachets) that comes from
instruction performing a zero-check (with this tau-operand we ensure
that zero-check is performed before the actual division).

    { Op_TauLdInd,              false, MB::Load,          MK::AutoCompress_Speculative,  
           "ldind",         "ldind%m:%t [%0] ((%1,%2)) -) %l",          },

This is an indirect load from memory :)
Checked with two tau operands (null-check and bounds-check, AFAIR)

Egor Pasko

View raw message