Skip to content
Snippets Groups Projects
Commit 9ade9894 authored by Simon Marlow's avatar Simon Marlow
Browse files

[project @ 1999-08-02 10:35:53 by simonmar]

Oops, back out most of last revision.  Other changes crept in by mistake.
parent 57e017ff
No related merge requests found
......@@ -147,7 +147,7 @@ sub init_TARGET_STUFF {
$T_X86_PRE_LLBL = '.L';
$T_X86_BADJMP = '^\tjmp [^\.\*]';
$T_MOVE_DIRVS = '^(\s*(\.(p2)?align\s+\d+(,0x90)?|\.globl\s+\S+|\.text|\.data|\.section\s+.*|\.size\s+.*|\.type\s+.*|\.Lfe.*\n\t\.size\s+.*|\.ident.*)\n)';
$T_MOVE_DIRVS = '^(\s*(\.(p2)?align\s+\d+(,0x90)?|\.globl\s+\S+|\.text|\.data|\.section\s+.*|\.type\s+.*|\.Lfe.*\n\t\.size\s+.*|\.size\s+.*|\.ident.*)\n)';
$T_COPY_DIRVS = '\.(globl)';
if ( $TargetPlatform =~ /freebsd3/ ) {
......@@ -684,7 +684,7 @@ sub mangle_asm {
}
die "Prologue junk?: $p\n" if $p =~ /^\t[^\.]/
&& $TargetPlatform !~ /^(powerpc-|i386-)/; #ToDo: remove test
&& $TargetPlatform !~ /^powerpc-/; #ToDo: remove test
# glue together what's left
$c = $p . $r;
......@@ -704,7 +704,6 @@ sub mangle_asm {
$e =~ s/^\tret\n//;
$e =~ s/^\tpopl \%edi\n//;
$e =~ s/^\tpopl \%esi\n//;
$e =~ s/^\tpopl \%ebx\n//;
$e =~ s/^\tpopl \%ecx\n//;
$e =~ s/^\taddl \$\d+,\%esp\n//;
} elsif ($TargetPlatform =~ /^m68k-/) {
......@@ -745,7 +744,7 @@ sub mangle_asm {
# On Alphas, the prologue mangling is done a little later (below)
# toss all calls to __DISCARD__
$c =~ s/^\t(call|jbsr|jal)\s+$TUS[@]?__DISCARD__(\@PLT)?\n//go;
$c =~ s/^\t(call|jbsr|jal)\s+$TUS[@]?__DISCARD__\n//go;
# MIPS: that may leave some gratuitous asm macros around
# (no harm done; but we get rid of them to be tidier)
......@@ -971,9 +970,7 @@ sub mangle_asm {
$chk[$infochk{$symb}] =~ s/\.long ([A-Za-z]\S+_upd)/\.long \.\1/;
print OUTASM $chk[$infochk{$symb}];
} else {
# for shared libs --SDM
print OUTASM $chk[$infochk{$symb}];
# print OUTASM &rev_tbl($symb, $chk[$infochk{$symb}], 1);
print OUTASM &rev_tbl($symb, $chk[$infochk{$symb}], 1);
}
# entry code will be put here!
......@@ -1012,10 +1009,6 @@ sub mangle_asm {
# The next two only apply if we're not stealing %esi or %edi.
$c =~ s/^\tmovl \$${T_US}${symb}_fast\d*,\%esi\n\tjmp \*\%esi\n// if ($StolenX86Regs < 3);
$c =~ s/^\tmovl \$${T_US}${symb}_fast\d*,\%edi\n\tjmp \*\%edi\n// if ($StolenX86Regs < 4);
# for PIC code
$c =~ s/^\tleal ${T_US}${symb}_fast\d*\@GOTOFF\(\%ebx\),\%eax\n\tjmp \*\%eax\n//;
$c =~ s/^\tjmp \*${T_US}${symb}_fast\d*\@GOT\(\%ebx\)\n//;
$c =~ s/^\.LPR\d+\:\n\tmovl \(\%esp\),\%ebx\n\tret\n//;
} elsif ( $TargetPlatform =~ /^mips-/ ) {
$c =~ s/^\tjmp \$31,\(\$27\),0\n\t\.align 4\n\t\.end/\t.align 4\n\t.end/;
} elsif ( $TargetPlatform =~ /^m68k-/ ) {
......@@ -1088,9 +1081,7 @@ sub mangle_asm {
print OUTASM ".${symb}_vtbl:\n";
print OUTASM $chk[$vectorchk{$symb}];
} else {
# for shared libs --SDM print OUTASM $chk[$vectorchk{$symb}];
print OUTASM $chk[$vectorchk{$symb}];
# print OUTASM &rev_tbl($symb, $chk[$vectorchk{$symb}], 0);
print OUTASM &rev_tbl($symb, $chk[$vectorchk{$symb}], 0);
}
# direct return code will be put here!
$chkcat[$vectorchk{$symb}] = 'DONE ALREADY';
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment