>>>>> "W" == Wizard  <[EMAIL PROTECTED]> writes:

  W> Uri Guttman wrote:
  >> but having parrot op codes map to special instructions
  >> makes sense only if we are doing some form of machine instruction
  >> generation as with JIT or TIL.

  W> Actually, I wasn't necessarily asking for any special ops (I'm not
  W> actually asking for anything, it's just a suggestion), just that
  W> the boolean math operations use a specific register or registers. I
  W> think this would make implementing code generation on those
  W> platforms more straight-forward.

which level of code generation are you refering to? parrot op codes or
machine instructions? 

  W> Things like:
  W>    if( $port_read && 0xF7 ) {...
  W> would tell perl to place the word into the bool-specific register, and the
  W> implementation for the platform could then see that the operation on that
  W> register would be a more likely candidate for optimizations such as:
  W>    LOW B0, AX     ; get low-order byte of bool register (from DATA?)
  W>    BITT B0, 4     ; test bit4 of B0
  W> or whatever the actual ASM ops are.

same question.

  W>   If the word were to be randomly assigned to any register, then
  W> all similar operations would need to be tested for those potential
  W> optimizations. That's not impossible, however in RT/embedded
  W> systems those ticks are at a premium.

again, i think you are conflating parrot registers with machine
registers. they are not the same and there is no mapping from one to the
other on any particular platform. when we get to TIL or JIT which both
will generate real machine code, then architecture specific
optimizations will be addressed. right now the actual machine
architecture is (mostly) irrelevant in discussing parrot op
codes. parrot op codes will be implemented in portable c and not in
platform dependent assembler for the obvious portability reasons.

uri

PS. my cc's to you are bouncing with a delivery warning. this is replied
only to the list.




-- 
Uri Guttman  ---------  [EMAIL PROTECTED]  ----------  http://www.sysarch.com
SYStems ARCHitecture and Stem Development ------ http://www.stemsystems.com
Search or Offer Perl Jobs  --------------------------  http://jobs.perl.org

Reply via email to