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
d899444347
There is no need to maintain a set to keep track of variables that use location expressions. In such cases, AT_location attribute's value will be a label.
...
llvm-svn: 137659
2011-08-15 21:43:21 +00:00
Devang Patel
900d97719b
Fix warning.
...
llvm-svn: 137658
2011-08-15 21:35:16 +00:00
Devang Patel
3e4a965519
Simplify. Let DbgVariable keep track of variable's DBG_VALUE machine instruction.
...
llvm-svn: 137656
2011-08-15 21:24:36 +00:00
Devang Patel
99819b527d
Simplify mapping to variable from its abstract variable info.
...
When a variable is inlined multiple places, abstract variable keeps name, location, type etc.. info and all other concreate instances of the variable directly refers to abstract variable.
llvm-svn: 137637
2011-08-15 19:01:20 +00:00
Devang Patel
d7d80aadd1
Refactor.
...
llvm-svn: 137632
2011-08-15 18:40:16 +00:00
Devang Patel
6e4d2c9fb7
Refactor.
...
llvm-svn: 137631
2011-08-15 18:35:42 +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
444034783e
Use ArrayRef.
...
llvm-svn: 137485
2011-08-12 18:10:19 +00:00
Benjamin Kramer
fa7e6a54b1
Plug a memory leak.
...
llvm-svn: 137321
2011-08-11 18:39:28 +00:00
Devang Patel
784077eb57
Stay within 80 columns.
...
llvm-svn: 137283
2011-08-10 23:58:09 +00:00
Devang Patel
bb23a4a9a5
Distinguish between two copies of one inlined variable. Take 2.
...
llvm-svn: 137253
2011-08-10 21:50:54 +00:00
Devang Patel
e30746c844
Revert unintentional parts of previous check-in.
...
llvm-svn: 137249
2011-08-10 21:16:49 +00:00
Devang Patel
7e62302fae
Start using LexicalScopes utility. No intetional functionality change.
...
llvm-svn: 137246
2011-08-10 20:55:27 +00:00
Devang Patel
fee7cedbc9
Simplify by creating parent first.
...
llvm-svn: 137056
2011-08-08 18:22:10 +00:00
Chandler Carruth
81b7e11c89
Temporarily revert r135528 which distinguishes between two copies of one
...
inlined variable, based on the discussion in PR10542.
This explodes the runtime of several passes down the pipeline due to
a large number of "copies" remaining live across a large function. This
only shows up with both debug and opt, but when it does it creates
a many-minute compile when self-hosting LLVM+Clang. There are several
other cases that show these types of regressions.
All of this is tracked in PR10542, and progress is being made on fixing
the issue. Once its addressed, the re-instated, but until then this
restores the performance for self-hosting and other opt+debug builds.
Devang, let me know if this causes any trouble, or impedes fixing it in
any way, and thanks for working on this!
llvm-svn: 136953
2011-08-05 00:51:31 +00:00
Bob Wilson
0a8d5c6047
Some revisions to Devang's change r136759 for merged global debug info.
...
llvm-svn: 136802
2011-08-03 19:42:51 +00:00
Devang Patel
dc9cbaaf23
Use byte offset, instead of element number, to access merged global.
...
llvm-svn: 136759
2011-08-03 01:25:46 +00:00
Nick Lewycky
019d255d3e
Fix a lot of typos, improve (but not necessarily fix) grammaros and reflow some
...
lines. No functionality change.
llvm-svn: 136458
2011-07-29 03:49:23 +00:00
Devang Patel
53dc616170
Remove outdated FIXME comment.
...
llvm-svn: 136275
2011-07-27 22:00:01 +00:00
Devang Patel
f098ce2757
It is quiet possible that inlined function body is split into multiple chunks of consequtive instructions. But, there is not any way to describe this in .debug_inline accelerator table used by gdb. However, describe non contiguous ranges of inlined function body appropriately using AT_range of DW_TAG_inlined_subroutine debug info entry.
...
llvm-svn: 136196
2011-07-27 00:34:13 +00:00
Devang Patel
613958c82c
While extracting lexical scopes from machine instruction stream, work on one machine basic block at a time.
...
llvm-svn: 136106
2011-07-26 18:09:53 +00:00
Devang Patel
ddfe66e948
Refactor.
...
llvm-svn: 135633
2011-07-20 23:00:27 +00:00
Devang Patel
8fb9fd6769
There are two ways to map a variable to its lexical scope. Lexical scope information is embedded in MDNode describing the variable. It is also available as a part of DebugLoc attached with DBG_VALUE instruction. DebugLoc attached with an instruction is less reliable in optimized code so use information embedded in the MDNode.
...
llvm-svn: 135629
2011-07-20 22:18:50 +00:00
Devang Patel
a59b24b090
Distinguish between two copies of one inlined variable.
...
llvm-svn: 135528
2011-07-19 22:31:15 +00:00
Devang Patel
b7cc06366d
Use DebugLoc directly to map inlined functions' instructions to respective lexical scope.
...
llvm-svn: 135302
2011-07-15 21:25:44 +00:00
Devang Patel
f5f352dda5
Eliminate redundant map.
...
llvm-svn: 135278
2011-07-15 16:38:42 +00:00
Evan Cheng
b46f3e24ba
Reverting r135232. It's causing infinite looping in DbgScope::openInsnRange.
...
llvm-svn: 135254
2011-07-15 06:26:35 +00:00
Devang Patel
001c4f3ff0
Do not get confused by multiple empty lexical scopes inlined at one location.
...
llvm-svn: 135232
2011-07-15 00:30:39 +00:00
Devang Patel
4771159f9f
Refactor.
...
llvm-svn: 135212
2011-07-14 23:17:49 +00:00
Devang Patel
1f9913fdb2
Eliminate redundant LLVMContext argument.
...
Improve DbgScope->dump() output.
llvm-svn: 135207
2011-07-14 22:30:56 +00:00
Devang Patel
d5234bbced
Simplify.
...
llvm-svn: 135127
2011-07-14 01:52:45 +00:00
Devang Patel
07d61edc30
Simplify and delay extracting DebugLoc elements, scope and InlinedAt, as much as possible.
...
llvm-svn: 135124
2011-07-14 01:14:57 +00:00
Devang Patel
e07ebe32bf
Simplify. Compile unit check inside hasValidLocation() did not add any value.
...
llvm-svn: 135118
2011-07-14 00:20:24 +00:00
Devang Patel
a9195bcff0
Fix typo in DEBUG message.
...
llvm-svn: 135111
2011-07-14 00:04:53 +00:00
Devang Patel
2cce0d103d
Add DEBUG messages.
...
llvm-svn: 135110
2011-07-14 00:03:58 +00:00
Devang Patel
2442a89eb9
Refactor.
...
llvm-svn: 134703
2011-07-08 17:09:57 +00:00
Devang Patel
ed9fd45740
Make provision to have floating point constants in .debug_loc expressions.
...
llvm-svn: 134702
2011-07-08 16:49:43 +00:00
Devang Patel
53b050aec6
Add DEBUG message.
...
llvm-svn: 134643
2011-07-07 21:44:42 +00:00
Devang Patel
b7a328ed27
Add DEBUG messages.
...
llvm-svn: 134572
2011-07-07 00:14:27 +00:00
Devang Patel
92ca8fc927
Remove dead code.
...
llvm-svn: 134561
2011-07-06 23:26:18 +00:00
Devang Patel
f071d72c44
Handle debug info for i128 constants.
...
llvm-svn: 133821
2011-06-24 20:46:11 +00:00
Benjamin Kramer
440c3b7306
Use path API for path concatenation.
...
llvm-svn: 132668
2011-06-05 14:36:47 +00:00
Devang Patel
e7181b5fdb
A DBG_VALUE that truncates a range does not start another dbg value range.
...
llvm-svn: 132433
2011-06-01 23:00:17 +00:00
Devang Patel
324f843107
Do not drop constant values when a variable's content is described using .debug_loc entries.
...
llvm-svn: 132427
2011-06-01 22:03:25 +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
Rafael Espindola
d23bfb8a7a
Make size computation less brittle.
...
llvm-svn: 132222
2011-05-27 22:05:41 +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
354fa0798f
Fix debug info for blocks' variable.
...
llvm-svn: 131940
2011-05-24 00:22:25 +00:00