and though bugs are the bane of my existence, rest assured the wretched thing will get the best of care here

  1. 28 Apr, 2017 1 commit
    • Brad Smith's avatar
      Merging r297098: · 6269fe42
      Brad Smith authored
      ```---------------------------------------------------------------------
      r297098 | brad | 2017-03-06 18:48:31 -0500 (Mon, 06 Mar 2017) | 2 lines
      
      Set the Int64Type / IntMaxType types correctly for OpenBSD/mips64
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 301605
      6269fe42
  2. 27 Apr, 2017 1 commit
    • Krzysztof Parzyszek's avatar
      Merging r296645: (PR32253) · ba8e6140
      Krzysztof Parzyszek authored
      Included an updated testcase
      
      ------------------------------------------------------------------------
      [Hexagon] Fix lowering of formal arguments of type i1
      
      On Hexagon, values of type i1 are passed in registers of type i32,
      even though i1 is not a legal value for these registers. This is a
      special case and needs special handling to maintain consistency of
      the lowering information.
      
      This fixes PR32089.
      ------------------------------------------------------------------------
      
      llvm-svn: 301550
      ba8e6140
  3. 26 Apr, 2017 9 commits
    • Hans Wennborg's avatar
      Merging r292034: (PR32315) · f761e7d6
      Hans Wennborg authored
      Tweaked to not remove the non-const variants as to not change the ABI.
      
      ------------------------------------------------------------------------
      r292034 | majnemer | 2017-01-14 13:54:58 -0800 (Sat, 14 Jan 2017) | 7 lines
      
      Adding const overloads of operator* and operator-> for DenseSet iterators
      
      This fixes some problems when building ClangDiagnostics.cpp on Visual Studio 2017 RC. As far as I understand, there was a change in the implementation of the constructor for std::vector with two iterator parameters, which in our case causes an attempt to dereference const Iterator objects. Since there was no overload for a const Iterator, the compile would fail.
      
      Patch by Hugo Puhlmann!
      
      Differential Revision: https://reviews.llvm.org/D28726
      ------------------------------------------------------------------------
      
      llvm-svn: 301479
      f761e7d6
    • Tom Stellard's avatar
      Merging r299574: · 6ccc7b46
      Tom Stellard authored
      ```---------------------------------------------------------------------
      r299574 | nico | 2017-04-05 14:10:42 -0400 (Wed, 05 Apr 2017) | 17 lines
      
      clang-format: Support formatting utf-8 character literals in C++11+ mode.
      
      clang-format <<END
      auto c1 = u8'a';
      auto c2 = u'a';
      END
      
      Before:
        auto c1 = u8 'a';
        auto c2 = u'a';
      
      Now:
        auto c1 = u8'a';
        auto c2 = u'a';
      
      Patch from Denis Gladkikh <llvm@denis.gladkikh.email>!
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 301463
      6ccc7b46
    • Tom Stellard's avatar
      Merging r294786: · a6353c45
      Tom Stellard authored
      ```---------------------------------------------------------------------
      r294786 | yaxunl | 2017-02-10 16:46:07 -0500 (Fri, 10 Feb 2017) | 24 lines
      
      Fix invalid addrspacecast due to combining alloca with global var
      
      For function-scope variables with large initialisation list, FE usually
      generates a global variable to hold the initializer, then generates
      memcpy intrinsic to initialize the alloca. InstCombiner::visitAllocaInst
      identifies such allocas which are accessed only by reading and replaces
      them with the global variable. This is done by casting the global variable
      to the type of the alloca and replacing all references.
      
      However, when the global variable is in a different address space which
      is disjoint with addr space 0 (e.g. for IR generated from OpenCL,
      global variable cannot be in private addr space i.e. addr space 0), casting
      the global variable to addr space 0 results in invalid IR for certain
      targets (e.g. amdgpu).
      
      To fix this issue, when the global variable is not in addr space 0,
      instead of casting it to addr space 0, this patch chases down the uses
      of alloca until reaching the load instructions, then replaces load from
      alloca with load from the global variable. If during the chasing
      bitcast and GEP are encountered, new bitcast and GEP based on the global
      variable are generated and used in the load instructions.
      
      Differential Revision: https://reviews.llvm.org/D27283
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 301452
      a6353c45
    • Rui Ueyama's avatar
    • Rui Ueyama's avatar
      Merge r298568: Print out "suppoted targets" · 3c833140
      Rui Ueyama authored
      llvm-svn: 301446
      3c833140
    • Rui Ueyama's avatar
      Merge r298570: Fix Windows buildbots · af86b564
      Rui Ueyama authored
      llvm-svn: 301445
      af86b564
    • Rui Ueyama's avatar
      57032a18
    • Tom Stellard's avatar
      Merging r300429: · 12454867
      Tom Stellard authored
      ```---------------------------------------------------------------------
      r300429 | d0k | 2017-04-16 16:13:08 -0400 (Sun, 16 Apr 2017) | 7 lines
      
      [X86] Remove special handling for 16 bit for A asm constraints.
      
      Our 16 bit support is assembler-only + the terrible hack that is
      .code16gcc. Simply using 32 bit registers does the right thing for the
      latter.
      
      Fixes PR32681.
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 301437
      12454867
    • Tom Stellard's avatar
      Merging r300404: · 39445ab0
      Tom Stellard authored
      ```---------------------------------------------------------------------
      r300404 | dim | 2017-04-15 18:15:01 -0400 (Sat, 15 Apr 2017) | 22 lines
      
      Use correct registers for "A" inline asm constraint
      
      Summary:
      In PR32594, inline assembly using the 'A' constraint on x86_64 causes
      llvm to crash with a "Cannot select" stack trace.  This is because
      `X86TargetLowering::getRegForInlineAsmConstraint` hardcodes that 'A'
      means the EAX and EDX registers.
      
      However, on x86_64 it means the RAX and RDX registers, and on 16-bit x86
      (ia16?) it means the old AX and DX registers.
      
      Add new register classes in `X86RegisterInfo.td` to support these cases,
      and amend the logic in `getRegForInlineAsmConstraint` to cope with
      different subtargets.  Also add a test case, derived from PR32594.
      
      Reviewers: craig.topper, qcolombet, RKSimon, ab
      
      Reviewed By: ab
      
      Subscribers: ab, emaste, royger, llvm-commits
      
      Differential Revision: https://reviews.llvm.org/D31902
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 301436
      39445ab0
  4. 24 Apr, 2017 1 commit
    • Simon Dardis's avatar
      Merging r296105, r296016 and 296111: · 933e616b
      Simon Dardis authored
      ```---------------------------------------------------------------------
      r296105 | sdardis | 2017-02-24 10:50:27 +0000 (Fri, 24 Feb 2017) | 13 lines
      
      [mips][mc] Fix a crash when disassembling odd sized sections
      
      Make the MIPS disassembler consistent with the other targets in returning
      a Size of zero when the input buffer cannot contain an instruction due
      to it's size. Previously it reported the minimum instruction size when
      it failed due to the buffer not being big enough for an instruction
      causing llvm-objdump to crash when disassembling all sections.
      
      Reviewers: slthakur
      
      Differential Revision: https://reviews.llvm.org/D29984
      ```
      
      ---------------------------------------------------------------------
      ------------------------------------------------------------------------
      r296106 | sdardis | 2017-02-24 10:51:27 +0000 (Fri, 24 Feb 2017) | 5 lines
      
      [mips][mc] Fix a crash when disassembling odd sized sections
      
      Corresponding test.
      
      
      ------------------------------------------------------------------------
      ------------------------------------------------------------------------
      r296111 | rovka | 2017-02-24 12:47:11 +0000 (Fri, 24 Feb 2017) | 1 line
      
      Fixup r296105 - only run tests on Mips
      ------------------------------------------------------------------------
      
      llvm-svn: 301169
      933e616b
  5. 22 Apr, 2017 6 commits
    • Brad Smith's avatar
      Merging r299269: · d14b74f6
      Brad Smith authored
      ```---------------------------------------------------------------------
      r299269 | brad | 2017-03-31 18:13:17 -0400 (Fri, 31 Mar 2017) | 2 lines
      
      Add/update PIE defaults for OpenBSD.
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 301087
      d14b74f6
    • Brad Smith's avatar
      Merging r296430: · dabd1af0
      Brad Smith authored
      ```---------------------------------------------------------------------
      r296430 | brad | 2017-02-27 22:20:26 -0500 (Mon, 27 Feb 2017) | 2 lines
      
      Set ABIs correctly for OpenBSD/arm; soft float and aapcs-linux.
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 301086
      dabd1af0
    • Brad Smith's avatar
      Merging r295786: · 1e8b1a88
      Brad Smith authored
      ```---------------------------------------------------------------------
      r295786 | brad | 2017-02-21 18:13:09 -0500 (Tue, 21 Feb 2017) | 2 lines
      
      Hook up OpenBSD AArch64 support
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 301085
      1e8b1a88
    • Brad Smith's avatar
      Merging r295635: · 78b623bc
      Brad Smith authored
      ```---------------------------------------------------------------------
      r295635 | brad | 2017-02-19 22:18:15 -0500 (Sun, 19 Feb 2017) | 5 lines
      
      Enable support for __float128 in Clang on OpenBSD/X86
      
      /usr/local/include/c++/4.9.4/type_traits:279:39: error: __float128 is not
      supported on this target
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 301084
      78b623bc
    • Brad Smith's avatar
      Merging r295614: · 8abd5fe4
      Brad Smith authored
      ```---------------------------------------------------------------------
      r295614 | brad | 2017-02-19 15:11:48 -0500 (Sun, 19 Feb 2017) | 2 lines
      
      Always use --eh-frame-hdr on OpenBSD, even for -static
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 301083
      8abd5fe4
    • Brad Smith's avatar
      Merging r296493: · 200fcffe
      Brad Smith authored
      ```---------------------------------------------------------------------
      r296493 | brad | 2017-02-28 12:28:35 -0500 (Tue, 28 Feb 2017) | 2 lines
      
      Set default CPU for OpenBSD/arm to Cortex-A8
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 301082
      200fcffe
  6. 21 Apr, 2017 1 commit
    • Tom Stellard's avatar
      Merging r298604: · 0d229e0c
      Tom Stellard authored
      ```---------------------------------------------------------------------
      r298604 | niravd | 2017-03-23 11:01:50 -0400 (Thu, 23 Mar 2017) | 14 lines
      
      [SDAG] Fix zeroExtend assertion error
      
      Move CombineTo preventing deleted node from being returned in
      visitZERO_EXTEND.
      
      Fixes PR32284.
      
      Reviewers: RKSimon, bogner
      
      Reviewed By: RKSimon
      
      Subscribers: llvm-commits
      
      Differential Revision: https://reviews.llvm.org/D31254
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 300979
      0d229e0c
  7. 06 Apr, 2017 1 commit
    • Tom Stellard's avatar
      Merging r296698: · 2a8b38be
      Tom Stellard authored
      ```---------------------------------------------------------------------
      r296698 | rnk | 2017-03-01 17:41:12 -0500 (Wed, 01 Mar 2017) | 10 lines
      
      [Constant Hoisting] Avoid inserting instructions before EH pads
      
      Now that terminators can be EH pads, this code needs to iterate over the
      immediate dominators of the EH pad to find a valid insertion point.
      
      Fix for PR32107
      
      Patch by Robert Olliff!
      
      Differential Revision: https://reviews.llvm.org/D30511
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 299670
      2a8b38be
  8. 04 Apr, 2017 5 commits
    • Tom Stellard's avatar
      Merging r298705: · d70b75e8
      Tom Stellard authored
      ```---------------------------------------------------------------------
      r298705 | tstellar | 2017-03-24 12:13:18 -0400 (Fri, 24 Mar 2017) | 11 lines
      
      stable-merge-request.sh: Add a script for submitting merge requests via bugzilla
      
      Summary:
      This script will automatically create a new stable merge request bug in
      bugzilla for the given svn revision and release number.
      
      Reviewers: hans
      
      Subscribers: llvm-commits
      
      Differential Revision: https://reviews.llvm.org/D30905
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 299455
      d70b75e8
    • Tom Stellard's avatar
      Merging r298551: · 52af6b97
      Tom Stellard authored
      ```---------------------------------------------------------------------
      r298551 | kzhuravl | 2017-03-22 17:48:18 -0400 (Wed, 22 Mar 2017) | 4 lines
      
      [AMDGPU] Fix bug 31610
      
      Differential Revision: https://reviews.llvm.org/D31258
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 299441
      52af6b97
    • Tom Stellard's avatar
      Partial merge of r293110 into the 4.0 branch · db94c8bf
      Tom Stellard authored
      Avoid printing optimization remarks from llc unless they are enabled.
      
      Fixes http://llvm.org/PR32184
      
      llvm-svn: 299409
      db94c8bf
    • Craig Topper's avatar
      Merging r299347: · 09f3db4d
      Craig Topper authored
      ```---------------------------------------------------------------------
      r299347 | ctopper | 2017-04-02 20:51:57 -0700 (Sun, 02 Apr 2017) | 1 line
      
      [AVX-512] Fix a couple more intrinsic macros I missed in r299346.
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 299405
      09f3db4d
    • Craig Topper's avatar
      Merging r299346: · baa8fddf
      Craig Topper authored
      ```---------------------------------------------------------------------
      r299346 | ctopper | 2017-04-02 20:41:29 -0700 (Sun, 02 Apr 2017) | 3 lines
      
      [AVX-512] Fix some intrinsic macros that use the wrong macro parameter names and don't have parentheses around them.
      
      Thanks to Matthew Barr for reporting this issue.
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 299404
      baa8fddf
  9. 23 Mar, 2017 1 commit
  10. 07 Mar, 2017 4 commits
    • Hans Wennborg's avatar
      ReleaseNotes: fix indent · ed7ec907
      Hans Wennborg authored
      llvm-svn: 297204
      ed7ec907
    • Hans Wennborg's avatar
      ReleaseNotes: fix the VS version; follow-up to r297097 · 62364efb
      Hans Wennborg authored
      llvm-svn: 297203
      62364efb
    • Hans Wennborg's avatar
      Merging r297075: · ab7cbc9a
      Hans Wennborg authored
      ```---------------------------------------------------------------------
      r297075 | hans | 2017-03-06 13:10:40 -0800 (Mon, 06 Mar 2017) | 1 line
      
      Disable gvn-hoist (PR32153)
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 297165
      ab7cbc9a
    • Hans Wennborg's avatar
      Merging r296992: · d251e94e
      Hans Wennborg authored
      ```---------------------------------------------------------------------
      r296992 | sanjoy | 2017-03-05 15:49:17 -0800 (Sun, 05 Mar 2017) | 7 lines
      
      [SCEV] Decrease the recursion threshold for CompareValueComplexity
      
      Fixes PR32142.
      
      r287232 accidentally increased the recursion threshold for
      CompareValueComplexity from 2 to 32.  This change reverses that change
      by introducing a separate flag for CompareValueComplexity's threshold.
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 297164
      d251e94e
  11. 06 Mar, 2017 2 commits
  12. 02 Mar, 2017 3 commits
    • Eric Fiselier's avatar
      Update ABI lists and changelog for final 4.0 release · d07c41fa
      Eric Fiselier authored
      llvm-svn: 296804
      d07c41fa
    • Hans Wennborg's avatar
      Merging r296656: · 4adb2ddb
      Hans Wennborg authored
      ```---------------------------------------------------------------------
      r296656 | bruno | 2017-03-01 11:18:42 -0800 (Wed, 01 Mar 2017) | 34 lines
      
      [PCH] Avoid VarDecl emission attempt if no owning module avaiable
      
      This is a stopgap fix for PR31863, a regression introduced in r276159.
      
      Consider this snippet:
      
      struct FVector;
      struct FVector {};
      struct FBox {
        FVector Min;
        FBox(int);
      };
      namespace {
      FBox InvalidBoundingBox(0);
      }
      
      While parsing the DECL_VAR for 'struct FBox', clang recursively read all the
      dep decls until it finds the DECL_CXX_RECORD forward declaration for 'struct
      FVector'. Then, it resumes all the way up back to DECL_VAR handling in
      `ReadDeclRecord`, where it checks if `isConsumerInterestedIn` for the decl.
      
      One of the condition for `isConsumerInterestedIn` to return false is if the
      VarDecl is imported from a module `D->getImportedOwningModule()`, because it
      will get emitted when we import the relevant module. However, before checking
      if it comes from a module, clang checks if `Ctx.DeclMustBeEmitted(D)`, which
      triggers the emission of 'struct FBox'. Since one of its fields is still
      incomplete, it crashes.
      
      Instead, check if `D->getImportedOwningModule()` is true before calling
      `Ctx.DeclMustBeEmitted(D)`.
      
      Differential Revision: https://reviews.llvm.org/D29753
      
      rdar://problem/30173654
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 296762
      4adb2ddb
    • Hans Wennborg's avatar
      Merging r296642: · f51dd7e3
      Hans Wennborg authored
      ```---------------------------------------------------------------------
      r296642 | hans | 2017-03-01 09:15:08 -0800 (Wed, 01 Mar 2017) | 5 lines
      
      [GVNHoist] Don't hoist unsafe scalars at -Oz (PR31729)
      
      Based on Aditya Kumar's patch:
      
      Differential Revision: https://reviews.llvm.org/D29092
      ```
      
      ---------------------------------------------------------------------
      
      llvm-svn: 296761
      f51dd7e3
  13. 01 Mar, 2017 2 commits
  14. 28 Feb, 2017 1 commit
  15. 27 Feb, 2017 2 commits
    • Hans Wennborg's avatar
      Merging r296093 and r296260: · 68b9f14f
      Hans Wennborg authored
      ```---------------------------------------------------------------------
      r296093 | ctopper | 2017-02-23 22:38:24 -0800 (Thu, 23 Feb 2017) | 1 line
      
      [ExecutionDepsFix] Use range-based for loop. NFC
      ```
      
      ---------------------------------------------------------------------
      
      ------------------------------------------------------------------------
      r296260 | ctopper | 2017-02-25 10:12:25 -0800 (Sat, 25 Feb 2017) | 18 lines
      
      [ExecutionDepsFix] Don't make copies of LiveReg objects when collecting operands for soft instructions
      
      Summary:
      While collecting operands we make copies of the LiveReg objects which are stored in the LiveRegs array. If the instruction uses the same register multiple times we end up with multiple copies. Later we iterate through the collected list of LiveReg objects and merge DomainValues. In the process of doing this the merge function can change the contents of the original LiveReg object in the LiveRegs array, but not the copies that have been made. So when we get to the second usage of the register we end up seeing a stale copy of the LiveReg object.
      
      To fix this I've stopped copying and now just store a pointer to the original LiveReg object. Another option might be to avoid adding the same register to the Regs array twice, but this approach seemed simpler.
      
      The included test case exposes this bug due to an AVX-512 masked OR instruction using the same register for the passthru operand and one of the inputs to the OR operation.
      
      Fixes PR30284.
      
      Reviewers: RKSimon, stoklund, MatzeB, spatel, myatsina
      
      Reviewed By: RKSimon
      
      Subscribers: llvm-commits
      
      Differential Revision: https://reviews.llvm.org/D30242
      ------------------------------------------------------------------------
      
      llvm-svn: 296380
      68b9f14f
    • Hans Wennborg's avatar
      Merging r296358 and r296359: · a20b011d
      Hans Wennborg authored
      ```---------------------------------------------------------------------
      r296358 | aadg | 2017-02-27 09:33:20 -0800 (Mon, 27 Feb 2017) | 8 lines
      
      Add libcxxabi's LICENSE.TXT to libunwind.
      
      When libunwind was spinned off libcxxabi, most file were copied from
      libcxxabi to libunwind.  However, libc++abi's toplevel LICENSE.TXT was
      forgotten in the copying. It's considered a good practice to have the
      license file at the root of the project, and making linunwind a separate
      project was not supposed to change its licensing. Besides, several
      header files refer to the LICENSE.TXT, so copy the one from libc++abi.
      ```
      
      ---------------------------------------------------------------------
      
      ------------------------------------------------------------------------
      r296359 | aadg | 2017-02-27 09:47:58 -0800 (Mon, 27 Feb 2017) | 1 line
      
      Fix the project name in the license file.
      ------------------------------------------------------------------------
      
      llvm-svn: 296364
      a20b011d