aboutsummaryrefslogtreecommitdiffstats
path: root/debug/DwarfPrinter.ml
Commit message (Collapse)AuthorAgeFilesLines
* Added base address if needed.Bernhard Schommer2020-02-061-20/+25
| | | | | | | | Ranges of locations are relative to some base address. Most times this is just the same as the compilation unit. However if the compilation unit contains functions in multiple sections we need to add a base address of the section that the locations are contained.
* Compatibility with OCaml 4.08 (#302)Xavier Leroy2019-07-081-2/+2
| | | | | | | | | | | | | | | | * Do not use `Pervasives.xxx` qualified names Starting with OCaml 4.08, `Pervasives` is deprecated in favor of `Stdlib`, and uses of `Pervasives` cause fatal warnings. This commit uses unqualified names instead, as no ambiguity occurs. * Clarify "open" statements OCaml 4.08.0 has stricter warnings concerning open statements that shadow module names. Closes: #300
* Fix misspellings in messages, man pages, and commentsXavier Leroy2019-05-311-1/+1
| | | | | | This is a manual, partial merge of Github pull request #296 by @Fourchaux. flocq/, cparser/MenhirLib/ and parts of test/ have not been changed because these are local copies and the fixes should be performed upstream.
* Simplified offset printing.Bernhard Schommer2019-04-161-2/+3
| | | | | | | Instead of printing an the start label and adding the offset by computing the difference of the range label and the start label use the range label directly. Bug 26234
* Reworked range entries.Bernhard Schommer2019-04-161-8/+23
| | | | | | | | | | | | The fist changes changes the offset for range entries to used labels instead of integer constants, leaving the computation to the assembler. The second part of the change the address changes the way ranges entries of scopes are printed. They need to be relative to the start address of the code in the section they are included. Bug 26234
* Various improvements in the wording of diagnostics.Michael Schmidt2018-08-021-1/+1
| | | | | | Fix various typos in diagnostic messages and unified wording and capitalization. Bug 23850
* No verbose debug info in default mode.Bernhard Schommer2017-07-141-5/+17
| | | | | | We don't need verbose debug for the assembler. The verbose debug information should only be printed if assembler files are generated.
* Better fix for problems with quoting in files.Bernhard Schommer2017-03-201-2/+2
| | | | | | Instead of using Filename.quote, string entries are printed with %S. Bug 21216
* Do not print anonymous member names in debug infoBernhard Schommer2017-01-241-2/+2
| | | | | Anonymous members no longer are printed in the debug information. Fix 20798
* More verbose dwarf.Bernhard Schommer2016-12-071-1/+3
|
* Reset all Hashtbls.Bernhard Schommer2016-11-251-1/+4
| | | | | A non reseted Hashtbl caused problems with multiple input files. Bug 20462
* Do not use hardcoded register number for sp.Bernhard Schommer2016-11-251-10/+10
| | | | | | Since the dwarf register names for x86_32 and x86_64 differ it is wrong to hardcode the dwarf register number for rsp to 4. Bug 20461
* Use 64 bit address in debug information.Bernhard Schommer2016-11-101-19/+22
| | | | | Address constants need to be 64bit also in the debug information. Bug 20335
* Added sizetyp for subarray bounds. Fix 19894Bernhard Schommer2016-09-221-2/+2
|
* Code cleanup.Bernhard Schommer2016-03-101-8/+3
| | | | | | Removed some unused variables, functions etc. and resolved some problems which occur if all warnings except 3,4,9 and 29 are active. Bug 18394.
* Sort strings in the debug_str section.Bernhard Schommer2015-12-041-0/+1
| | | | | | In order to get deterministic output code we need to sort the strings in the debug_str section by their label. Fix 17727.
* New option to control the debug information build.Bernhard Schommer2015-11-041-2/+4
| | | | | | The new option -gonly-global allows the generation of debuging information for global variables only. Bug 17566.
* Implemented the usage of DW_AT_ranges for non-contiguous address ranges.Bernhard Schommer2015-10-161-5/+22
| | | | | | | | | | The gcc produces DW_AT_ranges for non-contiguous address ranges, like compilation units containing functions which are placed in different ELF-sections or lexical scopes that are split up. With this commit CompCert also uses this DWARF v3 feature for gnu backend based targets. In order to ensure backward compability a flag is added which avoids this and produces debug info in DWARF v2 format. Bug 17392.
* First step to implemente address ranges for the gnu backend.Bernhard Schommer2015-10-151-23/+34
| | | | | | | | | In contrast to the dcc, the gcc uses address ranges to express non-contiguous range of addresses. As a first step we set the start and end addresses for the different address ranges for the compilation unit by using the start and end addresses of functions. Bug 17392.
* More verbose debug printer.Bernhard Schommer2015-10-141-195/+201
| | | | | | | | Like, for example the clang, CompCert now prints a more detailed descriptions of the debug information in the assembler file. For each abbreviation and debug entry the dwarf attributes and their encodings are added. Bug 17392.
* bug 17392: remove trailing whitespace in source filesMichael Schmidt2015-10-141-4/+4
|
* Changed the type of the debug sections with additional string.Bernhard Schommer2015-10-131-3/+4
| | | | | | | | Instead of using a string they now take an optional string, which should be none if the backend is not the diab backend and the corresponding section is the text section and Some s with s being the custom section name else. Bug 17392.
* Implement the usage of the debug_str section for the gcc backend.Bernhard Schommer2015-10-131-33/+43
| | | | | | | | GCC prints all string larger than 3 characters in the debug_str section which reduces the size of the debug information since entries containing the same string now map to the same string in the debug_str sections. Bug 17392.
* Remove unused members from debug types.Bernhard Schommer2015-10-131-10/+0
| | | | | | | The dwarf 2 standard allows more attributes for certain debuggint entries than used by gcc or diab data. Since they are also not set by compcert they can be removed. Bug 17392.
* Use a more descriptive type for diab debug entries.Bernhard Schommer2015-10-121-11/+7
| | | | | | Instead of using a tuple we now use a record with descriptive names for the different entries. Bug 17392
* Filled in the rest of the funciton needed for thte debug info under arm.Bernhard Schommer2015-10-091-1/+1
| | | | | | The name_of_section function no returns the correct name for the debug sections, the prologue and epilogue directives are added and the labels for the live ranges are introduced in the Asmexpand pass.
* Fast fix for functions in different sections in one compilation unit for gcc.Bernhard Schommer2015-10-061-1/+14
|
* First try of debug information for gcc.Bernhard Schommer2015-10-021-12/+33
|
* Started implementation of gnu compatible debug information.Bernhard Schommer2015-10-021-2/+5
|
* Use different entry_to_label mapping for each compilation unit.Bernhard Schommer2015-10-011-3/+20
|
* Also add the rest to the producer tag.Bernhard Schommer2015-09-301-1/+2
|
* Removed newline in version string and add buildnr and tag if existing toBernhard Schommer2015-09-301-1/+6
| | | | Producer as well as target system.
* More fixes for the DebugInformation.Bernhard Schommer2015-09-291-7/+2
| | | | | | | Changed the sizeof function to take into account the bytes needed for the sleb128/uleb128 encoding of the DW_OP_* arguments and changed the end_live_range function to only close functions where the live range is currently open.
* Change the way the debug sections are printed.Bernhard Schommer2015-09-281-29/+28
| | | | | | If a user uses the #pragma use_section for functions the diab linker requires a separate debug_info section for each entry. This commit adds functionality to emulate this behavior.
* Added location for the formal parameters and move the end of allBernhard Schommer2015-09-281-2/+4
| | | | scopes before the last statement.
* Changed the size expression to 2byte for debug_loc entries.Bernhard Schommer2015-09-281-1/+18
|
* Added printing the reference address for the LocRef and started refactoring oldBernhard Schommer2015-09-271-7/+7
| | | | | | | | Debuging code. The old functions to store the symbol for the Global variables and retrive this is no longer needed since the atom is stored in DebugInformation. Also the Debug.Abbrev module is no longer needed.
* Added translation of the range lists to location entries.Bernhard Schommer2015-09-251-1/+10
|
* Added support for the locations of stack allocated local variables.Bernhard Schommer2015-09-251-16/+59
| | | | | This commit adds furher support for location information for local variables and starts with the implementation of the debug_loc section.
* Record the scope structure during unblocking.Bernhard Schommer2015-09-221-6/+6
| | | | | | Instead of creating separate annotations for the local variables we call the Debug.add_lvar_scope and we construct a mapping from function id + scope id to scope information.
* Merge branch 'debugscopes' into debug_locationsBernhard Schommer2015-09-211-3/+5
|\ | | | | | | | | | | Conflicts: debug/CtoDwarf.ml debug/DwarfPrinter.ml
| * Various changes in the debug printer.Bernhard Schommer2015-09-071-6/+7
| | | | | | | | | | | | The debug printer now uses udata for member sizes since structs can have a size larger than 255 bytes. Also functions that are inlined no longer have an high and low pc in their abbreviation entry.
* | First version with computation of dwarf info from debug info.Bernhard Schommer2015-09-171-27/+25
| | | | | | | | | | Introduced a new dwarf generation from the information collected in the DebugInformation and removed the old CtODwarf translation.
* | Move more functionality in the new interface.Bernhard Schommer2015-09-161-4/+0
| | | | | | | | | | | | Added functions to add more information to the debuging interface, like the struct layout with offsets, bitifiled layout and removed the no longer needed mapping from stamp to atom.
* | Added the abbreviation for symbol constants.Bernhard Schommer2015-08-261-0/+1
| |
* | Merge branch 'master' into debug_locationsBernhard Schommer2015-08-261-3/+2
|\| | | | | | | | | | | | | Conflicts: debug/CtoDwarf.ml debug/DwarfPrinter.ml debug/DwarfTypes.mli
| * Fixed abbreviation of DW_TAG_formal_parameter.Bernhard Schommer2015-08-251-1/+1
| | | | | | | | | | | | Dwarf debuging entries for formal parameters were printed as variables. This could lead to confusion in function pointer types and later with local variables.
| * Also change the order of high and low pc in the compilation unit tag.Bernhard Schommer2015-08-241-1/+1
| |
| * Revert "Added support for the location of non static global variables."Bernhard Schommer2015-08-231-7/+1
| | | | | | | | This reverts commit b4846ffadfa3fbb73ffa7d9c43e5218adeece8da.
* | Added symbol functions for printing of the location for global variables.Bernhard Schommer2015-08-211-10/+10
|/