Commit Graph

218 Commits

Author SHA1 Message Date
peter
76a53a375d * varspez in calls to push_addr_param 2003-09-16 16:17:01 +00:00
peter
aca99d30e8 * fix previous commit, also include objectsymtable 2003-09-14 13:20:12 +00:00
peter
8dd0a4027a * support mulitple overloads in implementation, this is delphi
compatible
  * procsym only stores the overloads available in the interface
2003-09-14 12:58:00 +00:00
peter
6a8d5eb25d * NEWRA branch merged 2003-09-03 15:55:00 +00:00
florian
220e05dd5e * fixed arm concatcopy
+ arm support in the common compiler sources added
  * moved some generic cg code around
  + tfputype added
  * ...
2003-09-03 11:18:36 +00:00
daniel
cdb8a15f4a * Some more R_NO changes
* Preventive code to loadref added
2003-08-20 20:29:06 +00:00
peter
af3946938a * check if owner.defowner is valid when checking private/protected 2003-07-05 22:41:59 +00:00
pierre
ecaa77a503 * single threadvar debugging support 2003-07-04 22:41:41 +00:00
peter
0dceec9a64 * current_procdef removed, use current_procinfo.procdef instead 2003-06-13 21:19:30 +00:00
peter
e7975c7592 * re-resolving added instead of reloading from ppu
* tderef object added to store deref info for resolving
2003-06-07 20:26:32 +00:00
peter
5a59576557 * fix to compile without gdb 2003-06-05 17:53:30 +00:00
florian
b84cead281 * absolutesyms aren't fpuregable either 2003-06-02 22:59:17 +00:00
Jonas Maebe
7d1f5c8330 * fixed intregister bug
* fixed error in my previous commit: vo_(fpu)regable should only be set
    for (inline)localsymtable and (inline)parasymtable entries
2003-05-30 18:48:17 +00:00
Jonas Maebe
6c7f3ad02e * the vartype field of tvarsym is now a property, because is_XXXregable
must be updated when the vartype is changed
2003-05-30 13:35:10 +00:00
peter
92ee1804b6 * removed selfpointer_offset, vmtpointer_offset
* tvarsym.adjusted_address
  * address in localsymtable is now in the real direction
  * removed some obsolete globals
2003-05-15 18:58:53 +00:00
peter
b42efec29d * create rtti label using newasmsymboldata and update binding
only when calling tai_symbol.create
  * tai_symbol.create_global added
2003-05-12 18:13:57 +00:00
peter
1a2eedd767 * self moved to hidden parameter
* removed hdisposen,hnewn,selfn
2003-05-09 17:47:02 +00:00
peter
e2cbae0ff1 * vs_hidden replaced by is_hidden boolean 2003-05-05 14:53:16 +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
Jonas Maebe
e514b12f7a * fixed stabs generation for local variables on systems where they have
a positive offset relative to the stack/framepointer
2003-04-27 10:03:18 +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
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
peter
4cee86cad2 * fix operator overload search parameter order 2003-04-23 13:13:58 +00:00
peter
8da3f59d32 * vs_hidden released 2003-04-10 17:57:52 +00:00
peter
ec66760702 * store symoptions also for procdef
* check symoptions (private,public) when calculating possible
    overload candidates
2003-03-17 15:54:22 +00:00
peter
00e2ee165b * merged methodpointer fixes from 1.0.x 2003-01-15 01:44:32 +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
55a161bbbf * Tregister changed into a record 2003-01-08 18:43:56 +00:00
daniel
5041b70618 * Removed ifdefs around notifications
ifdefs around for loop optimizations remain
2003-01-03 12:15:55 +00:00
michael
fbd28675c9 + Patch from peter to support initial values for local variables 2003-01-02 11:14:02 +00:00
peter
d0725b2e7d * high value insertion changed so it works also when 2 parameters
are passed
2003-01-01 22:51:03 +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
c466e75da1 * fix crashes when searching symbols 2002-12-27 18:07:44 +00:00
peter
b52fbd46ba * fix stupid copy&paste bug in binary operator search 2002-12-20 16:02:22 +00:00
peter
dfb2918780 * fix order of procdefs in procsym, procdefs are now always appended
so that loading from a ppu will keep the same order. This is
    important for the generation of VMTs
