Eric Christopher
d42b92f5c3
Untabify and 80-col.
...
llvm-svn: 157274
2012-05-22 18:45:24 +00:00
Eric Christopher
775cbd2b47
Formatting consistency.
...
llvm-svn: 157273
2012-05-22 18:45:18 +00:00
Eric Christopher
4d25052a9a
Handle OpDeref in case it comes in as a register operand.
...
Part of rdar://11352000
llvm-svn: 156405
2012-05-08 18:56:00 +00:00
Eric Christopher
a8caa739de
Make comment here more clear.
...
llvm-svn: 154878
2012-04-16 23:54:23 +00:00
Eric Christopher
70e1bd8872
Add support for objc property decls according to the page at:
...
http://llvm.org/docs/SourceLevelDebugging.html#objcproperty
including type and DECL. Expand the metadata needed accordingly.
rdar://11144023
llvm-svn: 153639
2012-03-29 08:42:56 +00:00
Eric Christopher
7285c7d51d
Fix the output of the DW_TAG_friend tag to include DW_AT_friend
...
and not the rest of the member tag.
Fixes PR11695
llvm-svn: 153570
2012-03-28 07:34:31 +00:00
Eric Christopher
7734ca2891
For types with a parent of the compile unit make sure and emit
...
the DECL information.
rdar://10855921
llvm-svn: 152876
2012-03-15 23:55:40 +00:00
Eric Christopher
7dd54fb695
Revert the removal of DW_AT_MIPS_linkage_name when we aren't putting
...
out the DW_AT_name. Older gdbs unfortunately still use it to
disambiguate member functions in templated classes (gdb.cp/templates.exp).
rdar://11043421 (which is now deferred for a bit)
llvm-svn: 152782
2012-03-15 08:19:33 +00:00
Eric Christopher
a9916d0296
Remove the DW_AT_MIPS_linkage name attribute when we don't need it
...
output (we're emitting a specification already and the information
isn't changing).
Saves 1% on the debug information for a build of llvm.
Fixes rdar://11043421
llvm-svn: 152697
2012-03-14 02:59:17 +00:00
Eric Christopher
54cf8ff45e
Add the DW_AT_APPLE_runtime_class attribute to forward declarations
...
as well as completely defined classes.
This fixes rdar://10956070
llvm-svn: 152171
2012-03-07 00:15:19 +00:00
Eric Christopher
5cd2a9d98e
Only add DW_AT_prototyped if we're working with a C-like language.
...
Worth another 45k (1%) off of a large C++ testcase.
rdar://10909458
llvm-svn: 151144
2012-02-22 08:46:21 +00:00
Eric Christopher
3a2656b394
Add the source language into the compile unit.
...
llvm-svn: 151143
2012-02-22 08:46:13 +00:00
Eric Christopher
ef64b465a4
Remove extra semi-colon.
...
llvm-svn: 151142
2012-02-22 08:46:02 +00:00
Eric Christopher
8575790912
There's no need for a DW_AT_byte_size on a pointer type.
...
Part of rdar://10493979 where it reduces by about .5% (10k)
llvm-svn: 151097
2012-02-21 22:25:53 +00:00
Devang Patel
d925d1a8d7
Remove tabs.
...
llvm-svn: 150012
2012-02-07 23:33:58 +00:00
Devang Patel
4488217f73
DebugInfo: Provide a new hook to encode relationship between a property and an ivar.
...
llvm-svn: 149874
2012-02-06 17:49:43 +00:00
Devang Patel
403e819731
Emit new property tag.
...
llvm-svn: 149737
2012-02-04 01:30:32 +00:00
Eric Christopher
8ea8e4fc76
Add a comment and ensure that anyone else looking at this code doesn't start
...
to bleed from the eyes.
llvm-svn: 147695
2012-01-06 23:03:37 +00:00
Eric Christopher
21bde87bf3
As part of the ongoing work in finalizing the accelerator tables, extend
...
the debug type accelerator tables to contain the tag and a flag
stating whether or not a compound type is a complete type.
rdar://10652330
llvm-svn: 147651
2012-01-06 04:35:23 +00:00
Eric Christopher
da011dd0e3
Resolve part of a fixme and add a new one.
...
llvm-svn: 146784
2011-12-16 23:42:42 +00:00
Eric Christopher
03faed3eac
Add a fixme here.
...
llvm-svn: 146783
2011-12-16 23:42:38 +00:00
Nick Lewycky
cfde1a26b4
DW_AT_virtuality is also defined to be constant, not flag.
...
llvm-svn: 146534
2011-12-14 00:56:07 +00:00
Nick Lewycky
cb91849fc7
DW_AT_accessibility is "constant" class, not form class, so it may not use
...
DW_FORM_flag. Use DW_FORM_data1 for one byte.
llvm-svn: 146475
2011-12-13 05:09:11 +00:00
Devang Patel
107e8ec30d
DISubrange supports unsigned lower/upper array bounds, so let's not fake it in the end while emitting DWARF. If a FE needs to encode signed lower/upper array bounds then we need to extend DISubrange or ad DISignedSubrange.
...
llvm-svn: 144937
2011-11-17 23:43:15 +00:00
Eric Christopher
0a917b7ad4
Initialize variable.
...
llvm-svn: 144360
2011-11-11 03:16:32 +00:00
Eric Christopher
c12c211c44
If we have a DIE with an AT_specification use that instead of the normal
...
addr DIE when adding to the dwarf accelerator tables.
llvm-svn: 144354
2011-11-11 01:55:22 +00:00
Rafael Espindola
79278365d3
Check in getOrCreateSubprogramDIE if a declaration exists and if so output
...
it first.
This is a more general fix to pr11300.
llvm-svn: 144324
2011-11-10 22:34:29 +00:00
Eric Christopher
e288793e44
Move type handling to make sure we get all created types that aren't
...
forward decls and have names into the dwarf accelerator types table.
llvm-svn: 144306
2011-11-10 19:52:58 +00:00
Eric Christopher
5223a57533
Remove the pubnames section, no one consumes it.
...
llvm-svn: 144169
2011-11-09 05:24:07 +00:00
Eric Christopher
08a558eeef
Also add the linkage name to the name accelerator tables if it exists
...
and is different than the normal name.
llvm-svn: 144130
2011-11-08 21:56:23 +00:00
Eric Christopher
5139dadd50
Add all completed and named types to the dwarf type accelerator tables.
...
llvm-svn: 144027
2011-11-07 22:11:16 +00:00
Eric Christopher
4996c70034
Add the support code to enable the dwarf accelerator tables. Upcoming patches
...
to fix the types section (all types, not just global types), and testcases.
The code to do the final emission is disabled by default.
llvm-svn: 143923
2011-11-07 09:24:32 +00:00
NAKAMURA Takumi
29ccdd8207
Dwarf: [PR11022] Fix emitting DW_AT_const_value(>i64), to be host-endian-neutral.
...
Don't assume APInt::getRawData() would hold target-aware endianness nor host-compliant endianness. rawdata[0] holds most lower i64, even on big endian host.
FIXME: Add a testcase for big endian target.
FIXME: Ditto on CompileUnit::addConstantFPValue() ?
llvm-svn: 143194
2011-10-28 14:12:22 +00:00
Nick Lewycky
cc64ae140d
Always use the string pool, even when it makes the .o larger. This may help
...
tools that read the debug info in the .o files by making the DIE sizes more
consistent.
llvm-svn: 143186
2011-10-28 05:29:47 +00:00
Nick Lewycky
d59c0cac6c
Teach our Dwarf emission to use the string pool.
...
llvm-svn: 143097
2011-10-27 06:44:11 +00:00
Nick Lewycky
654f5ce812
Reflow lines, fix comments for doxygen style, fix whitespace. No functionality
...
change.
llvm-svn: 143074
2011-10-26 22:55:33 +00:00
Eric Christopher
cead033ced
Whitespace.
...
llvm-svn: 141005
2011-10-03 15:49:20 +00:00
James Molloy
0ceb8cadd2
Fix emission of debug data for global variables. getContext() on DIGlobalVariables is not valid any more.
...
llvm-svn: 140539
2011-09-26 17:40:42 +00:00
Devang Patel
5e6b65cf0d
Do not unnecessarily use AT_specification DIE because it does not add any value.
...
Few weeks ago, llvm completely inverted the debug info graph. Earlier each debug info node used to keep track of its compile unit, now compile unit keeps track of important nodes. One impact of this change is that the global variable's do not have any context, which should be checked before deciding to use AT_specification DIE.
llvm-svn: 140282
2011-09-21 23:41:11 +00:00
Devang Patel
04d6d47865
Add support to emit debug info for C++0x nullptr type.
...
llvm-svn: 139751
2011-09-14 23:13:28 +00:00
Devang Patel
0ecbcbd12c
Eliminate unnecessary forwarding function.
...
llvm-svn: 138006
2011-08-18 23:17:55 +00:00
Devang Patel
a6576a146d
Add new DIE into the map asap.
...
llvm-svn: 137998
2011-08-18 22:21:50 +00:00
Devang Patel
eb1bb4e419
Until now all debug info MDNodes referred to a root MDNode, a compile unit. This simplified handling of these needs in dwarf writer. However, one side effect of this is that during link time optimization all these MDNodes are _not_ uniqued. In other words there will be N number of MDNodes describing "int", "char" and all other types, which would suddenly grow when each object file starts using libraries like STL.
...
MDNodes graph structure such that compiler unit keeps track of important MDNodes and update dwarf writer to process mdnodes top-down instead of bottom up.
llvm-svn: 137778
2011-08-16 22:09:43 +00:00
Devang Patel
3acc70e536
Refactor. Variables are part of compile unit so let CompileUnit create new variable.
...
llvm-svn: 137663
2011-08-15 22:04:40 +00:00
Devang Patel
dfd6ec3ce1
Refactor. Global variables are part of compile unit so let CompileUnit create new global variable.
...
llvm-svn: 137621
2011-08-15 17:57:41 +00:00
Devang Patel
895437142a
Refactor. A subprogram is part of compile unit so let CompileUnit construct new subprogram.
...
llvm-svn: 137618
2011-08-15 17:24:54 +00:00
Devang Patel
bcd50a10d5
While emitting constant value, look through derived type and use underlying basic type to determine size and signness of the constant value.
...
llvm-svn: 135627
2011-07-20 21:57:04 +00:00
Devang Patel
f071d72c44
Handle debug info for i128 constants.
...
llvm-svn: 133821
2011-06-24 20:46:11 +00:00
Devang Patel
562c74284f
Incomplete type may not have corresponding DIE, so do not check DIEEntry eagerly.
...
llvm-svn: 132377
2011-06-01 00:23:24 +00:00
Devang Patel
1cb8ab456c
Refactor.
...
llvm-svn: 132373
2011-05-31 23:30:30 +00:00
Devang Patel
e9853f25ad
Include global types, that are referenced through local variables, in debug_pubtypes list.
...
llvm-svn: 132371
2011-05-31 22:56:51 +00:00
Devang Patel
8816bbc02d
Select DW_AT_const_value size based on global variable size.
...
llvm-svn: 132239
2011-05-28 00:39:18 +00:00
Devang Patel
39e22eae49
Keep this simple. Use DIType to get signness and size of a type. Based on size, select appropraite form.
...
llvm-svn: 132206
2011-05-27 19:13:26 +00:00
Devang Patel
f1d04706fb
Handle signed types gracefully.
...
This fixes regressions reported by buildbots as a fallout of r132193.
llvm-svn: 132197
2011-05-27 18:15:52 +00:00
Devang Patel
3c6aed2d98
Select DW_AT_const_value size based on variable size.
...
llvm-svn: 132193
2011-05-27 16:45:18 +00:00
Devang Patel
12419aee7a
Doug convinced me that DW_AT_APPLE_objc_complete_type is more appropriate name.
...
s/DW_AT_APPLE_objc_class_extension/DW_AT_APPLE_objc_complete_type/g
llvm-svn: 131244
2011-05-12 21:29:42 +00:00
Devang Patel
2409e7843b
Let Objective-C front-end identify class extension, in dwarf output, using an attribute DW_AT_APPLE_objc_class_extension.
...
llvm-svn: 131238
2011-05-12 19:06:16 +00:00
Devang Patel
17b532728b
Move CompileUnit::getOrCreateNameSpace() and CompileUnit::addPubType() from DwarfDebug.cpp to DwarfCompileUnit.cpp
...
llvm-svn: 130991
2011-05-06 16:57:54 +00:00
Devang Patel
3e021533cd
Teach dwarf writer to handle complex address expression for .debug_loc entries.
...
This fixes clang generated blocks' variables' debug info.
Radar 9279956.
llvm-svn: 130373
2011-04-28 02:22:40 +00:00
Devang Patel
77dc541b00
Simplify handling of variables with complex address (i.e. blocks variables)
...
llvm-svn: 130339
2011-04-27 22:45:24 +00:00
Devang Patel
ba5fbf17df
Refactor code. Keep dwarf register operation selection logic at one place.
...
llvm-svn: 130231
2011-04-26 19:06:18 +00:00
Devang Patel
8ce24133fd
Rename a method to match what it really does.
...
s/addVariableAddress/addFrameVariableAddress/g
llvm-svn: 130170
2011-04-25 23:02:17 +00:00
Devang Patel
514b4006c2
Introduce support to encode Objective-C property information in debugging information generated for an interface.
...
llvm-svn: 129624
2011-04-16 00:11:51 +00:00
Devang Patel
0e821f4673
I missed this new file in previous commit.
...
llvm-svn: 129407
2011-04-12 23:21:44 +00:00