Skip to content

Commit

Permalink
Improve the performance of signature binding
Browse files Browse the repository at this point in the history
Replacing `nqp::ctxcode(nqp::ctx)` pair with `nqp::curcode` reduces the
overall performance loss on a test script from 20-30% to 14-20% with 14%
being the most likely outcome.
  • Loading branch information
vrurg committed Nov 25, 2020
1 parent e46a1da commit b1f59a2
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/Perl6/Actions.nqp
Expand Up @@ -9235,9 +9235,7 @@ class Perl6::Actions is HLL::Actions does STDActions {
QAST::Var.new(:name($instantiated_code), :scope('local'), :decl('var')),
QAST::Op.new(
:op('getcodeobj'),
QAST::Op.new(
:op('ctxcode'),
QAST::Op.new(:op('ctx'))))));
QAST::Op.new(:op('curcode')))));
}
my $inst_param := QAST::Node.unique('__lowered_param_obj_');
$var.push(
Expand Down

0 comments on commit b1f59a2

Please sign in to comment.