2002-12-16 22:08:31 +00:00
peter
409bc6f4dc * better error message when no operator is found for equal 2002-12-11 22:39:23 +00:00
carl
081a4aab35 * 3% memory optimization
* changed some types
  + added type checking with different size for call node and for
     parameters
2002-12-07 14:27:07 +00:00
peter
dc66eafb0b * merged cdecl and array fixes 2002-12-06 17:51:09 +00:00
peter
3d696d9c7c * tvarsym.get_push_size replaced by paramanager.push_size 2002-11-27 20:04:09 +00:00
peter
26fcfc6b6f * only find real equal procvars 2002-11-27 02:34:20 +00:00
carl
6a52e7a9e5 - removed the invalid if <> checking (Delphi is strange on this)
+ implemented abstract warning on instance creation of class with
    abstract methods.
 * some error message cleanups
2002-11-25 18:43:31 +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
carl
60d17dbc01 * some small speed optimizations
+ added several new warnings/hints
2002-11-23 22:50:04 +00:00
carl
05d86bbef8 * memory optimization with tconstsym (1.5%) 2002-11-22 22:48:10 +00:00
peter
a496dbe1ff * pass proccalloption to ret_in_xxx and push_xxx functions 2002-11-18 17:31:54 +00:00
carl
64655be168 * memory optimization (3-4%) : cleanup of tai fields,
cleanup of tdef and tsym fields.
  * make it work for m68k
2002-11-17 16:31:55 +00:00
carl
53aa63ead1 + align RTTI tables 2002-11-09 15:30:07 +00:00
peter
fb36caedf1 * give correct fileposition for undefined forward procs 2002-10-13 21:33:37 +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
c597544d99 * split boolean check in two lines for easier debugging 2002-10-05 00:52:20 +00:00
florian
e1c908703a + constsym with type=constguid can be written to ppu now,
fixes web bug #1820
2002-09-26 12:04:53 +00:00
peter
cea50f7185 * add argument to equal_paras() to support default values or not 2002-09-16 14:11:12 +00:00
peter
a540ff122c * tdicationary.replace added to replace and item in a dictionary. This
is only allowed for the same name
  * varsyms are inserted in symtable before the types are parsed. This
    fixes the long standing "var longint : longint" bug
  - consume_idlist and idstringlist removed. The loops are inserted
    at the callers place and uses the symtable for duplicate id checking
2002-09-09 17:34:14 +00:00
carl
121dfde260 * bugfix 2109 (bad imho, but only way) 2002-09-08 11:10:17 +00:00
florian
e4664f0ed6 + tvarsym.paraitem added 2002-09-07 18:17:41 +00:00
peter
dcd9e0107c * old logs removed and tabs fixed 2002-09-07 15:25:00 +00:00
peter
20af604613 * memdebug enhancements 2002-09-05 19:29:42 +00:00
peter
93f33a3d0c * internalerror instead of crash in getprocdef 2002-09-05 14:51:42 +00:00
daniel
b0364566d1 * Make Tprocdef.defs protected 2002-09-03 16:26:26 +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
peter
a28f75ed03 * sym.insert_in_data removed
* symtable.insertvardata/insertconstdata added
  * removed insert_in_data call from symtable.insert, it needs to be
    called separatly. This allows to deref the address calculation
  * procedures now calculate the parast addresses after the procedure
    directives are parsed. This fixes the cdecl parast problem
  * push_addr_param has an extra argument that specifies if cdecl is used
    or not
