#1885: Parrot_load_bytecode should only load bytecode
-------------------------+--------------------------------------------------
 Reporter:  whiteknight  |       Owner:  cotto   
     Type:  RFC          |      Status:  new     
 Priority:  normal       |   Milestone:          
Component:  core         |     Version:  master  
 Severity:  medium       |    Keywords:  pir, pbc
     Lang:               |       Patch:          
 Platform:  all          |  
-------------------------+--------------------------------------------------

Comment(by whiteknight):

 Thanks for the comments Patrick. One question I have is whether the call
 "load_bytecode 'foo.pir'" Always triggers the :load functions and not the
 :init functions. For a .pbc file I agree that triggering the :load
 functions is the expected behavior, but I would be very very surprised if
 IMCC were smart enough to determine that it should trigger :load and not
 :init after compiling from the load_bytecode opcode.

 Considering that :init and :immediate flags on subs are often used to
 update the constants table, I would be extremely surprised if
 "load_bytecode 'foo.pir'" did not trigger the :init functions. It may also
 trigger the :load functions too. I think we should put together a test for
 this behavior.

 Also, I thought there was a way to output .pbc files from Parrot PIR code.
 If there isn't one, we need to make creating it a high priority.

 So it seems like we have a few steps to tackle first (I'll lay out some
 things in a tasklist page on the wiki eventually):
  - Figure out what, exactly, load_bytecode does.
  - Figure out whether loading a .pir file is actually faster than loading
 a .pbc file in current Parrot and, if so, why. This should not be the case
 and if it is we have a serious problem.
  - Create a new compiler compreg interface for IMCC that would perform the
 kinds of functions we need it to perform

 So this is turning out to be a bigger task than I originally thought but I
 am becoming more and more convinced that it is necessary.

-- 
Ticket URL: <https://trac.parrot.org/parrot/ticket/1885#comment:7>
Parrot <https://trac.parrot.org/parrot/>
Parrot Development
_______________________________________________
parrot-tickets mailing list
[email protected]
http://lists.parrot.org/mailman/listinfo/parrot-tickets

Reply via email to