Commit Graph

37 Commits

Author SHA1 Message Date
Pierre Muller
cf4d02ef92 Add globals to implementation _USES clause to prepare move of V_XXX constants to globals unit 2023-09-09 06:54:30 +00:00
Jonas Maebe
d294731542 LLVM: enable DWARF debug info generation 2022-05-13 22:49:02 +02:00
yury
2808873d1b * Reworked the optimization of unused $parentfp for nested routines.
- Do not remove the $parentfp parameter as was done in the previous optimization approach. Instead when $parentfp is unused to the following:
      - On the caller side: Omit passing the value for $parentfp for targets where tcgcallparanode.push_zero_sized_value_para=false (classic CPU targets). 
          Pass 0/nil as $parentfp for targets where tcgcallparanode.push_zero_sized_value_para=true;
      - On the callee side: Prevent allocation of registers/resources for $parentfp.
  - When possible keep $parentfp in a register.
  - Set the pio_nested_access flag in tprocinfo.set_needs_parentfp() to properly handle deep nesting levels;

git-svn-id: trunk@45436 -
2020-05-19 13:17:47 +00:00
Jonas Maebe
281b3ad276 * fix case completeness and unreachable code warnings in compiler that would
be introduced by the next commit

git-svn-id: trunk@42046 -
2019-05-12 14:29:03 +00:00
svenbarth
ecda183153 * revert r37968: it does more harm than good
git-svn-id: trunk@37978 -
2018-01-15 16:41:22 +00:00
svenbarth
22932493b9 * if the debug info of a parent def is considered as queued then ensure that it is indeed queued (if it should already be in the list then the duplicate entry would have the state written if it's checked and thus ignored)
+ added test

git-svn-id: trunk@37969 -
2018-01-14 16:46:10 +00:00
svenbarth
ff44f51292 * generate an internal error to avoid infinite loops if nothing changed during a loop pass to write the debug info of remaining defs
git-svn-id: trunk@37968 -
2018-01-14 16:43:46 +00:00
florian
b1dff29cbf * removed unused units
git-svn-id: trunk@36165 -
2017-05-09 19:53:14 +00:00
svenbarth
3a9f8e88fd * don't write or reference debug information for a unit if it belongs to a/another package
git-svn-id: trunk@34382 -
2016-08-26 15:09:24 +00:00
Jonas Maebe
145e9c1aae * don't generate debug info for class fields in generic types
-> fixes failed compilation of webtbs/25600 with debug info
      (broken since 6 June, possibly because of r27874)
  * don't allocate class fields defined in generic types, as the
    only reason for this was to have valid debug info

git-svn-id: trunk@27928 -
2014-06-10 19:05:10 +00:00
pierre
356ea656e4 Try to avoid problems with generic types for stabs/stabx
git-svn-id: trunk@27635 -
2014-04-22 21:28:45 +00:00
Jonas Maebe
df2eddd169 * correctly deal with writing debug information in the Stabs writer for class
hierarchies from other units that were compiled without debug information
    in case not all classes from the hierarchy are explicitly used
    (mantis #22495, #21503, #21259)

git-svn-id: trunk@21972 -
2012-07-26 14:27:10 +00:00
pierre
813ebf08e3 * Avoid having current_debuginfo pointing to freed memory
git-svn-id: trunk@20549 -
2012-03-21 10:17:43 +00:00
paul
de21de2024 compiler: implement delphi like namespaces
git-svn-id: branches/paul/namespaces@18859 -
2011-08-27 03:52:07 +00:00
paul
915c412ae3 compiler: generate debug info for record methods:
- extended write_symtable_procdefs to handle record definitions
  - fix stabs info generator to use prefixed symbol names for record methods, also handle records static symbols the same way as for object types
  - fix dwarf info record generation: add visibility info and write methods, also prefix record members the same way as object members

git-svn-id: branches/paul/extended_records@16570 -
2010-12-16 06:12:05 +00:00
pierre
11d6509a56 Attempt to fix missing stabs definitions problem
git-svn-id: trunk@15238 -
2010-05-06 22:53:26 +00:00
Jonas Maebe
671f8a1d30 * always immediately reset isdbgwritten for syms in the parasymtable,
because they have to be written multiple times in case the procdef
    is also written multiple times (such as with DWARF on
    tf_dwarf_only_local_labels systems)

git-svn-id: trunk@14214 -
2009-11-18 22:31:08 +00:00
Jonas Maebe
341708b95d * write all parameters using the order of procdef.paras, eliminates the
special treatment required to put self as the first parameter in the
    debug info
  + added Apple-specific Objective-C related DWARF attributes
  * properly emit debug information for Objective-C classes and methods
  * fixed some typos in comments
  * properly mark "absolute" local variables mapped to parameters as
    variables in the debug info rather than as parameters (gdb expects one
    parameter to be passed when calling functions from inside gdb per
    parameter mentioned in the debug info, even if multiple parameters
    have the same stack address) 

git-svn-id: branches/objc@13723 -
2009-09-16 18:46:15 +00:00
peter
a3a66ba74d * split tvisibility from tsymoptions
* replace current_object_option with symtable.currentvisibility

git-svn-id: trunk@12048 -
2008-11-11 09:05:39 +00:00
Jonas Maebe
98e843c092 * support overriding debuginfo for classrefdefs
git-svn-id: trunk@11327 -
2008-07-05 14:25:23 +00:00
Jonas Maebe
39fa81d40e * fixed stabs debug info for webtbs/tw9766 again
git-svn-id: trunk@10602 -
2008-04-05 12:29:07 +00:00
peter
741b5a1df7 * fix writing procedure local type defs
* write type names once for types defined in the current compiled unit

git-svn-id: trunk@10541 -
2008-03-23 13:40:41 +00:00
peter
13f6396221 * generalize def and symbol handling
* stabs uses ansistring instead of pchars
  * write procdef in separate loop. this fixes debugging of nested/overloaded procs

git-svn-id: trunk@10189 -
2008-02-03 17:52:30 +00:00
peter
a724d80e81 * debuginfo initialized per unit
git-svn-id: trunk@8918 -
2007-10-23 18:19:17 +00:00
pierre
3473faab07 + added generation of debugging infos of parast and localst for methods
git-svn-id: trunk@7038 -
2007-03-30 21:34:55 +00:00
florian
eda8184e21 * problem with virtual methods and interfaces fixed, fixes #8158
git-svn-id: trunk@6099 -
2007-01-21 15:57:16 +00:00
peter
e17b424e28 * refactor procsym procdef list
git-svn-id: trunk@5210 -
2006-11-03 18:44:46 +00:00
peter
658c46b903 * remove tdictionary and tindexarray
* symtables based on TFPHashObjectList and TFPObjectList
  * rename torddef.typ to torddef.ordtype
  * rename tfloatdef.typ to tfloatdef.floattype
  * rename tdef.deftype to tdef.typ
  * remove obsolete browser code, browcol is kept so the ide
    can still be compiled

git-svn-id: trunk@5192 -
2006-11-03 00:30:30 +00:00
peter
3078a1927f * remove ttype
* rename old ttype variables *type to *def
  * rename resulttypepass to pass_typecheck
  * rename pass_2 to pass_generate_code

git-svn-id: trunk@5077 -
2006-10-29 22:19:39 +00:00
peter
b7fe6797bf Merged revisions 2921-2922,2925 via svnmerge from
http://svn.freepascal.org/svn/fpc/branches/linker/compiler

........
r2921 | peter | 2006-03-15 08:35:00 +0100 (Wed, 15 Mar 2006) | 2 lines

  * pass ObjectWriter to ObjectOuput

........
r2922 | peter | 2006-03-15 12:40:30 +0100 (Wed, 15 Mar 2006) | 2 lines

  * refactor asmdata

........
r2925 | peter | 2006-03-15 16:09:39 +0100 (Wed, 15 Mar 2006) | 3 lines

  * add cfi to asmdata
  * move asmlist, asmcfi, asmdata to own unit

........

git-svn-id: trunk@2932 -
2006-03-16 08:52:22 +00:00
florian
12730b4cb1 + dwarf: objectdef
git-svn-id: trunk@2429 -
2006-02-04 16:08:51 +00:00
florian
8cd8e4ba8d + basic dwarf support for variables and types
git-svn-id: trunk@2353 -
2006-01-28 16:06:08 +00:00
peter
51b8a4a132 * move stabs generation to a single procedure call from pmodules
git-svn-id: trunk@1358 -
2005-10-12 10:35:46 +00:00
peter
89297d2c39 * move all stabs ($ifdef gdb) code to dbgstabs
git-svn-id: trunk@1255 -
2005-10-02 11:17:05 +00:00
peter
82faa95118 * lineinfo fixed for binary writer
* add tai_directive to replace old tai_direct calls
    in powerpc

git-svn-id: trunk@1139 -
2005-09-19 11:47:30 +00:00
peter
a3ab2053c9 * support multiple asmlabel types, renamed getlabel to
getjumplabel and added type para to getlabel for specific types
  * moved lineinfo generation from assemble and aggas to dbgstabs

git-svn-id: trunk@1120 -
2005-09-18 21:16:10 +00:00
peter
fdc4925fcd * basic framework for debuginfo class added
git-svn-id: trunk@1084 -
2005-09-15 08:34:51 +00:00