Permalink
Switch branches/tags
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
41 lines (24 sloc) 987 Bytes

Bootstrapping procedure for NQP

NPQ is a bootstrapped compiler, which means that it uses itself to compile itself.

To make the first compilation possible under MoarVM, a compiled version of the compiler is stored in src/vm/moar/stage0/*.moarvm and included in the source code repository.

When you make changes to the compiler, eventually you need to update these stage0 files.

Here is how you proceed to update the MoarVM bootstrapping files in NQP. At any stage, if make test fails, don't go ahead with the following steps, but fix the problem first.

(Note: the equivalent under JVM is src/vm/jvm/stage0/*.jar with the update target make j-bootstrap-files)

  • Make your changes, run make test

  • Run make m-bootstrap-files and make test

  • Commit the non-bootstrap files that you modified yourself

  • Commit the bootstrap files

Historic References: http://irclog.perlgeek.de/perl6/2010-04-22#i_2253227