2002-08-25 19:25:18 +00:00
peter
5c57932695 * fixed loop in concat_procdefs 2002-08-25 09:06:21 +00:00
peter
70028e433d * write address of varsym always 2002-08-20 16:54:40 +00:00
daniel
ba29715c7a * Tcallnode.det_resulttype rewritten 2002-08-20 10:31:26 +00:00
peter
98dd65b0f3 * inlining is now also allowed in interface
* renamed write/load to ppuwrite/ppuload
  * tnode storing in ppu
  * nld,ncon,nbas are already updated for storing in ppu
2002-08-18 20:06:23 +00:00
florian
e313bab4ff * first part of procinfo rewrite 2002-08-17 09:23:33 +00:00
carl
745efb2c47 * issameref() to test if two references are the same (then emit no opcodes)
+ ret_in_reg to replace ret_in_acc
    (fix some register allocation bugs at the same time)
  + save_std_register now has an extra parameter which is the
    usedinproc registers
2002-08-16 14:24:57 +00:00
florian
af4302bc67 * more fixes for ppc calling conventions 2002-08-13 21:40:55 +00:00
carl
9da171faf2 + stab register indexes for powerpc (moved from gdb to cpubase)
+ tprocessor enumeration moved to cpuinfo
  + linker in target_info is now a class
  * many many updates for m68k (will soon start to compile)
  - removed some ifdef or correct them for correct cpu
2002-08-12 15:08:39 +00:00
peter
425bb45ddc * renamed current_library to objectlibrary 2002-08-11 14:32:25 +00:00
peter
ac71268ce6 * saving of asmsymbols in ppu supported
* asmsymbollist global is removed and moved into a new class
    tasmlibrarydata that will hold the info of a .a file which
    corresponds with a single module. Added librarydata to tmodule
    to keep the library info stored for the module. In the future the
    objectfiles will also be stored to the tasmlibrarydata class
  * all getlabel/newasmsymbol and friends are moved to the new class
2002-08-11 13:24:10 +00:00
daniel
950b60d3f8 * Added important comment 2002-07-23 10:13:23 +00:00
daniel
46b8ed0657 * Tried to make Tprocsym.defs protected. I didn't succeed but the cleanups
are worth comitting.
2002-07-23 09:51:22 +00:00
daniel
94e5bd51a1 * Register variables are now possible for global variables too. This is
important for small programs without procedures.
2002-07-20 17:45:29 +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
florian
336808f6c3 * start of the new generic parameter handling 2002-07-11 14:41:27 +00:00
Jonas Maebe
cb3eb438b6 * memory leak fixes from Sergey Korshunoff 2002-07-10 07:24:40 +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
peter
70ff711f73 * mangledname rewrite, tprocdef.mangledname is now created dynamicly
in most cases and not written to the ppu
  * add mangeledname_prefix() routine to generate the prefix of
    manglednames depending on the current procedure, object and module
  * removed static procprefix since the mangledname is now build only
    on demand from tprocdef.mangledname
2002-04-19 15:46:01 +00:00
peter
2dcf2ee940 * give error when using enums with jumps as array index
* allow char as enum value
2002-04-16 16:12:47 +00:00
carl
6101b737db + target_info.size_of_pointer -> pointer_size
+ some cleanup of unused types/variables
2002-04-15 19:08:22 +00:00
carl
c00a004c98 + change unit use 2002-04-07 13:37:29 +00:00
peter
190ead04c0 * more fixes for protected handling 2002-02-03 09:30:03 +00:00
peter
60d2ddbbd5 * protected/private symbols parsing fixed 2001-12-31 16:59:41 +00:00
peter
e45bb82d81 * freemem change to value parameter
* torddef low/high range changed to int64
2001-12-03 21:48:41 +00:00
Jonas Maebe
879d8ccb44 * fixed web bug #1707:
* tvarsym.getvaluesize doesn't return 0 anymore for dynarrays (found
       by Florian)
     * in genrtti, some more ppointer(data)^ tricks were necessary
