Skip to content
  1. Nov 18, 2014
    • Hans Wennborg's avatar
      SimplifyCFG: Range'ify some for-loops. No functional change. · a6a11a96
      Hans Wennborg authored
      llvm-svn: 222215
      a6a11a96
    • Jason Molenda's avatar
      Read the LSDA and Personality Routine function address out of the · e9c7ecf6
      Jason Molenda authored
      eh_frame data.  These two pieces of information are used in the
      process of exception handler unwinding on SysV ABI systems.
      
      This patch reads the data from the eh_frame section 
      (DWARFCallFrameInfo.cpp), allows for it to be saved & read out
      of a given UnwindPlan (UnwindPlan.h, UnwindPlan.cpp) - as well
      as printing the information in the UnwindPlan::Dump method - and
      adds methods to the FuncUnwinders object so that higher levels
      can query if a given function has an LSDA / personality routine
      defined.
      
      It's only lightly tested, but seems to be working correctly as long
      as your have this information in eh_frame.  Does not address getting
      this information from compact unwind yet on Darwin systems.
      
      <rdar://problem/18742797> 
      
      llvm-svn: 222214
      e9c7ecf6
    • David Majnemer's avatar
      IndVarSimplify: Allow LFTR to fire more often · 9a91e4a1
      David Majnemer authored
      I added a pessimization in r217102 to prevent miscompiles when the
      incremented induction variable was used in a comparison; it would be
      poison.
      
      Try to use the incremented induction variable more often when we can be
      sure that the increment won't end in poison.
      
      Differential Revision: http://reviews.llvm.org/D6222
      
      llvm-svn: 222213
      9a91e4a1
    • Duncan P. N. Exon Smith's avatar
      IR: Sink MDNode::Hash down to GenericMDNode::Hash · 4db24cc4
      Duncan P. N. Exon Smith authored
      Part of PR21532.
      
      llvm-svn: 222212
      4db24cc4
    • Duncan P. N. Exon Smith's avatar
      IR: Move MDNode operands from the back to the front · c23610b1
      Duncan P. N. Exon Smith authored
      Having the operands at the back prevents subclasses from safely adding
      fields.  Move them to the front.
      
      Instead of replicating the custom `malloc()`, `free()` and `DestroyFlag`
      logic that was there before, overload `new` and `delete`.
      
      I added calls to a new `GenericMDNode::dropAllReferences()` in
      `LLVMContextImpl::~LLVMContextImpl()`.  There's a maze of callbacks
      happening during teardown, and this resolves them before we enter
      the destructors.
      
      Part of PR21532.
      
      llvm-svn: 222211
      c23610b1
    • Manman Ren's avatar
      Update testing case that was accidently duplicated. · 8975b044
      Manman Ren authored
      llvm-svn: 222210
      8975b044
    • Michael J. Spencer's avatar
      Fix covered switch warning · 21245af8
      Michael J. Spencer authored
      llvm-svn: 222209
      21245af8
    • Michael J. Spencer's avatar
      Support ELF files of unknown type. · bbd875b6
      Michael J. Spencer authored
      llvm-svn: 222208
      bbd875b6
    • Greg Clayton's avatar
      Have CommandObjectCommandsAddRegex inherit from IOHandlerDelegateMultiline so... · ea508635
      Greg Clayton authored
      Have CommandObjectCommandsAddRegex inherit from IOHandlerDelegateMultiline so it will not immediately terminate after the first regular expression in "command regex <name>" commands.
      
      Fixed the prompt to not include non-printable characters as it was hosing up the prompt when you ran "command regex foo" and entered multi-line editing mode.
      
      Fixed error strings to include more complete descriptions when bad regular expressions are entered.
      
      Removed the old IOHandlerLinesUpdated function as it is no longer needed (inheriting from IOHandlerDelegateMultiline takes care of what this function used to do).
      
      llvm-svn: 222207
      ea508635
    • Greg Clayton's avatar
      Fixed a broken test suite test after recent editline merges. · dacf689a
      Greg Clayton authored
      The problem is that editline currently is trying to be smart when we paste things into a terminal window. It detects that input is pending and multi-line input is accepted as long as there is anything pending.
      
      So if you open lldb and paste the text between the quotes:
      
      "command regex carp
      s/^$/help/
      
      carp
      "
      
      We still still be stuck in the "command regex" multi-line input reader as it will have all three lines:
      
      "s/^$/help/
      
      carp
      "
      
      The true fix for this is something Kate Stone will soon work on:
      
      - multi-line input readers must opt into this paste/pending input feature ("expr" will opt into it, all other commands won't)
      - If we are in a multi-line input reader that requests this and stuff is pasted, then it will do what it does today
      - if we start in a IOHandler that doesn't need/want pending input and text is pasted, and we transistion to a IOHandler that does want this functionality, then disable the pending input. Example text would be:
      
      "frame variable
      thread backtrace
      expr
      for (int i=0;i<10;++i)
        (int)printf("i = %i\n", i);
      
      frame select 0
      "
      
      When we push the expression multi-line reader we would disable the pending input because we had pending input _before_ we entered "expr".
      
      If we did this first:
      
      (lldb) expr
      
      Then we pasted:
      
      "void foo()
      {
      }
      
      void bar()
      {
      }
      "
      
      Then we would allow the pending input to not look for an empty line to terminate the expression. We filed radar 19008425 to track fixing this issue.
      
      llvm-svn: 222206
      dacf689a
    • Duncan P. N. Exon Smith's avatar
      IR: Split MDNode into GenericMDNode and MDNodeFwdDecl · 50846f80
      Duncan P. N. Exon Smith authored
      Split `MDNode` into two classes:
      
        - `GenericMDNode`, which is uniquable (and for now, always starts
          uniqued).  Once `Metadata` is split from the `Value` hierarchy, this
          class will lose the ability to RAUW itself.
      
        - `MDNodeFwdDecl`, which is used for the "temporary" interface, is
          never uniqued, and isn't managed by `LLVMContext` at all.
      
      I've left most of the guts in `MDNode` for now, but I'll incrementally
      move things to the right places (or delete the functionality, as
      appropriate).
      
      Part of PR21532.
      
      llvm-svn: 222205
      50846f80
    • Justin Bogner's avatar
      InstrProf: Don't emit coverage for uninstantiated templates · 94d384e4
      Justin Bogner authored
      We include unused functions and methods in -fcoverage-mapping so that
      we can differentiate between uninstrumented and unused. This can cause
      problems for uninstantiated templates though, since they may involve
      an incomplete type that can't be mangled. This shows up in things like
      libc++'s <unordered_map> and makes coverage unusable.
      
      Avoid the issue by skipping uninstantiated methods of a templated
      class.
      
      llvm-svn: 222204
      94d384e4
    • Manman Ren's avatar
      Revert r222040 because of bot failure. · a64bd44f
      Manman Ren authored
      http://lab.llvm.org:8080/green/job/clang-Rlto_master/298/
      Hopefully, bot will be green.
      
      llvm-svn: 222203
      a64bd44f
    • Nick Kledzik's avatar
      [mach-o] zero-fill sections have no file offset · b072c367
      Nick Kledzik authored
      In mach-o, sections of type S_ZEROFILL are special cased and to always have
      their section.offset field be zero.
      
      llvm-svn: 222202
      b072c367
    • Nick Kledzik's avatar
      [mach-o] extract atom alignment information from mach-o files · 63adb08c
      Nick Kledzik authored
      llvm-svn: 222201
      63adb08c
    • Nick Kledzik's avatar
      [mach-o] enhance arm64 reloc parser to support local pointer relocations · f6e5ace9
      Nick Kledzik authored
      The arm64 assembler almost always uses r_extern=1 relocations in which the
      r_symbolnum field is the index of the symbol the relocation references.  But
      sometimes it will set r_extern=0 in which case the linker needs to read the
      content of the reloction to determine the target.
      
      Add test case that the r_extern=0 relocation round trips.
      
      llvm-svn: 222200
      f6e5ace9
    • Nick Kledzik's avatar
      [mach-o] fix typos. No function change · 68c42eca
      Nick Kledzik authored
      llvm-svn: 222199
      68c42eca
    • Nick Kledzik's avatar
      [mach-o] enhance arm64 reloc parser to support local pointer relocations · 60db3549
      Nick Kledzik authored
      The arm64 assembler almost always uses r_extern=1 relocations in which the
      r_symbolnum field is the index of the symbol the relocation references.  But
      sometimes it will set r_extern=0 in which case the linker needs to read the
      content of the reloction to determine the target.
      
      Add test case that the r_extern=0 relocation round trips.
      
      llvm-svn: 222198
      60db3549
    • Nick Kledzik's avatar
      [mach-o] fix typos. No function change · 218f7199
      Nick Kledzik authored
      llvm-svn: 222197
      218f7199
    • Manman Ren's avatar
      Debug Info: context field of a global variable is DIScopeRef. · 40854964
      Manman Ren authored
      Paired commit with r222195.
      
      llvm-svn: 222196
      40854964
    • Manman Ren's avatar
      Debug Info: In DIBuilder, the context field of a global variable is updated to · 554865da
      Manman Ren authored
      use DIScopeRef.
      
      A paired commit at clang will follow to show cases where we will use an
      identifer for the context of a global variable.
      
      rdar://18958417
      
      llvm-svn: 222195
      554865da
    • John McCall's avatar
      Fix an assertion when ending a function definition. · 0d8d6c09
      John McCall authored
      The bug is that ExprCleanupObjects isn't always empty
      in a fresh evaluation context.  New evaluation contexts just
      track the current depth of the stack.
      
      The assertion will misfire whenever we finish processing
      a function body inside an expression that contained an earlier
      block literal with non-trivial captures.  That's actually
      a lot less likely than you'd think, though, because it has
      to be a real function declaration, not just another block.
      Mixed block/lambda code would work, as would a template
      instantiation or a local class definition.
      
      The code works correctly if the assertion is disabled.
      
      rdar://16356628
      
      llvm-svn: 222194
      0d8d6c09
    • Alexander Kornienko's avatar
      Make DiagnosticsEngine::takeClient return std::unique_ptr<> · 41c247a6
      Alexander Kornienko authored
      Summary:
      Make DiagnosticsEngine::takeClient return std::unique_ptr<>. Updated
      callers to store conditional ownership using a pair of pointer and unique_ptr
      instead of a pointer + bool. Updated code that temporarily registers clients to
      use the non-owning registration (+ removed extra calls to takeClient).
      
      Reviewers: dblaikie
      
      Reviewed By: dblaikie
      
      Subscribers: cfe-commits
      
      Differential Revision: http://reviews.llvm.org/D6294
      
      llvm-svn: 222193
      41c247a6
    • Reid Kleckner's avatar
      Handle use of default member initializers before end of outermost class · d60b82f9
      Reid Kleckner authored
      Specifically, when we have this situation:
        struct A {
          template <typename T> struct B {
            int m1 = sizeof(A);
          };
          B<int> m2;
        };
      
      We can't parse m1's initializer eagerly because we need A to be
      complete.  Therefore we wait until the end of A's class scope to parse
      it. However, we can trigger instantiation of B before the end of A,
      which will attempt to instantiate the field decls eagerly, and it would
      build a bad field decl instantiation that said it had an initializer but
      actually lacked one.
      
      Fixed by deferring instantiation of default member initializers until
      they are needed during constructor analysis. This addresses a long
      standing FIXME in the code.
      
      Fixes PR19195.
      
      Reviewed By: rsmith
      
      Differential Revision: http://reviews.llvm.org/D5690
      
      llvm-svn: 222192
      d60b82f9
    • Duncan P. N. Exon Smith's avatar
      IR: Simplify uniquing for MDNode · f39c3b81
      Duncan P. N. Exon Smith authored
      Change uniquing from a `FoldingSet` to a `DenseSet` with custom
      `DenseMapInfo`.  Unfortunately, this doesn't save any memory, since
      `DenseSet<T>` is a simple wrapper for `DenseMap<T, char>`, but I'll come
      back to fix that later.
      
      I used the name `GenericDenseMapInfo` to the custom `DenseMapInfo` since
      I'll be splitting `MDNode` into two classes soon: `MDNodeFwdDecl` for
      temporaries, and `GenericMDNode` for everything else.
      
      I also added a non-debug-info reduced version of a type-uniquing test
      that started failing on an earlier draft of this patch.
      
      Part of PR21532.
      
      llvm-svn: 222191
      f39c3b81
    • Enrico Granata's avatar
      Fix a problem where the StringPrinter could be mistaking an empty string for a... · 099263b4
      Enrico Granata authored
      Fix a problem where the StringPrinter could be mistaking an empty string for a read error, and reporting spurious 'unable to read data' messages. rdar://19007243
      
      llvm-svn: 222190
      099263b4
    • Enrico Granata's avatar
      Add APIs on SBFunction and SBCompileUnit to inquire about the language type... · 6cd8e0c9
      Enrico Granata authored
      Add APIs on SBFunction and SBCompileUnit to inquire about the language type that the function/compile unit is defined in
      
      llvm-svn: 222189
      6cd8e0c9
  2. Nov 17, 2014
Loading