1. Jan 25, 2014
    • Richard Smith's avatar
      Allow virt-specifiers after GNU attributes in member-declarators. GCC doesn't · 4b5a9498
      Richard Smith authored
      allow this, and we should warn on it, but it turns out that people were already
      relying on this.
      
      We should introduce a -Wgcc-compat warning for this if the attributes are known
      to GCC, but we don't currently track enough information about attributes to do
      so reliably.
      
      llvm-svn: 200045
      4b5a9498
    • Tim Northover's avatar
      ARM: also remove useless .arm directive from other files · 7449bda3
      Tim Northover authored
      llvm-svn: 200044
      7449bda3
    • Tim Northover's avatar
      ARM: remove unnecessary .arm directive · 5386cae6
      Tim Northover authored
      It was redundant (since ARM mode is the default) and misleading since
      (e.g.) Cortex-A15 would not satisfy the #ifdef but would be in ARM
      mode regardless.
      
      llvm-svn: 200043
      5386cae6
    • Rafael Espindola's avatar
      Fix c++03 build. · 09419ad6
      Rafael Espindola authored
      llvm-svn: 200042
      09419ad6
    • Aaron Ballman's avatar
      Adds a getSemanticSpelling function to semantic attribute subclasses which... · 81cb8cbf
      Aaron Ballman authored
      Adds a getSemanticSpelling function to semantic attribute subclasses which have a meaningful semantic spelling. Adds a sibling function to parsed attribtues (via AttributeList) for getting the semantic spelling, if one were to exist. This can be used for cleaner code that deals directly with the semantic spellings (such as the MSInheritance attribute).
      
      llvm-svn: 200041
      81cb8cbf
    • Rafael Espindola's avatar
      Make ObjectFile ownership of the MemoryBuffer optional. · afcc3df7
      Rafael Espindola authored
      This allows llvm-ar to mmap the input files only once.
      
      llvm-svn: 200040
      afcc3df7
    • Bob Wilson's avatar
      Fix a typo "endi" -> "endif" in r200035. · 1b392619
      Bob Wilson authored
      llvm-svn: 200039
      1b392619
    • Rui Ueyama's avatar
      Support/COFF: Fix PEHeader struct, and define PE32Header as its alias. · fa5900a6
      Rui Ueyama authored
      This change does not affect anything because everybody seems to be using
      Object/COFF.h instead. But the definition is not for PE32 but for PE32+,
      so fix it anyway.
      
      llvm-svn: 200038
      fa5900a6
    • Craig Topper's avatar
      3f9978e6
    • Craig Topper's avatar
      Replace tablegen uses of EVT with MVT. Add isOverloaded() to MVT to... · 8561de90
      Craig Topper authored
      Replace tablegen uses of EVT with MVT. Add isOverloaded() to MVT to facilitate. Remove TGValueTypes.cpp since its unused now (and may have been before).
      
      llvm-svn: 200036
      8561de90
    • Joerg Sonnenberger's avatar
      Don't use .arm for ARMv7M, which will use the hwdiv path. Non-hwdiv · 2fb149b9
      Joerg Sonnenberger authored
      remains ARM mode only, supporting thumb requires explicit it prefixes
      for the predicted adds/subs and adjusting the offset computation for the
      different block sizes.
      
      llvm-svn: 200035
      2fb149b9
    • Juergen Ributzka's avatar
      Add Constant Hoisting Pass · 4f3df4ad
      Juergen Ributzka authored
      Retry commit r200022 with a fix for the build bot errors. Constant expressions
      have (unlike instructions) module scope use lists and therefore may have users
      in different functions. The fix is to simply ignore these out-of-function uses.
      
      llvm-svn: 200034
      4f3df4ad
    • Hal Finkel's avatar
      Fix DAGCombiner::GatherAllAliases to account for non-chain dependencies · 51a98380
      Hal Finkel authored
      DAGCombiner::GatherAllAliases, which is only used when AA used is enabled
      during DAGCombine, had a fundamentally incorrect assumption for which this
      change compensates. GatherAllAliases, which is used to find aliasing
      predecessor chain nodes (so that a better chain can be selected for a load or
      store to enable subsequent optimizations) assumed that walking up the chain
      would always catch all possibly-aliasing loads and stores. This is not true: To
      really find all aliases, we also need to search for aliases through the value
      operand of a store, etc.  Consider the following situation:
      
        Token1 = ...
        L1 = load Token1, %52
        S1 = store Token1, L1, %51
        L2 = load Token1, %52+8
        S2 = store Token1, L2, %51+8
        Token2 = Token(S1, S2)
        L3 = load Token2, %53
        S3 = store Token2, L3, %52
        L4 = load Token2, %53+8
        S4 = store Token2, L4, %52+8
      
      If we search for aliases of S3 (which loads address %52), and we look only
      through the chain, then we'll miss the trivial dependence on L1 (which loads
      from %52). We then might change all loads and stores to use Token1 as their
      chain operand, which could result in copying %53 into %52 before copying
      %52 into %51 (which should happen first).
      
      The problem is, however, that searching for such data dependencies can become
      expensive, and the cost is not directly related to the chain depth. Instead,
      we'll rule out such configurations by insisting that we've visited all chain
      users (except for users of the original chain, which is not necessary).  When
      doing this, we need to look through nodes we don't care about (otherwise,
      things like register copies will interfere with trivial use cases).
      
      Unfortunately, I don't have a small test case for this problem. Creating the
      underlying situation is not hard (a pair of memcpys will do it), but arranging
      for the default instruction schedule to be incorrect is very fragile.
      
      This unbreaks self hosting on PPC64 when using
      -mllvm -combiner-global-alias-analysis -mllvm -combiner-alias-analysis.
      
      llvm-svn: 200033
      51a98380
    • Aaron Ballman's avatar
      Since Visual Studio 2012 is the minimum version of MSVC we support, the... · 83f197b6
      Aaron Ballman authored
      Since Visual Studio 2012 is the minimum version of MSVC we support, the old-style visualizers are being removed. Adding a Natvis replacement for the debugging visualizers.
      
      llvm-svn: 200032
      83f197b6
    • Yunzhong Gao's avatar
      Fixing PR18510 by checking whether the non-virtual base of the derived class · 063763ea
      Yunzhong Gao authored
      might have a smaller size as compared to the stand-alone type of the base class.
      This is possible when the derived class is packed and hence might have smaller
      alignment requirement than the base class.
      
      Differential Revision: http://llvm-reviews.chandlerc.com/D2599
      
      llvm-svn: 200031
      063763ea
    • Bill Wendling's avatar
      Verify that attributes are not lost during linking. · 3c68b0d4
      Bill Wendling authored
      We don't want to lose attributes when a function decl without them is merged
      with a function decl that has them.
      PR2382
      
      llvm-svn: 200030
      3c68b0d4
    • Rui Ueyama's avatar
      [PECOFF] Accept /machine:x64 option. · 49bfd503
      Rui Ueyama authored
      This is the first patch to support PE32+ format, which is the image format
      to use 64 bit address space on Windows/x86-64.
      
      llvm-svn: 200029
      49bfd503
    • Benjamin Kramer's avatar
      InstCombine: Don't try to use aggregate elements of ConstantExprs. · 09b0f88a
      Benjamin Kramer authored
      PR18600.
      
      llvm-svn: 200028
      09b0f88a
    • Lang Hames's avatar
      Add a testcase for the changes in r199938. · c63c52e0
      Lang Hames authored
      <rdar://problem/15611947>
      
      llvm-svn: 200027
      c63c52e0
    • Juergen Ributzka's avatar
      Revert "Add Constant Hoisting Pass" · 50e7e80d
      Juergen Ributzka authored
      This reverts commit r200022 to unbreak the build bots.
      
      llvm-svn: 200024
      50e7e80d
    • Hal Finkel's avatar
      Restrict FindBetterChain DAG combines to unindexed nodes · ccc18e13
      Hal Finkel authored
      These transformations obviously won't work for indexed (pre/post-inc) loads and
      stores. In practice, I'm not sure there is any benefit to enabling them for
      indexed nodes because other transformations that these might enable likely also
      won't handle indexed nodes.
      
      I don't have an in-tree test case that hits this problem, but an upcoming bug
      fix will make it much more likely.
      
      llvm-svn: 200023
      ccc18e13
    • Juergen Ributzka's avatar
      Add Constant Hoisting Pass · 38b67d0c
      Juergen Ributzka authored
      This pass identifies expensive constants to hoist and coalesces them to
      better prepare it for SelectionDAG-based code generation. This works around the
      limitations of the basic-block-at-a-time approach.
      
      First it scans all instructions for integer constants and calculates its
      cost. If the constant can be folded into the instruction (the cost is
      TCC_Free) or the cost is just a simple operation (TCC_BASIC), then we don't
      consider it expensive and leave it alone. This is the default behavior and
      the default implementation of getIntImmCost will always return TCC_Free.
      
      If the cost is more than TCC_BASIC, then the integer constant can't be folded
      into the instruction and it might be beneficial to hoist the constant.
      Similar constants are coalesced to reduce register pressure and
      materialization code.
      
      When a constant is hoisted, it is also hidden behind a bitcast to force it to
      be live-out of the basic block. Otherwise the constant would be just
      duplicated and each basic block would have its own copy in the SelectionDAG.
      The SelectionDAG recognizes such constants as opaque and doesn't perform
      certain transformations on them, which would create a new expensive constant.
      
      This optimization is only applied to integer constants in instructions and
      simple (this means not nested) constant cast experessions. For example:
      %0 = load i64* inttoptr (i64 big_constant to i64*)
      
      Reviewed by Eric
      
      llvm-svn: 200022
      38b67d0c
    • Juergen Ributzka's avatar
      3e752e7a
    • Juergen Ributzka's avatar
      Doxify comments · 63e5c1fd
      Juergen Ributzka authored
      llvm-svn: 200020
      63e5c1fd
    • Rui Ueyama's avatar
      [PECOFF] Use constant instead of magic number. · 87e15c75
      Rui Ueyama authored
      llvm-svn: 200019
      87e15c75
    • Alp Toker's avatar
      Fix known typos · cb402911
      Alp Toker authored
      Sweep the codebase for common typos. Includes some changes to visible function
      names that were misspelt.
      
      llvm-svn: 200018
      cb402911
    • Alp Toker's avatar
      Report lli remote IO errors consistently · ad6aa47c
      Alp Toker authored
      This enables IO error reports in both the child and server processes.
      
      The scheme still isn't entirely satisfactory and output is jumbled but it beats
      having no output at all. This will hopefully unblock ARM support (PR18057).
      
      llvm-svn: 200017
      ad6aa47c
    • Benjamin Kramer's avatar
      5e1794ee
    • Dmitry Vyukov's avatar
      tsan: fix test for -O2 · 3ee32e76
      Dmitry Vyukov authored
      otherwise races are suppressed due to "same stack"
      
      llvm-svn: 200015
      3ee32e76
    • Rafael Espindola's avatar
      Unify duplicated functions. · e7583756
      Rafael Espindola authored
      llvm-svn: 200014
      e7583756
  2. Jan 24, 2014