From 7e74642b02956c635cd50cdcfeb94741dba17fe8 Mon Sep 17 00:00:00 2001 From: florian Date: Sun, 1 Aug 1999 18:28:09 +0000 Subject: [PATCH] * modifications for the new code generator --- compiler/ag386bin.pas | 8 ++++++-- compiler/ag386nsm.pas | 8 ++++++-- compiler/pdecl.pas | 19 +++++++++++++++++-- compiler/pexpr.pas | 12 +++++++++--- compiler/tcflw.pas | 7 ++++--- 5 files changed, 42 insertions(+), 12 deletions(-) diff --git a/compiler/ag386bin.pas b/compiler/ag386bin.pas index 88788ceb2e..4e72d0e458 100644 --- a/compiler/ag386bin.pas +++ b/compiler/ag386bin.pas @@ -501,7 +501,8 @@ unit ag386bin; else if l>1 then objectalloc^.sectionalign(2); pai_datablock(hp)^.sym^.typ:=AS_LOCAL; - pai_datablock(hp)^.sym^.setaddress(objectalloc^.currsec,objectalloc^.sectionsize,pai_datablock(hp)^.size); + pai_datablock(hp)^.sym^.setaddress(objectalloc^.currsec,objectalloc^.sectionsize, + pai_datablock(hp)^.size); objectalloc^.sectionalloc(pai_datablock(hp)^.size); end; end @@ -905,7 +906,10 @@ unit ag386bin; end. { $Log$ - Revision 1.20 1999-07-31 12:33:11 peter + Revision 1.21 1999-08-01 18:28:09 florian + * modifications for the new code generator + + Revision 1.20 1999/07/31 12:33:11 peter * fixed smartlinking Revision 1.19 1999/07/22 09:37:30 florian diff --git a/compiler/ag386nsm.pas b/compiler/ag386nsm.pas index 77c06faf92..c0b5f35240 100644 --- a/compiler/ag386nsm.pas +++ b/compiler/ag386nsm.pas @@ -499,7 +499,8 @@ unit ag386nsm; sep:=#9 else sep:=','; - s:=s+sep+getopstr(pai386(hp)^.oper[i],pai386(hp)^.opsize,pai386(hp)^.opcode,pai386(hp)^.ops,(i=2)); + s:=s+sep+getopstr(pai386(hp)^.oper[i],pai386(hp)^.opsize,pai386(hp)^.opcode, + pai386(hp)^.ops,(i=2)); end; end; end; @@ -602,7 +603,10 @@ ait_stab_function_name : ; end. { $Log$ - Revision 1.46 1999-07-22 09:37:33 florian + Revision 1.47 1999-08-01 18:28:10 florian + * modifications for the new code generator + + Revision 1.46 1999/07/22 09:37:33 florian + resourcestring implemented + start of longstring support diff --git a/compiler/pdecl.pas b/compiler/pdecl.pas index 3d54d0fbf9..4a0fc27501 100644 --- a/compiler/pdecl.pas +++ b/compiler/pdecl.pas @@ -57,7 +57,10 @@ unit pdecl; uses cobjects,scanner,aasm,tree,pass_1,strings, - files,types,verbose,systems,import,tccnv + files,types,verbose,systems,import +{$ifndef newcg} + ,tccnv +{$endif newcg} {$ifdef GDB} ,gdb {$endif GDB} @@ -1129,7 +1132,10 @@ unit pdecl; do_firstpass(pt); if p^.proptype^.deftype=setdef then begin +{$ifndef newcg} + {!!!!!!!!!!} arrayconstructor_to_set(pt); +{$endif newcg} do_firstpass(pt); end; pt:=gentypeconvnode(pt,p^.proptype); @@ -1439,7 +1445,9 @@ unit pdecl; oldparse_only:=parse_only; parse_only:=true; parse_proc_dec; +{$ifndef newcg} parse_object_proc_directives(aktprocsym); +{$endif newcg} if (aktprocsym^.definition^.options and pomsgint)<>0 then aktclass^.options:=aktclass^.options or oo_hasmsgint; if (aktprocsym^.definition^.options and pomsgstr)<>0 then @@ -1454,7 +1462,9 @@ unit pdecl; oldparse_only:=parse_only; parse_only:=true; constructor_head; +{$ifndef newcg} parse_object_proc_directives(aktprocsym); +{$endif newcg} if (aktprocsym^.definition^.options and povirtualmethod)<>0 then aktclass^.options:=aktclass^.options or oo_hasvirtual; parse_only:=oldparse_only; @@ -1468,7 +1478,9 @@ unit pdecl; oldparse_only:=parse_only; parse_only:=true; destructor_head; +{$ifndef newcg} parse_object_proc_directives(aktprocsym); +{$endif newcg} if (aktprocsym^.definition^.options and povirtualmethod)<>0 then aktclass^.options:=aktclass^.options or oo_hasvirtual; parse_only:=oldparse_only; @@ -2291,7 +2303,10 @@ unit pdecl; end. { $Log$ - Revision 1.137 1999-07-29 20:54:02 peter + Revision 1.138 1999-08-01 18:28:11 florian + * modifications for the new code generator + + Revision 1.137 1999/07/29 20:54:02 peter * write .size also Revision 1.136 1999/07/27 23:42:11 peter diff --git a/compiler/pexpr.pas b/compiler/pexpr.pas index aef70e3968..6e496b4d0a 100644 --- a/compiler/pexpr.pas +++ b/compiler/pexpr.pas @@ -48,7 +48,10 @@ unit pexpr; uses globtype,systems,tokens, cobjects,globals,scanner,aasm,pass_1, - hcodegen,types,verbose,strings,tccal + hcodegen,types,verbose,strings +{$ifndef newcg} + ,tccal +{$endif newcg} { parser specific stuff } ,pbase,pdecl { processor specific stuff } @@ -125,7 +128,7 @@ unit pexpr; { support if procvar then for tp7 and many other expression like this } Store_valid:=Must_be_valid; Must_be_valid:=false; - firstpass(p); + do_firstpass(p); Must_be_valid:=Store_valid; if not(getprocvar) and (p^.resulttype^.deftype=procvardef) then begin @@ -2061,7 +2064,10 @@ unit pexpr; end. { $Log$ - Revision 1.126 1999-07-30 12:28:40 peter + Revision 1.127 1999-08-01 18:28:13 florian + * modifications for the new code generator + + Revision 1.126 1999/07/30 12:28:40 peter * fixed crash with unknown id and colon parameter in write Revision 1.125 1999/07/27 23:42:14 peter diff --git a/compiler/tcflw.pas b/compiler/tcflw.pas index ddd108f4f5..4c5548b0cd 100644 --- a/compiler/tcflw.pas +++ b/compiler/tcflw.pas @@ -236,7 +236,6 @@ implementation old_t_times:=t_times; if not(cs_littlesize in aktglobalswitches) then t_times:=t_times*8; - cleartempgen; if assigned(p^.t1) then begin @@ -244,7 +243,6 @@ implementation if codegenerror then exit; end; - { save counter var } p^.t2:=getcopy(p^.left^.left); @@ -495,7 +493,10 @@ implementation end. { $Log$ - Revision 1.12 1999-06-30 22:16:25 florian + Revision 1.13 1999-08-01 18:28:15 florian + * modifications for the new code generator + + Revision 1.12 1999/06/30 22:16:25 florian * use of is_ordinal checked: often a qword/int64 isn't allowed (case/for ...) * small qword problems fixed