2001-11-30 16:25:35 +00:00
peter
faf78ea813 * overloading supported in child classes
* fixed parsing of classes with private and virtual and overloaded
    so it is compatible with delphi
2001-11-18 18:43:13 +00:00
peter
d2e1952377 * procsym definition rewrite 2001-11-02 22:58:00 +00:00
peter
e37dbf904d * calling convention rewrite 2001-10-25 21:22:32 +00:00
peter
17d62feebe * $calling directive and -Cc commandline patch added
from Pavel Ozerski
2001-10-23 21:49:42 +00:00
peter
7781fca6bd * read only typed const support, switch $J- 2001-10-20 20:30:20 +00:00
michael
d75c4d6486 * Smartlinking with interfaces fixed
* Better smartlinking for rtti and init tables
2001-09-19 11:04:41 +00:00
peter
915b5cd7a9 * split constsym.value in valueord,valueordptr,valueptr. The valueordptr
is used for holding target platform pointer values. As those can be
    bigger than the source platform.
2001-09-02 21:18:28 +00:00
peter
f88f6eb571 * rtti/init table updates
* rttisym for reusable global rtti/init info
  * support published for interfaces
2001-08-30 20:13:52 +00:00
florian
9746f4c2d6 * some cg reorganisation
* some PPC updates
2001-08-26 13:35:06 +00:00
peter
7b45b6a4a9 * local browser support fixed 2001-08-19 09:39:27 +00:00
peter
f4bae3b050 * errordef.typesym is not updated anymore 2001-08-12 22:11:52 +00:00
peter
096dc02fe0 * don't write fpuregable for varoptions 2001-08-12 20:00:26 +00:00
peter
81200dc9ef * funcret moved from tprocinfo to tprocdef 2001-08-06 21:40:46 +00:00
peter
b10e754536 * alignmentinfo record added
* -Oa argument supports more alignment settings that can be specified
    per type: PROC,LOOP,VARMIN,VARMAX,CONSTMIN,CONSTMAX,RECORDMIN
    RECORDMAX,LOCALMIN,LOCALMAX. It is possible to set the mimimum
    required alignment and the maximum usefull alignment. The final
    alignment will be choosen per variable size dependent on these
    settings
2001-07-01 20:16:15 +00:00
florian
05cfc07952 * some more support for widechars commited especially
regarding type casting and constants
2001-05-08 21:06:30 +00:00
peter
6c7708c1e0 * ppu object to class rewrite
* move ppu read and write stuff to fppu
2001-05-06 14:49:16 +00:00
peter
0c03535b5b * registration of targets and assemblers 2001-04-18 22:01:53 +00:00
peter
a7cf57524e * symtable change to classes
* range check generation and errors fixed, make cycle DEBUG=1 works
  * memory leaks fixed
2001-04-13 01:22:06 +00:00
peter
4e2655cdc5 * resulttype rewrite 2001-04-02 21:20:29 +00:00
peter
d8abf76f6b * getsym redesign, removed the globals srsym,srsymtable 2001-03-11 22:58:49 +00:00
peter
32b9cdb7cf + new tlinkedlist class (merge of old tstringqueue,tcontainer and
tlinkedlist objects)
2000-12-25 00:07:25 +00:00
pierre
631a4cd660 + use int64tostr function for integer consts 2000-11-28 00:25:17 +00:00
Jonas Maebe
4706eff850 * fixes so no more range errors with improved range checking code 2000-11-13 14:44:35 +00:00
florian
098dd1b56f * tprocdef.procsym must be set also when a tprocdef is loaded from a PPU 2000-11-08 23:15:17 +00:00
peter
e2fd02814d * uppercase manglednames 2000-11-06 23:13:53 +00:00
peter
5115083270 * tprocdef.fullprocname added for better casesensitve writing of
procedures
2000-11-01 23:04:37 +00:00
peter
451723647e * symtable splitted, no real code changes 2000-10-31 22:02:46 +00:00