This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
captureexistsnamed | |
capturehasnameds | |
x_posixerrno | |
r_atpos | |
r_atpos_i | |
r_atpos_n | |
r_bindpos | |
r_bindpos_i | |
r_bindpos_n | |
r_elems |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
my @array := nqp::list; | |
my int $i := 0; | |
while $i < 20000 { | |
nqp::bindpos(@array, $i, nqp::coerce_is($i)); | |
$i := $i + 1; | |
}; | |
say(nqp::join(',', @array)); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sub A($k, $x1, $x2, $x3, $x4, $x5) { if ($k <= 0) { return $x4() + $x5() }; my $B := sub () { $k--; A($k, $B, $x1, $x2, $x3, $x4) }; $B() }; sub K($n) { sub () { $n } }; say(A(18, K(1), K(-1), K(-1), K(1), K(0) )) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
C:\Users\mwilson\src\MoarVM\nqp-cc>prove -vv -e "..\moarvm nqp.moarvm" t\nqp | |
t\nqp\01-literals.t ................... | |
1..9 | |
ok 1 | |
ok 2 | |
ok 3 | |
ok 4 | |
ok 5 | |
ok 6 | |
ok 7 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class FooFOO { | |
my %bar := nqp::hash( | |
'Æ' , 'Æ', | |
'Æ' , 'Æ', | |
'&' , '&', | |
'&' , '&', | |
'Á' , 'Á', | |
'Á' , 'Á', | |
'Ă' , 'Ă', | |
'Â' , 'Â', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mwilson@host06:~/src/MoarVM/nqp-cc$ ../moarvm "Multiple allocating threads work large heap usage.moarvm" |tee out.txt |llvm-symbolizer-3.4 ; cat out.txt | |
Before new threads | |
In new thread | |
In new thread | |
In new thread | |
In new thread | |
Lived until after joins | |
mwilson@host06:~/src/MoarVM/nqp-cc$ ../moarvm "Multiple allocating threads work large heap usage.moarvm" |tee out.txt |llvm-symbolizer-3.4 ; cat out.txt | |
ASAN:SIGSEGV | |
================================================================= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sub ndr(*@vals, Int :$radix is copy where ($radix||=10) > 0 && True) { | |
1+floor log (1 max [max] @vals>>.abs), $radix | |
}; | |
say ndr(40,50,60); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
my \size = 500; | |
my \reps = 100; | |
my $a = []; | |
for 1..size { $a[$_ - 1] = $_ } | |
my $s = now; | |
for 1..reps { | |
my @b = $a[1..($a - 1)]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
=head2 The magic input handle | |
The magic command-line input handle is C<$*ARGFILES>. | |
=end | |
say 3333 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
export PATH=/home/p6eval/nqp-jvm/nqp/install/bin:/home/p6eval/nqp-jvm/jdk1.7.0/bin:/home/p6eval/nqp-jvm/jdk1.7.0/jre/bin:/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/games | |
cd | |
set -e | |
echo -e "\n\nNew nqp-jvm build" | |
date | |
cd nqp-jvm/nqp | |
git fetch origin | |
if git log HEAD..origin/master --oneline | |
then |