Commit Graph

76 Commits

Author SHA1 Message Date
Jonas Maebe
edb2179730 + added freeintparaloc
* ppc get/freeintparaloc now check whether the parameter regs are
    properly allocated/deallocated (and get an extra list para)
  * ppc a_call_* now internalerrors if pi_do_call is not yet set
  * fixed lot of missing pi_do_call's
2003-06-07 18:57:04 +00:00
peter
047a066711 * procinlinenode removed
* aktexit2label removed, fast exit removed
  + tcallnode.inlined_pass_2 added
2003-05-26 21:17:17 +00:00
peter
05c05f2555 * failn removed
* inherited result code check moven to pexpr
2003-05-13 19:14:41 +00:00
peter
26d78ff5c9 * moved implicit exception frame from ncgutil to psub
* constructor/destructor helpers moved from cobj/ncgutil to psub
2003-05-11 21:37:03 +00:00
florian
9612e57805 * introduced defaultordconsttype to decribe the default size of ordinal constants
on 64 bit CPUs it's equal to cs64bitdef while on 32 bit CPUs it's equal to s32bitdef
  + added defines CPU32 and CPU64 for 32 bit and 64 bit CPUs
  * int64s/qwords are allowed as for loop counter on 64 bit CPUs
2003-05-01 07:59:42 +00:00
peter
60978ba89c * aktprocdef renamed to current_procdef
* procinfo renamed to current_procinfo
  * procinfo will now be stored in current_module so it can be
    cleaned up properly
  * gen_main_procsym changed to create_main_proc and release_main_proc
    to also generate a tprocinfo structure
  * fixed unit implicit initfinal
2003-04-27 11:21:32 +00:00
peter
7f14891d66 * aktprocdef cleanup, aktprocdef is now always nil when parsing
a new procdef declaration
  * aktprocsym removed
  * lexlevel removed, use symtable.symtablelevel instead
  * implicit init/final code uses the normal genentry/genexit
  * funcret state checking updated for new funcret handling
2003-04-27 07:29:50 +00:00
peter
61a964729e * removed load_funcret 2003-04-26 00:28:41 +00:00
peter
f4b818fc1d * removed funcretn,funcretsym, function result is now in varsym
and aliases for result and function name are added using absolutesym
  * vs_hidden parameter for funcret passed in parameter
  * vs_hidden fixes
  * writenode changed to printnode and released from extdebug
  * -vp option added to generate a tree.log with the nodetree
  * nicer printnode for statements, callnode
2003-04-25 20:59:33 +00:00
daniel
6aa01a99a9 * Ifdefs around a lot of calls to cleartempgen
* Fixed registers that are allocated but not freed in several nodes
  * Tweak to register allocator to cause less spills
  * 8-bit registers now interfere with esi,edi and ebp
    Compiler can now compile rtl successfully when using new register
    allocator
2003-04-25 08:25:26 +00:00
peter
47489f2376 * firstpass uses expectloc
* checks if there are differences between the expectloc and
    location.loc from secondpass in EXTDEBUG
2003-04-22 23:50:22 +00:00
peter
4a0bda8041 * don't allow var and out parameters as for loop counter 2003-03-20 15:54:46 +00:00
peter
2721d341f0 * merged some verbosity options.
* V_LineInfo is a verbosity flag to include line info
2003-01-09 21:52:37 +00:00
daniel
2930a10314 * Readded missing variable 2003-01-04 08:08:47 +00:00
peter
60b05c92de * fixed warning about unset funcret 2003-01-03 17:16:57 +00:00
daniel
5041b70618 * Removed ifdefs around notifications
ifdefs around for loop optimizations remain
2003-01-03 12:15:55 +00:00
daniel
158e9689d7 + Notification implementation complete
+ Add for loop code optimization using notifications
   results in 1.5-1.9% speed improvement in nestloop benchmark
   Optimization incomplete, compiler does not cycle yet with
   notifications enabled.
2002-12-31 09:55:58 +00:00
daniel
038fec836e * Some work on notifications 2002-12-30 22:44:53 +00:00
peter
42af4ce5b9 * do not allow threadvar as loop counter 2002-12-27 15:25:40 +00:00
florian
e8bb7d10c3 * loop node flags from node flags splitted 2002-11-28 11:17:01 +00:00
peter
f3fc72095f * splitted defbase in defutil,symutil,defcmp
* merged isconvertable and is_equal into compare_defs(_ext)
  * made operator search faster by walking the list only once
2002-11-25 17:43:16 +00:00
peter
a496dbe1ff * pass proccalloption to ret_in_xxx and push_xxx functions 2002-11-18 17:31:54 +00:00
peter
3a419bde8a * set funcret state for exit(0) 2002-10-20 15:31:49 +00:00
carl
67486c96c3 * fixes for Delphi 6 compilation
(warning : Some features do not work under Delphi)
2002-10-05 12:43:23 +00:00
peter
dcd9e0107c * old logs removed and tabs fixed 2002-09-07 15:25:00 +00:00
carl
6c2bede5a8 * second part bug report 1996 fix, testrange in cordconstnode
only called if option is set (also make parsing a tiny faster)
2002-09-07 12:16:03 +00:00
peter
274624f2f6 * assignn check in exitnode changed to use a separate boolean as the
assignn can be changed to a calln
2002-09-01 18:47:00 +00:00
daniel
4b82d30953 * Removed sets from Tcallnode.det_resulttype
+ Added read/write notifications of variables. These will be usefull
   for providing information for several optimizations. For example
   the value of the loop variable of a for loop does matter is the
   variable is read after the for loop, but if it's no longer used
   or written, it doesn't matter and this can be used to optimize
   the loop code generation.
