1. Sep 16, 2016
    • Eric Fiselier's avatar
      Move inline attributes in filesystem to first declaration · 1b17a4b7
      Eric Fiselier authored
      llvm-svn: 281683
      1b17a4b7
    • Akira Hatanaka's avatar
      [CodeGen][ObjC] Block captures should inherit the type of the captured · d542ccfc
      Akira Hatanaka authored
      field in the enclosing lambda or block.
      
      This patch fixes a bug in code-gen where it uses the type of the
      declared variable rather than the type of the capture of the enclosing
      lambda or block for the block capture. For example, in the following
      function, code-gen currently uses i32* for the block capture "a" because
      "a" is passed to foo1 as a reference, but it should use i32 since the
      enclosing lambda captures "a" by value.
      
      void foo1(int &a) {
        auto lambda = [a]{
          auto block1 = ^{
            i = a;
          };
          block1();
        };
        lambda();
      }
      
      rdar://problem/18586386
      
      Differential Revision: https://reviews.llvm.org/D21104
      
      llvm-svn: 281682
      d542ccfc
    • Eric Fiselier's avatar
      [libc++] Add _LIBCPP_EXTERN_TEMPLATE_INLINE_VISIBILITY to support GCC ABI compatibility · f8f31c49
      Eric Fiselier authored
      Summary:
      GCC and Clang handle visibility attributes on the out-of-line definition of externally instantiated templates differently. For example in the reproducer below Clang will emit both 'foo' and 'bar' with default visibility while GCC only emits a non-hidden 'foo'.  
      
      ```
      // RUN: g++ -std=c++11 -shared -O3 test.cpp && sym_extract.py a.out
      // RUN: clang++ -std=c++11 -shared -O3 test.cpp && sym_extract.py a.out
      #define INLINE_VISIBILITY __attribute__((visibility("hidden"), always_inline))
      
      template <class T>
      struct Foo {
        void foo();
        void bar();
      };
      
      template <class T>
      void Foo<T>::foo() {}
      
      template <class T>
      inline INLINE_VISIBILITY
      void Foo<T>::bar() {}
      
      template struct Foo<int>;
      ```
      
      This difference creates ABI incompatibilities between Clang and GCC built dylibs. Specifically GCC built dylibs lack definitions for various member functions of `basic_string`, `basic_istream`, `basic_ostream`, `basic_iostream`, and `basic_streambuf` (All of these types are externally instantiated). 
      
      Surprisingly these missing symbols don't cause many problems because the functions are marked `always_inline`  therefore the dylib definition is rarely needed. However when an out-of-line definition is required then GCC built dylibs will fail to link. For example [GCC built dylibs cannot build Clang](http://stackoverflow.com/questions/39454262/clang-build-errors).
      
      This patch works around this issue by adding `_LIBCPP_EXTERN_TEMPLATE_INLINE_VISIBILITY` which is used to mark externally instantiated member functions as always inline. When building the library `_LIBCPP_EXTERN_TEMPLATE_INLINE_VISIBILITY` sets the symbol's visibility to "default" instead of "hidden", otherwise it acts exactly the same as `_LIBCPP_INLINE_VISIBILITY`.
      
      After applying this patch GCC dylibs now contain:
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE7sungetcEv`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE5gbumpEi`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE7sungetcEv`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE9sputbackcEc`
        * `_ZNSt3__113basic_istreamIwNS_11char_traitsIwEEE3getERNS_15basic_streambufIwS2_EE`
        * `_ZNSt3__113basic_ostreamIwNS_11char_traitsIwEEElsEPFRNS_9basic_iosIwS2_EES6_E`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE4setpEPcS4_`
        * `_ZNSt3__113basic_ostreamIwNS_11char_traitsIwEEEC1EPNS_15basic_streambufIwS2_EE`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE6snextcEv`
        * `_ZNSt3__113basic_istreamIcNS_11char_traitsIcEEE4swapERS3_`
        * `_ZNSt3__113basic_istreamIwNS_11char_traitsIwEEE4swapERS3_`
        * `_ZNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE6__initEPKcm`
        * `_ZNSt3__113basic_istreamIcNS_11char_traitsIcEEErsEPFRNS_8ios_baseES5_E`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE9pubsetbufEPcl`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE10pubseekoffExNS_8ios_base7seekdirEj`
        * `_ZNSt3__113basic_istreamIwNS_11char_traitsIwEEErsEPFRNS_9basic_iosIwS2_EES6_E`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE5pbumpEi`
        * `_ZNSt3__113basic_ostreamIcNS_11char_traitsIcEEE5seekpENS_4fposI11__mbstate_tEE`
        * `_ZNSt3__113basic_istreamIcNS_11char_traitsIcEEE7getlineEPcl`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE5sgetcEv`
        * `_ZNSt3__113basic_istreamIcNS_11char_traitsIcEEE3getERNS_15basic_streambufIcS2_EE`
        * `_ZNSt3__113basic_ostreamIcNS_11char_traitsIcEEElsEPFRNS_8ios_baseES5_E`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE8in_availEv`
        * `_ZNSt3__113basic_istreamIwNS_11char_traitsIwEEErsEPFRNS_8ios_baseES5_E`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE6sbumpcEv`
        * `_ZNSt3__113basic_ostreamIcNS_11char_traitsIcEEElsEPFRNS_9basic_iosIcS2_EES6_E`
        * `_ZNSt3__113basic_istreamIcNS_11char_traitsIcEEE3getERc`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE6snextcEv`
        * `_ZNSt3__112basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEE6__initEmw`
        * `_ZNSt3__113basic_istreamIwNS_11char_traitsIwEEE7getlineEPwl`
        * `_ZNSt3__113basic_ostreamIcNS_11char_traitsIcEEE5tellpEv`
        * `_ZNSt3__113basic_istreamIwNS_11char_traitsIwEEE3getERw`
        * `_ZNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE6__initEmc`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE7pubsyncEv`
        * `_ZNSt3__113basic_istreamIcNS_11char_traitsIcEEE3getEPcl`
        * `_ZNSt3__113basic_istreamIcNS_11char_traitsIcEEEC2EPNS_15basic_streambufIcS2_EE`
        * `_ZNSt3__113basic_istreamIcNS_11char_traitsIcEEErsEPFRNS_9basic_iosIcS2_EES6_E`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE7pubsyncEv`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE5sputcEc`
        * `_ZNSt3__113basic_ostreamIwNS_11char_traitsIwEEE5seekpExNS_8ios_base7seekdirE`
        * `_ZNKSt3__115basic_streambufIcNS_11char_traitsIcEEE6getlocEv`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE5gbumpEi`
        * `_ZNSt3__114basic_iostreamIcNS_11char_traitsIcEEE4swapERS3_`
        * `_ZNSt3__113basic_ostreamIwNS_11char_traitsIwEEE5seekpENS_4fposI11__mbstate_tEE`
        * `_ZNSt3__113basic_ostreamIwNS_11char_traitsIwEEE5tellpEv`
        * `_ZNSt3__113basic_ostreamIwNS_11char_traitsIwEEElsEPFRS3_S4_E`
        * `_ZNSt3__113basic_istreamIwNS_11char_traitsIwEEE3getEPwl`
        * `_ZNSt3__113basic_istreamIwNS_11char_traitsIwEEEC2EPNS_15basic_streambufIwS2_EE`
        * `_ZNSt3__113basic_ostreamIcNS_11char_traitsIcEEElsEPFRS3_S4_E`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE4setgEPcS4_S4_`
        * `_ZNSt3__112basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEE6__initEPKwmm`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE4setgEPwS4_S4_`
        * `_ZNSt3__113basic_istreamIwNS_11char_traitsIwEEEC1EPNS_15basic_streambufIwS2_EE`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE8pubimbueERKNS_6localeE`
        * `_ZNSt3__113basic_ostreamIcNS_11char_traitsIcEEE4swapERS3_`
        * `_ZNSt3__113basic_ostreamIwNS_11char_traitsIwEEEC2EPNS_15basic_streambufIwS2_EE`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE10pubseekposENS_4fposI11__mbstate_tEEj`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE5pbumpEi`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE5sgetcEv`
        * `_ZNSt3__113basic_ostreamIwNS_11char_traitsIwEEE4swapERS3_`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE10pubseekposENS_4fposI11__mbstate_tEEj`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE5sputnEPKcl`
        * `_ZNSt3__113basic_ostreamIcNS_11char_traitsIcEEE5seekpExNS_8ios_base7seekdirE`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE5sgetnEPwl`
        * `_ZNSt3__113basic_ostreamIwNS_11char_traitsIwEEElsEPFRNS_8ios_baseES5_E`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE4setpEPwS4_`
        * `_ZNSt3__115basic_streambufIcNS_11char_traitsIcEEE5sgetnEPcl`
        * `_ZNKSt3__115basic_streambufIwNS_11char_traitsIwEEE6getlocEv`
        * `_ZNSt3__114basic_iostreamIcNS_11char_traitsIcEEEC2EPNS_15basic_streambufIcS2_EE`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE8pubimbueERKNS_6localeE`
        * `_ZNSt3__114basic_iostreamIcNS_11char_traitsIcEEEC1EPNS_15basic_streambufIcS2_EE`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE8in_availEv`
        * `_ZNSt3__113basic_istreamIcNS_11char_traitsIcEEEC1EPNS_15basic_streambufIcS2_EE`
        * `_ZNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE6__initEPKcmm`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE6sbumpcEv`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE10pubseekoffExNS_8ios_base7seekdirEj`
        * `_ZNSt3__113basic_ostreamIcNS_11char_traitsIcEEEC2EPNS_15basic_streambufIcS2_EE`
        * `_ZNSt3__113basic_istreamIwNS_11char_traitsIwEEErsEPFRS3_S4_E`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE9sputbackcEw`
        * `_ZNSt3__112basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEE6__initEPKwm`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE5sputnEPKwl`
        * `_ZNSt3__113basic_istreamIcNS_11char_traitsIcEEErsEPFRS3_S4_E`
        * `_ZNSt3__113basic_ostreamIcNS_11char_traitsIcEEEC1EPNS_15basic_streambufIcS2_EE`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE9pubsetbufEPwl`
        * `_ZNSt3__115basic_streambufIwNS_11char_traitsIwEEE5sputcEw`
      
      
      This patch has no effect on Clang based builds.
      
      
      
      Reviewers: mclow.lists, eugenis, danalbert, jroelofs, EricWF
      
      Subscribers: beanz, cfe-commits, mgorny
      
      Differential Revision: https://reviews.llvm.org/D24600
      
      llvm-svn: 281681
      f8f31c49
    • Justin Lebar's avatar
      [CUDA] Don't try to run sanitizers on NVPTX. · 6efbc73c
      Justin Lebar authored
      Summary:
      Sanitizers aren't supported on NVPTX -- don't try to run them.
      
      This lets you e.g. pass -fsanitize=address and get asan on your host
      code.
      
      Reviewers: kcc
      
      Subscribers: cfe-commits, tra, jhen
      
      Differential Revision: https://reviews.llvm.org/D24640
      
      llvm-svn: 281680
      6efbc73c
    • Kostya Serebryany's avatar
      [asan] fix window build · 4dd6b50f
      Kostya Serebryany authored
      llvm-svn: 281679
      4dd6b50f
    • Rui Ueyama's avatar
      Check /pdb output using llvm-pdbdump. · 783afd66
      Rui Ueyama authored
      test/COFF/rsds.test checks only RSDS directory in a DLL and
      didn't check the validity of the PDF file produced.
      (Technically the produced PDB is not valid because it is really
      a stub, but this test is still good to have.)
      
      llvm-svn: 281678
      783afd66
    • Kostya Serebryany's avatar
      3e9ce5f4
    • Hans Wennborg's avatar
      build_llvm_package.bat: Update to VS2015 and include LLDB · 4dfe0d89
      Hans Wennborg authored
      llvm-svn: 281676
      4dfe0d89
    • Evgeniy Stepanov's avatar
      [asan] Reenable 64-bit allocator on android/aarch64. · 8652d6ac
      Evgeniy Stepanov authored
      This is a re-commit of r281371, with updated tests.
      
      llvm-svn: 281674
      8652d6ac
    • Eric Fiselier's avatar
      [libc++] Fix and document visibility attributes for Clang, GCC and Windows. · 49e2967f
      Eric Fiselier authored
      Summary:
      This patch fixes a number of problems with the visibility macros across GCC (on Unix) and Windows (DLL import/export semantics). All of the visibility macros are now documented under `DesignDocs/VisibilityMacros.rst`. Now I'll no longer forget the subtleties of each!
      
      This patch adds two new visibility macros:
      
      * `_LIBCPP_ENUM_VIS` for controlling the typeinfo of enum types. Only Clang supports this.
      * `_LIBCPP_EXTERN_TEMPLATE_TYPE_VIS` for redefining visibility on explicit instantiation declarations. Clang and Windows require this.
      
      After applying this patch GCC only emits one -Wattribute warning opposed to 30+.
      
      
      Reviewers: mclow.lists, EricWF
      
      Subscribers: beanz, mgorny, cfe-commits
      
      Differential Revision: https://reviews.llvm.org/D24602
      
      llvm-svn: 281673
      49e2967f
    • Sanjay Patel's avatar
    • Rui Ueyama's avatar
      Fix old copy-n-paste errors. · 8e8296fa
      Rui Ueyama authored
      llvm-svn: 281671
      8e8296fa
    • Rui Ueyama's avatar
      Create PDB.h and move code to remove unnecessary #includes. · 1d99ab39
      Rui Ueyama authored
      llvm-svn: 281670
      1d99ab39
    • Akira Hatanaka's avatar
      [Sema] Allow shifting a scalar operand by a vector operand. · 81986719
      Akira Hatanaka authored
      r278501 inadvertently introduced a bug in which it disallowed shifting
      scalar operands by vector operands when not compiling for OpenCL. This
      commit fixes it.
      
      Patch by Vladimir Yakovlev.
      
      Differential Revision: https://reviews.llvm.org/D24467
      
      llvm-svn: 281669
      81986719
    • Anna Zaks's avatar
      [sanitizer] Fixup 2: Do not introduce __sanitizer namespace globally · de3fb6f0
      Anna Zaks authored
      This got committed by mistake. Should fix some bots.
      
      llvm-svn: 281668
      de3fb6f0
    • Kostya Serebryany's avatar
      [libFuzzer] make caller-callee feedback work with trace-pc-guard · 09845170
      Kostya Serebryany authored
      llvm-svn: 281667
      09845170
    • David L. Jones's avatar
      Simplify Clang's version number configuration in CMake. · 2f754522
      David L. Jones authored
      Currently, the Clang version is computed as follows:
      
       1. LLVM defines major, minor, and patch versions, all statically set. Today,
          these are 4, 0, and 0, respectively.
       2. The static version numbers are combined into PACKAGE_VERSION along with a
          suffix, so the result today looks like "4.0.0svn".
       3. Clang extracts CLANG_VERSION from PACKAGE_VERSION using a regexp. The regexp
          allows the patch level to omitted, and drops any non-digit trailing values.
          Today, this result looks like "4.0.0".
       4. CLANG_VERSION is then split further into CLANG_VERSION_MAJOR and
          CLANG_VERSION_MINOR. Today, these resolve to 4 and 0, respectively.
       5. If CLANG_VERSION matches a regexp with three version components, then
          CLANG_VERSION_PATCHLEVEL is extracted and the CLANG_HAS_VERSION_PATCHLEVEL
          variable is set to 1. Today, these values are 0 and 1, respectively.
       6. The CLANG_VERSION_* variables (and CLANG_HAS_VERSION_PATCHLEVEL) are
          configured into [llvm/tools/clang/]include/clang/Basic/Version.inc
          verbatim by CMake.
       7. In [llvm/tools/clang/]include/clang/Basic/Version.h, macros are defined
          conditionally, based on CLANG_HAS_VERSION_PATCHLEVEL, to compute
          CLANG_VERSION_STRING as either a two- or three-level version number. Today,
          this value is "4.0.0", because despite the patchlevel being 0, it was
          matched by regexp and is thus "HAS"ed by the preprocessor. This string is
          then used wherever Clang's "version" is needed [*].
      
      [*] Including, notably, by compiler-rt, for computing its installation path.
      
      This change collapses steps 2-5 by defaulting Clang to use LLVM's (non-string)
      version components for the Clang version (see [*] for why not PACKAGE_VERSION),
      and collapses steps 6 and 7 by simply writing CLANG_VERSION_STRING into
      Version.inc. The Clang version today always uses the patchlevel form, so the
      collapsed Version.inc does not have logic for a version without a patch level.
      
      Historically speaking, this technique began with the VER file in r82085 (which
      survives in the form of the regexp in #3). The major, minor, and patchlevel
      versions were introduced by r106863 (which remains in #4-6). The VER file itself
      was deleted in favor of the LLVM version number in r106914. On the LLVM side,
      the individual LLVM_VERSION_MAJOR, LLVM_VERSION_MINOR, and PACKAGE_VERSION
      weren't introduced for nearly two more years, until r150405.
      
      llvm-svn: 281666
      2f754522
    • Kostya Serebryany's avatar
      66a9c175
    • Reid Kleckner's avatar
      [codeview] Optimize the size of defranges with gaps · be82d3ec
      Reid Kleckner authored
      For small, discontiguous local variable regions, CodeView can use a
      single defrange record with a gap, rather than having two defrange
      records. I expect that this optimization will only have a minor impact
      on debug info size.
      
      llvm-svn: 281664
      be82d3ec
    • Sanjay Patel's avatar
      [InstCombine] allow icmp (shr/shl) folds for vectors · af91d1f8
      Sanjay Patel authored
      These 2 helper functions were already using APInt internally, so just
      change the API and caller to allow folds for splats. The scalar
      regression tests look quite thorough, so I just added a couple of
      tests to prove that vectors are handled too.
      
      These folds should be grouped with the other cmp+shift folds though.
      That can be an NFC follow-up.
      
      llvm-svn: 281663
      af91d1f8
    • Zachary Turner's avatar
      Allow ArchSpec to take a StringRef. · aa9f1c59
      Zachary Turner authored
      llvm-svn: 281662
      aa9f1c59
    • Zachary Turner's avatar
      [cmake] Don't depend on lldb-server unless it's built. · e13ffee0
      Zachary Turner authored
      llvm-svn: 281661
      e13ffee0
    • Rafael Espindola's avatar
      Error out instead of producing a corrupt PT_LOAD. · 4ec013ac
      Rafael Espindola authored
      What bfd and gold do is give up in putting the headers in the PT_LOAD
      and just start the PT_LOAD in the second page.
      
      llvm-svn: 281660
      4ec013ac
    • Anna Zaks's avatar
      [sanitizer] Fixup: Do not introduce __sanitizer namespace globally · 8cea92b9
      Anna Zaks authored
      Use the namespace in asan_win_dll_thunk.cc to fix the Windows bot.
      
      llvm-svn: 281659
      8cea92b9
    • Anna Zaks's avatar
      [compiler-rt] Remove the system includes from __sanitizer namespace · 8835e907
      Anna Zaks authored
      llvm-svn: 281658
      8835e907
    • Anna Zaks's avatar
      [compiler-rt] Do not introduce __sanitizer namespace globally · 691644f3
      Anna Zaks authored
      The definitions in sanitizer_common may conflict with definitions from system headers because:
      
      The runtime includes the system headers after the project headers (as per LLVM coding guidelines).
      lib/sanitizer_common/sanitizer_internal_defs.h pollutes the namespace of everything defined after it, which is all/most of the sanitizer .h and .cc files and the included system headers with: using namespace __sanitizer; // NOLINT
      This patch solves the problem by introducing the namespace only within the sanitizer namespaces as proposed by Dmitry.
      
      Differential Revision: https://reviews.llvm.org/D21947
      
      llvm-svn: 281657
      691644f3
    • Anna Zaks's avatar
      [sanitizers] DLAddr Symbolizer should fail if demangle fails · 592bc455
      Anna Zaks authored
      This can case crashes in high verbosity mode when demangling fails.
      Not including a test case since this is hard to reproduce.
      
      llvm-svn: 281656
      592bc455
    • Sanjay Patel's avatar
      regenerate checks · d590db6e
      Sanjay Patel authored
      llvm-svn: 281655
      d590db6e
    • Jason Henline's avatar
      [SE] Fix config bug with CUDA tests · 9fc16d4e
      Jason Henline authored
      Summary:
      It turns out CMake errors out if a processed directory contains source
      files that are not used. This was causing an error with the CUDATest.cpp
      file when configuring StreamExecutor with the CUDA platform disabled.
      
      Moving CUDATest.cpp to its own directory fixes this problem.
      
      Reviewers: jlebar, jprice
      
      Subscribers: beanz, mgorny, jlebar, parallel_libs-commits
      
      Differential Revision: https://reviews.llvm.org/D24618
      
      llvm-svn: 281654
      9fc16d4e
    • Mehdi Amini's avatar
      [GlobalOpt] Dead Eliminate declarations · d8803098
      Mehdi Amini authored
      GlobalOpt is already dead-code-eliminating global definitions. With
      this change it also takes care of declarations.
      Hopefully this should make it now a strict superset of GlobalDCE.
      This is important for LTO/ThinLTO as we don't want the linker to see
      "undefined reference" when it processes the input files: it could
      prevent proper internalization (or even load an extra file from a
      static archive, changing the behavior of the program!).
      
      llvm-svn: 281653
      d8803098
    • Chris Bieneman's avatar
      Fixing bot failures · 3045d703
      Chris Bieneman authored
      Need to only add debugserver as a test dependency on Darwin.
      
      llvm-svn: 281652
      3045d703
    • Chris Bieneman's avatar
      [LIT] First pass of LLDB LIT support · 4851558f
      Chris Bieneman authored
      Summary:
      This patch supplies basic infrastructure for LLDB to use LIT, and ports a few basic test cases from the LLDB test suite into LIT.
      
      With this patch the LLDB lit system is not capable or intended to fully replace the existing LLDB test suite, but this first patch enables people to write lit tests for LLDB.
      
      The lit substitution for %cc and %cxx default to the host compiler unless the CMake option LLDB_TEST_CLANG is On, in which case the in-tree clang will be used.
      
      The target check-lldb-lit will run all lit tests including the lit-based executor for the unit tests. Alternatively there is a target generated for each subdirectory under the lit directory, so check-lldb-unit and check-lldb-expr will run just the tests under their respective directories.
      
      The ported tests are not removed from the existing suite, and should not be until such a time when the lit runner is mature and in use by bots and workflows.
      
      Reviewers: zturner, labath, jingham, tfiala
      
      Subscribers: beanz, mgorny, lldb-commits
      
      Differential Revision: https://reviews.llvm.org/D24591
      
      llvm-svn: 281651
      4851558f
    • David Majnemer's avatar
      [InstCombine] Do not RAUW a constant GEP · 8b16da87
      David Majnemer authored
      canRewriteGEPAsOffset expects to process instructions, not constants.
      
      This fixes PR30342.
      
      llvm-svn: 281650
      8b16da87
    • Evandro Menezes's avatar
      [AArch64] Support for FP FMA when -ffp-contract=fast · 19b2aed3
      Evandro Menezes authored
      Currently, the machine combiner can proceed matching when -ffast-math is on.
      It should also match when only -ffp-contract=fast is specified as was the
      case before when DAGCombiner was doing the job.
      
      Patch by: Abderrazek Zaafrani <a.zaafrani@samsung.com>.
      
      Differential Revision: https://reviews.llvm.org/D24366
      
      llvm-svn: 281649
      19b2aed3
    • Hans Wennborg's avatar
      clang-format VS plugin: upgrade the project files to VS2015 · 252f9bf7
      Hans Wennborg authored
      The plugin itself runs on previous VS versions, but this enables
      it to be built with VS2015.
      
      llvm-svn: 281648
      252f9bf7
    • Rafael Espindola's avatar
      Make sure we create all necessary PT_LOADs. · 1d98d629
      Rafael Espindola authored
      We were some times stopping early when using linker scripts.
      
      llvm-svn: 281647
      1d98d629
    • George Rimar's avatar
      [ELF] - Linkerscript: implemented SORT_BY_INIT_PRIORITY. · 575208ca
      George Rimar authored
      This is PR30386,
      
      SORT_BY_INIT_PRIORITY is a keyword can be used to sort sections by numerical value of the
      GCC init_priority attribute encoded in the section name.
      
      Differential revision: https://reviews.llvm.org/D24611
      
      llvm-svn: 281646
      575208ca
    • Evgeniy Stepanov's avatar
      Revert "[ARM] Promote small global constants to constant pools" · a0601a40
      Evgeniy Stepanov authored
      This reverts r281604, which adds text relocations to ARM binaries.
      
      llvm-svn: 281645
      a0601a40
    • Sanjay Patel's avatar
      [InstCombine] simplify code; NFCI · 524fcdf0
      Sanjay Patel authored
      llvm-svn: 281644
      524fcdf0
    • Rui Ueyama's avatar
      Use SuperBlock struct defined in MSFCommon.h. · 7f382999
      Rui Ueyama authored
      llvm-svn: 281643
      7f382999