Skip to content

Commit

Permalink
Don't run every proto during CORE.setting build
Browse files Browse the repository at this point in the history
We can't properly do the analysis as to whether or not we need to run
the proto since we're not yet properly bootstrapped. However, assume
that we don't need to run any of them. This saves rather a lot of time,
because to run the proto involves compiling it. It also at present
triggers the compilation of all multi candidates and would compile them
in duplicate.
  • Loading branch information
jnthn committed Sep 28, 2021
1 parent dc07005 commit 11e7313
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/vm/moar/dispatchers.nqp
Original file line number Diff line number Diff line change
Expand Up @@ -1143,9 +1143,12 @@ nqp::dispatch('boot-syscall', 'dispatcher-register', 'raku-multi',
# however, nice when we can go straight to a candidate. To see if that's the
# case, we have to introspect the signature.
sub simple-args-proto($callee, $capture) {
# If we're compiling the setting, all sorts of things missing, so don't
# even try.
return 0 if $*COMPILING_CORE_SETTING;
# If we're compiling the setting, all sorts of things we need to do the
# analysis are missing, so don't even try. Nothing invoked in the
# CORE.setting build today that has an onlystar proto actually needs
# its proto invoking today, so we also regard them all as simple, to
# avoid a bunch of throwaway compilations.
return 1 if $*COMPILING_CORE_SETTING;

# If it's out of range so far as arity goes, we'll call the proto to
# produce an error.
Expand Down

0 comments on commit 11e7313

Please sign in to comment.