|
@@ -79,10 +79,7 @@ interface
|
|
|
{$ifdef m68k}
|
|
|
ait_labeled_instruction,
|
|
|
{$endif m68k}
|
|
|
-{$ifdef arm}
|
|
|
- ait_thumb_set,
|
|
|
-{$endif arm}
|
|
|
- ait_set,
|
|
|
+ ait_symbolpair,
|
|
|
ait_weak,
|
|
|
{ used to split into tiny assembler files }
|
|
|
ait_cutobject,
|
|
@@ -196,10 +193,7 @@ interface
|
|
|
{$ifdef m68k}
|
|
|
'labeled_instr',
|
|
|
{$endif m68k}
|
|
|
-{$ifdef arm}
|
|
|
- 'thumb_set',
|
|
|
-{$endif arm}
|
|
|
- 'set',
|
|
|
+ 'symbolpair',
|
|
|
'weak',
|
|
|
'cut',
|
|
|
'regalloc',
|
|
@@ -307,10 +301,7 @@ interface
|
|
|
ait_stab,ait_function_name,
|
|
|
ait_cutobject,ait_marker,ait_varloc,ait_align,ait_section,ait_comment,
|
|
|
ait_const,ait_directive,
|
|
|
-{$ifdef arm}
|
|
|
- ait_thumb_set,
|
|
|
-{$endif arm}
|
|
|
- ait_set,ait_weak,
|
|
|
+ ait_symbolpair,ait_weak,
|
|
|
ait_real_32bit,ait_real_64bit,ait_real_80bit,ait_comp_64bit,ait_real_128bit,
|
|
|
ait_symbol,
|
|
|
{$ifdef JVM}
|
|
@@ -368,6 +359,8 @@ interface
|
|
|
ash_savereg,ash_savexmm,ash_pushframe
|
|
|
);
|
|
|
|
|
|
+ TSymbolPairKind = (spk_set, spk_thumb_set);
|
|
|
+
|
|
|
|
|
|
const
|
|
|
regallocstr : array[tregalloctype] of string[10]=('allocated','released','sync','resized','used');
|
|
@@ -399,6 +392,9 @@ interface
|
|
|
'.seh_setframe','.seh_stackalloc','.seh_pushreg',
|
|
|
'.seh_savereg','.seh_savexmm','.seh_pushframe'
|
|
|
);
|
|
|
+ symbolpairkindstr: array[TSymbolPairKind] of string[11]=(
|
|
|
+ '.set', '.thumb_set'
|
|
|
+ );
|
|
|
|
|
|
type
|
|
|
{ abstract assembler item }
|
|
@@ -863,21 +859,16 @@ interface
|
|
|
tai_jcatch_class = class of tai_jcatch;
|
|
|
{$endif JVM}
|
|
|
|
|
|
- tai_set = class(tai)
|
|
|
+ tai_symbolpair = class(tai)
|
|
|
+ kind: TSymbolPairKind;
|
|
|
sym,
|
|
|
value: pshortstring;
|
|
|
- constructor create(const asym, avalue: string);
|
|
|
+ constructor create(akind: TSymbolPairKind; const asym, avalue: string);
|
|
|
destructor destroy;override;
|
|
|
constructor ppuload(t:taitype;ppufile:tcompilerppufile);override;
|
|
|
procedure ppuwrite(ppufile:tcompilerppufile);override;
|
|
|
end;
|
|
|
|
|
|
-{$ifdef arm}
|
|
|
- tai_thumb_set = class(tai_set)
|
|
|
- constructor create(const asym, avalue: string);
|
|
|
- end;
|
|
|
-{$endif arm}
|
|
|
-
|
|
|
tai_weak = class(tai)
|
|
|
sym: pshortstring;
|
|
|
constructor create(const asym: string);
|
|
@@ -1023,39 +1014,34 @@ implementation
|
|
|
ppufile.putstring(sym^);
|
|
|
end;
|
|
|
|
|
|
-{$ifdef arm}
|
|
|
- constructor tai_thumb_set.create(const asym, avalue: string);
|
|
|
- begin
|
|
|
- inherited create(asym, avalue);
|
|
|
- typ:=ait_thumb_set;
|
|
|
- end;
|
|
|
-{$endif arm}
|
|
|
-
|
|
|
- constructor tai_set.create(const asym, avalue: string);
|
|
|
+ constructor tai_symbolpair.create(akind: TSymbolPairKind; const asym, avalue: string);
|
|
|
begin
|
|
|
inherited create;
|
|
|
- typ:=ait_set;
|
|
|
+ kind:=akind;
|
|
|
+ typ:=ait_symbolpair;
|
|
|
sym:=stringdup(asym);
|
|
|
value:=stringdup(avalue);
|
|
|
end;
|
|
|
|
|
|
- destructor tai_set.destroy;
|
|
|
+ destructor tai_symbolpair.destroy;
|
|
|
begin
|
|
|
stringdispose(sym);
|
|
|
stringdispose(value);
|
|
|
inherited destroy;
|
|
|
end;
|
|
|
|
|
|
- constructor tai_set.ppuload(t: taitype; ppufile: tcompilerppufile);
|
|
|
+ constructor tai_symbolpair.ppuload(t: taitype; ppufile: tcompilerppufile);
|
|
|
begin
|
|
|
inherited ppuload(t,ppufile);
|
|
|
+ kind:=TSymbolPairKind(ppufile.getbyte);;
|
|
|
sym:=stringdup(ppufile.getstring);
|
|
|
value:=stringdup(ppufile.getstring);
|
|
|
end;
|
|
|
|
|
|
- procedure tai_set.ppuwrite(ppufile: tcompilerppufile);
|
|
|
+ procedure tai_symbolpair.ppuwrite(ppufile: tcompilerppufile);
|
|
|
begin
|
|
|
inherited ppuwrite(ppufile);
|
|
|
+ ppufile.putbyte(byte(kind));
|
|
|
ppufile.putstring(sym^);
|
|
|
ppufile.putstring(value^);
|
|
|
end;
|