2002-09-01 08:01:16 +00:00
daniel
3d7430e270 * Fixed the detection wether the first check of a for loop can be skipped 2002-08-22 15:15:20 +00:00
peter
91b49914f6 * More fixes for cross unit inlining, all tnodes are now implemented
* Moved pocall_internconst to po_internconst because it is not a
    calling type at all and it conflicted when inlining of these small
    functions was requested
2002-08-19 19:36:42 +00:00
florian
4144773f01 * result type handling in tcgcal.pass_2 overhauled
* better tnode.dowrite
  * some ppc stuff fixed
2002-08-17 22:09:43 +00:00
florian
e313bab4ff * first part of procinfo rewrite 2002-08-17 09:23:33 +00:00
daniel
0af1f3883c * Changed booleans into flags 2002-07-21 06:58:49 +00:00
florian
59abf2555b * types.pas renamed to defbase.pas because D6 contains a types
unit so this would conflicts if D6 programms are compiled
  + Willamette/SSE2 instructions to assembler added
2002-07-20 11:57:52 +00:00
daniel
c6f75def0c * Small mistake fixed; the skip test was done before we know the for node
is correct.
2002-07-20 11:18:18 +00:00
daniel
8cbd40c2f0 * The for node does a check if the first comparision can be skipped. I moved
the check from the second pass to the resulttype pass. The advantage is
  that the state tracker can now decide to skip the first comparision too.
2002-07-20 11:15:51 +00:00
daniel
bec9b5f988 * State tracker automatically changes while loops into repeat loops 2002-07-20 08:19:31 +00:00
daniel
7d66658fd4 * Further developed state tracking in whilerepeatn 2002-07-19 12:55:27 +00:00
daniel
399036f1c2 * State tracker work
* The whilen and repeatn are now completely unified into whilerepeatn. This
  allows the state tracker to change while nodes automatically into
  repeat nodes.
* Resulttypepass improvements to the notn. 'not not a' is optimized away and
  'not(a>b)' is optimized into 'a<=b'.
* Resulttypepass improvements to the whilerepeatn. 'while not a' is optimized
  by removing the notn and later switchting the true and falselabels. The
  same is done with 'repeat until not a'.
2002-07-19 11:41:34 +00:00
florian
ac8643e1d2 * raise takes now a void pointer as at and frame address
instead of a longint
2002-07-16 13:57:02 +00:00
florian
c3f4220f3b * readded removed changes 2002-07-15 18:03:14 +00:00
daniel
eeae0e4c00 + Added the beginning of a state tracker. This will track the values of
variables through procedures and optimize things away.
2002-07-14 18:00:43 +00:00
florian
336808f6c3 * start of the new generic parameter handling 2002-07-11 14:41:27 +00:00
peter
4285e99853 * internal linker
* reorganized aasm layer
2002-07-01 18:46:20 +00:00
peter
06ebac4e27 * readded missing revisions 2002-05-18 13:34:04 +00:00
carl
21b3a10f02 + defines.inc -> fpcdefs.inc to avoid conflicts if compiling by hand
+ try to fix temp allocation (still in ifdef)
+ generic constructor calls
+ start of tassembler / tmodulebase class cleanup
2002-05-16 19:46:34 +00:00
peter
2992e1819c * removed old logs and updated copyright year 2002-05-14 19:34:38 +00:00
peter
4dcd96747e * moved entry and exitcode to ncgutil and cgobj
* foreach gets extra argument for passing local data to the
    iterator function
  * -CR checks also class typecasts at runtime by changing them
    into as
  * fixed compiler to cycle with the -CR option
  * fixed stabs with elf writer, finally the global variables can
    be watched
  * removed a lot of routines from cga unit and replaced them by
    calls to cgobj
  * u32bit-s32bit updates for and,or,xor nodes. When one element is
    u32bit then the other is typecasted also to u32bit without giving
    a rangecheck warning/error.
  * fixed pascal calling method with reversing also the high tree in
    the parast, detected by tcalcst3 test
2002-05-12 16:53:04 +00:00
Jonas Maebe
7fb55bf4e4 + a_loadfpu_* and a_loadmm_* methods in tcg
* register allocation is now handled by a class and is mostly processor
    independent (+rgobj.pas and i386/rgcpu.pas)
  * temp allocation is now handled by a class (+tgobj.pas, -i386\tgcpu.pas)
  * some small improvements and fixes to the optimizer
  * some register allocation fixes
  * some fpuvaroffset fixes in the unary minus node
  * push/popusedregisters is now called rg.save/restoreusedregisters and
    (for i386) uses temps instead of push/pop's when using -Op3 (that code is
    also better optimizable)
  * fixed and optimized register saving/restoring for new/dispose nodes
  * LOC_FPU locations now also require their "register" field to be set to
    R_ST, not R_ST0 (the latter is used for LOC_CFPUREGISTER locations only)
  - list field removed of the tnode class because it's not used currently
    and can cause hard-to-find bugs
2002-03-31 20:26:33 +00:00
Jonas Maebe
a3455b27a4 * upper constant limits for "for" loops are now also converted to the
type of the counter var ('merged')
2001-11-19 14:21:30 +00:00