Loading crypto/perlasm/x86gas.pl +3 −1 Original line number Diff line number Diff line Loading @@ -160,7 +160,9 @@ sub ::comment } sub ::external_label { push(@out,".extern\t".&::LABEL($_[0],$nmdecor.$_[0])."\n"); } { foreach(@_) { push(@out,".extern\t".&::LABEL($_,$nmdecor.$_)."\n"); } } sub ::public_label { push(@out,".globl\t".&::LABEL($_[0],$nmdecor.$_[0])."\n"); } Loading crypto/perlasm/x86masm.pl +8 −2 Original line number Diff line number Diff line Loading @@ -16,6 +16,10 @@ sub ::generic $arg[0] =~ s/0x([0-9a-f]+)/0$1h/oi if (defined($arg[0])); $arg[1] =~ s/0x([0-9a-f]+)/0$1h/oi if (defined($arg[1])); # fix xmm references $arg[0] =~ s/\b[A-Z]+WORD\s+PTR/XMMWORD PTR/i if ($arg[1]=~/\bxmm[0-7]\b/i); $arg[1] =~ s/\b[A-Z]+WORD\s+PTR/XMMWORD PTR/i if ($arg[0]=~/\bxmm[0-7]\b/i); &::emit($opcode,@arg); 1; } Loading Loading @@ -132,7 +136,9 @@ sub ::comment { foreach (@_) { push(@out,"\t; $_\n"); } } { my $l=shift; push(@out,$l.($l=~/^\Q${::lbdecor}\E[0-9]{3}/?":\n":"::\n")); }; sub ::external_label { push(@out, "EXTERN\t".&::LABEL($_[0],$nmdecor.$_[0]).":NEAR\n"); } { foreach(@_) { push(@out, "EXTERN\t".&::LABEL($_,$nmdecor.$_).":NEAR\n"); } } sub ::public_label { push(@out,"PUBLIC\t".&::LABEL($_[0],$nmdecor.$_[0])."\n"); } Loading @@ -155,7 +161,7 @@ sub ::initseg { my $f=$nmdecor.shift; $initseg.=<<___; .CRT\$XCU SEGMENT DWORD PUBLIC DATA .CRT\$XCU SEGMENT DWORD PUBLIC 'DATA' EXTERN $f:NEAR DD $f .CRT\$XCU ENDS Loading crypto/perlasm/x86nasm.pl +3 −1 Original line number Diff line number Diff line Loading @@ -123,7 +123,9 @@ ___ sub ::comment { foreach (@_) { push(@out,"\t; $_\n"); } } sub ::external_label { push(@out,"${drdecor}extern\t".&::LABEL($_[0],$nmdecor.$_[0])."\n"); } { foreach(@_) { push(@out,"${drdecor}extern\t".&::LABEL($_,$nmdecor.$_)."\n"); } } sub ::public_label { push(@out,"${drdecor}global\t".&::LABEL($_[0],$nmdecor.$_[0])."\n"); } Loading Loading
crypto/perlasm/x86gas.pl +3 −1 Original line number Diff line number Diff line Loading @@ -160,7 +160,9 @@ sub ::comment } sub ::external_label { push(@out,".extern\t".&::LABEL($_[0],$nmdecor.$_[0])."\n"); } { foreach(@_) { push(@out,".extern\t".&::LABEL($_,$nmdecor.$_)."\n"); } } sub ::public_label { push(@out,".globl\t".&::LABEL($_[0],$nmdecor.$_[0])."\n"); } Loading
crypto/perlasm/x86masm.pl +8 −2 Original line number Diff line number Diff line Loading @@ -16,6 +16,10 @@ sub ::generic $arg[0] =~ s/0x([0-9a-f]+)/0$1h/oi if (defined($arg[0])); $arg[1] =~ s/0x([0-9a-f]+)/0$1h/oi if (defined($arg[1])); # fix xmm references $arg[0] =~ s/\b[A-Z]+WORD\s+PTR/XMMWORD PTR/i if ($arg[1]=~/\bxmm[0-7]\b/i); $arg[1] =~ s/\b[A-Z]+WORD\s+PTR/XMMWORD PTR/i if ($arg[0]=~/\bxmm[0-7]\b/i); &::emit($opcode,@arg); 1; } Loading Loading @@ -132,7 +136,9 @@ sub ::comment { foreach (@_) { push(@out,"\t; $_\n"); } } { my $l=shift; push(@out,$l.($l=~/^\Q${::lbdecor}\E[0-9]{3}/?":\n":"::\n")); }; sub ::external_label { push(@out, "EXTERN\t".&::LABEL($_[0],$nmdecor.$_[0]).":NEAR\n"); } { foreach(@_) { push(@out, "EXTERN\t".&::LABEL($_,$nmdecor.$_).":NEAR\n"); } } sub ::public_label { push(@out,"PUBLIC\t".&::LABEL($_[0],$nmdecor.$_[0])."\n"); } Loading @@ -155,7 +161,7 @@ sub ::initseg { my $f=$nmdecor.shift; $initseg.=<<___; .CRT\$XCU SEGMENT DWORD PUBLIC DATA .CRT\$XCU SEGMENT DWORD PUBLIC 'DATA' EXTERN $f:NEAR DD $f .CRT\$XCU ENDS Loading
crypto/perlasm/x86nasm.pl +3 −1 Original line number Diff line number Diff line Loading @@ -123,7 +123,9 @@ ___ sub ::comment { foreach (@_) { push(@out,"\t; $_\n"); } } sub ::external_label { push(@out,"${drdecor}extern\t".&::LABEL($_[0],$nmdecor.$_[0])."\n"); } { foreach(@_) { push(@out,"${drdecor}extern\t".&::LABEL($_,$nmdecor.$_)."\n"); } } sub ::public_label { push(@out,"${drdecor}global\t".&::LABEL($_[0],$nmdecor.$_[0])."\n"); } Loading