1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-20 11:33:24 +02:00
Commit Graph

1100 Commits

Author SHA1 Message Date
Stuart Hastings
a3999081cf Reverting r107918 and r107919. Radar 8063111.
llvm-svn: 107930
2010-07-08 23:25:39 +00:00
Devang Patel
2abdcdfb40 Relax assertion. In optimized code, it is possible that first instruction is coming from a inlined function.
This fixes PR7596 .

llvm-svn: 107923
2010-07-08 22:39:20 +00:00
Stuart Hastings
b70d4e06e3 Fix decl/def debug info for template functions. Radar 8063111.
llvm-svn: 107919
2010-07-08 22:28:59 +00:00
Devang Patel
69b391b5b1 Reuse DIEInteger for 1. This is frequently used while emitting an attribute using dwarf::DW_FORM_flag form.
llvm-svn: 107903
2010-07-08 20:10:35 +00:00
Devang Patel
3d7c71dbbb One MDNode may be used to create regular DIE as well as abstract DIE.
Keep track of abstract subprogram DIEs. 

llvm-svn: 107822
2010-07-07 22:20:57 +00:00
Devang Patel
3e07e4eb8b Rename couple of maps.
llvm-svn: 107810
2010-07-07 20:49:57 +00:00
Devang Patel
6aef3e8bb3 80 cols.
llvm-svn: 107807
2010-07-07 20:12:52 +00:00
Dale Johannesen
df6db93a4d Propagate the AlignStack bit in InlineAsm's to the
PrologEpilog code, and use it to determine whether
the asm forces stack alignment or not.  gcc consistently
does not do this for GCC-style asms; Apple gcc inconsistently
sometimes does it for asm blocks.  There is no
convenient place to put a bit in either the SDNode or
the MachineInstr form, so I've added an extra operand
to each; unlovely, but it does allow for expansion for
more bits, should we need it.  PR 5125.  Some
existing testcases are affected.
The operand lists of the SDNode and MachineInstr forms
are indexed with awesome mnemonics, like "2"; I may
fix this someday, but not now.  I'm not making it any
worse.  If anyone is inspired I think you can find all
the right places from this patch.

llvm-svn: 107506
2010-07-02 20:16:09 +00:00
Bill Wendling
f21e2fe2b9 Make the "linker_private" linkage type emit a non-weak symbol to the file. It
will still be stripped by the linker when it generates the final image.

llvm-svn: 107440
2010-07-01 22:38:24 +00:00
Bill Wendling
90b6422f2f Implement the "linker_private_weak" linkage type. This will be used for
Objective-C metadata types which should be marked as "weak", but which the
linker will remove upon final linkage. However, this linkage isn't specific to
Objective-C.

For example, the "objc_msgSend_fixup_alloc" symbol is defined like this:

      .globl l_objc_msgSend_fixup_alloc
      .weak_definition l_objc_msgSend_fixup_alloc
      .section __DATA, __objc_msgrefs, coalesced
      .align 3
l_objc_msgSend_fixup_alloc:
       .quad   _objc_msgSend_fixup
       .quad   L_OBJC_METH_VAR_NAME_1

This is different from the "linker_private" linkage type, because it can't have
the metadata defined with ".weak_definition".

Currently only supported on Darwin platforms.

llvm-svn: 107433
2010-07-01 21:55:59 +00:00
Devang Patel
606a8f3fbf Do not require line number entry for undefined local variable.
This is a regression caused by r106792 and caught by gdb testsuite.

llvm-svn: 107430
2010-07-01 21:38:08 +00:00
Daniel Dunbar
37b4089fbf MC: Pass the target instance to the AsmParser constructor.
llvm-svn: 107426
2010-07-01 20:41:56 +00:00
Mikhail Glushenkov
0163e1e289 Trailing whitespace.
llvm-svn: 107360
2010-07-01 01:00:22 +00:00
Devang Patel
00ee7ba38c Do not construct DIE for already processed MDNode.
llvm-svn: 107237
2010-06-30 01:40:11 +00:00
Devang Patel
93e5e9bd19 Add variables into a scope before constructing scope DIE otherwise variables won't be included DIE tree.
llvm-svn: 107228
2010-06-30 00:11:08 +00:00
Bill Wendling
59ef9bcc6d Revert r107205 and r107207.
llvm-svn: 107215
2010-06-29 22:34:52 +00:00
Devang Patel
6d7cc07644 Print InlinedAt location.
llvm-svn: 107214
2010-06-29 22:29:15 +00:00
Bill Wendling
05a4c0b1f2 Introducing the "linker_weak" linkage type. This will be used for Objective-C
metadata types which should be marked as "weak", but which the linker will
remove upon final linkage. For example, the "objc_msgSend_fixup_alloc" symbol is
defined like this:

       .globl l_objc_msgSend_fixup_alloc
       .weak_definition l_objc_msgSend_fixup_alloc
       .section __DATA, __objc_msgrefs, coalesced
       .align 3
l_objc_msgSend_fixup_alloc:
        .quad   _objc_msgSend_fixup
        .quad   L_OBJC_METH_VAR_NAME_1

This is different from the "linker_private" linkage type, because it can't have
the metadata defined with ".weak_definition".

llvm-svn: 107205
2010-06-29 21:24:00 +00:00
Devang Patel
8052c941ca Do not hardcode DW_AT_stmt_list value.
Inspired by Artur Pietrek.

llvm-svn: 107202
2010-06-29 20:17:53 +00:00
Devang Patel
2c43f47ccc Use DW_FORM_addr for DW_AT_entry_pc.
llvm-svn: 107085
2010-06-28 22:22:47 +00:00
Devang Patel
229053c609 Include inlined function in list of processed subprograms.
llvm-svn: 107065
2010-06-28 20:53:04 +00:00
Devang Patel
dffbf36af7 Preserve deleted function's local variables' debug info.
Radar 8122864.

llvm-svn: 107027
2010-06-28 18:25:03 +00:00
Devang Patel
1929457a0f Remove dead code.
llvm-svn: 106990
2010-06-28 05:59:13 +00:00
Devang Patel
b5b193fb87 Collect debug info for optimized variables of inlined functions.
llvm-svn: 106895
2010-06-25 22:07:34 +00:00
Devang Patel
af1d4eede5 DBG_VALUE machine instruction pointing to undefined register for a variable justify a separate scope if the variable is inlined function's argument.
Radar 8122864.

llvm-svn: 106792
2010-06-24 21:51:19 +00:00
Devang Patel
f50b6147ad Use single interface, using twine, to get named metadata.
getNamedMetadata().

llvm-svn: 106518
2010-06-22 01:19:38 +00:00
Devang Patel
38d9ee4e35 Discard special LLVM prefix from linkage name.
llvm-svn: 106516
2010-06-22 01:06:05 +00:00
Devang Patel
dee41b010a Do not rely on Twine temporaries to survive.
llvm-svn: 106515
2010-06-22 01:01:58 +00:00
Dan Gohman
6c6e9a45ff Give NamedRegionTimer an Enabled flag, allowing all its clients to
switch from this:

  if (TimePassesIsEnabled) {
    NamedRegionTimer T(Name, GroupName);
    do_something();
  } else {
    do_something(); // duplicate the code, this time without a timer!
  }

to this:

  {
    NamedRegionTimer T(Name, GroupName, TimePassesIsEnabled);
    do_something();
  }

llvm-svn: 106285
2010-06-18 15:56:31 +00:00
Devang Patel
3282324020 Use separate named MDNode to hold each function's local variable info.
This speeds up local variable handling in DwarfDebug.

llvm-svn: 106075
2010-06-16 00:53:55 +00:00
Eric Christopher
db2cef56c9 Don't emit the linkage for initializer label for mach-o tls.
llvm-svn: 106073
2010-06-16 00:27:30 +00:00
Stuart Hastings
5dd588e7d9 Added a comment.
llvm-svn: 106063
2010-06-15 23:06:30 +00:00
Stuart Hastings
f9ef9ff3d6 Support for nested functions/classes in debug output. (Again.) Radar 7424645.
llvm-svn: 105828
2010-06-11 20:08:44 +00:00
Stuart Hastings
37ed2a9663 Revert 105492 & 105493 due to a testcase regression. Radar 7424645.
llvm-svn: 105511
2010-06-05 00:39:29 +00:00
Stuart Hastings
eb78f8db98 Support for nested functions/classes in debug output. Radar 7424645.
llvm-svn: 105492
2010-06-04 22:36:03 +00:00
Eric Christopher
00f399e90a One underscore, not two.
llvm-svn: 105379
2010-06-03 04:02:59 +00:00
Devang Patel
5fb0590e9c Skip identical instruction while calculating DBG_VALUE range.
llvm-svn: 105340
2010-06-02 19:05:13 +00:00
Devang Patel
a5f4e6f4d9 Use local small vector.
llvm-svn: 105332
2010-06-02 16:42:51 +00:00
Devang Patel
345874624f Ignore line number of debug value in undefined register.
llvm-svn: 105292
2010-06-01 21:43:09 +00:00
Stuart Hastings
369d3391d8 Revert 104841, 104842, 104876 due to buildbot failures. Radar 7424645.
llvm-svn: 104953
2010-05-28 16:41:07 +00:00
Devang Patel
8d4eb26f24 Do not drop location info for inlined function args.
llvm-svn: 104884
2010-05-27 20:25:04 +00:00
Devang Patel
747f1a373b inlined function's arguments need a label to mark the start point because they are not directly attached to current function.
llvm-svn: 104848
2010-05-27 16:47:30 +00:00
Stuart Hastings
60d799e343 Support for nested functions/classes in debug output. Radar 7424645.
llvm-svn: 104841
2010-05-27 16:16:54 +00:00
Devang Patel
bdda547db4 Simplify. Eliminate unneeded debug_loc entry.
llvm-svn: 104785
2010-05-26 23:55:23 +00:00
Devang Patel
2bbe13a797 There is no need to force an line number entry (using previous location) for a temp label at unknown location.
llvm-svn: 104740
2010-05-26 21:23:46 +00:00
Devang Patel
c24a269116 Identify instructions, that needs a label to mark debug info entity, in advance. This simplifies beginScope().
llvm-svn: 104720
2010-05-26 19:37:24 +00:00
Devang Patel
6f08a37562 Remove dead code.
llvm-svn: 104706
2010-05-26 17:42:50 +00:00
Devang Patel
691615151f Do not construct location list backword!
llvm-svn: 104705
2010-05-26 17:29:32 +00:00
Devang Patel
d7ad8ac4c0 First cut at supporting .debug_loc section.
This is used to track variable information.

llvm-svn: 104649
2010-05-25 23:40:22 +00:00
Eric Christopher
f6d55e86e7 Move the verbose asm output up a bit so it can be used in the special cases
as well.

llvm-svn: 104642
2010-05-25 21:49:43 +00:00