1. Oct 30, 2015
    • Jim Ingham's avatar
      72b5f9bb
    • Dehao Chen's avatar
      clang-format lib/Transforms/Utils/AddDiscriminators.cpp · 7ddf7865
      Dehao Chen authored
      llvm-svn: 251656
      7ddf7865
    • Teresa Johnson's avatar
      Fix test check label. · bc11ede2
      Teresa Johnson authored
      Summary:
      I noticed when manually modifying this test that it was passing when I
      expected it to fail. Looks like the combination of LABEL and NOT on the
      check does not work. This can also be seen when running FileCheck with
      only that one -check-prefix (removing the additional -check-prefix=B):
      
      /usr/local/google/home/tejohnson/llvm/llvm_11_build/./bin/llvm-link -S -internalize -only-needed /usr/local/google/home/tejohnson/llvm/llvm_11_build/test/Linker/Output/link-flags.ll.tmp.b.bc /usr/local/google/home/tejohnson/llvm/llvm_11_build/test/Linker/Output/link-flags.ll.tmp.c.bc | /usr/local/google/home/tejohnson/llvm/llvm_11_build/./bin/FileCheck /usr/local/google/home/tejohnson/llvm/llvm_11/test/Linker/link-flags.ll -check-prefix=CN
      error: no check strings found with prefix 'CN:'
      
      The CN prefix checks don't in fact need "LABEL" so remove that.
      
      Reviewers: tra
      
      Subscribers: llvm-commits
      
      Differential Revision: http://reviews.llvm.org/D14173
      
      llvm-svn: 251655
      bc11ede2
    • Jonathan Peyton's avatar
      [OMPT] Windows Support for OMPT · 69e596a5
      Jonathan Peyton authored
      The problem is that the ompt_tool() function (which must be implemented by a
      performance tool) should be defined in the RTL as well to cover the case when
      the tool is not present in the address space of the process. This functionality
      is accomplished with weak symbols in Unices. Unfortunately, Windows does not
      support weak symbols.
      
      The solution in these changes is to grab the list of all modules loaded by the
      process and then search for symbol "ompt_tool()" within them. The function
      ompt_tool_windows() performs the search of the ompt_tool symbol. If ompt_tool is
      found, then its return value is used to initialize the tool. If ompt_tool is not
      found, then ompt_tool_windows() returns NULL and OMPT is thus, disabled.
      
      While doing these changes, the OMPT_SUPPORT detection in CMake was changed to
      test for the required featuers for OMPT_SUPPORT, namely: builtin_frame_address()
      existence, weak attribute existence and psapi.dll existence. For
      LIBOMP_HAVE_OMPT_SUPPORT to be true, it must be that the builtin_frame_address()
      intrinsic exists AND one of: either weak attributes exist or psapi.dll exists.
      
      Also, since Process Status API is used I had to add new dependency -- psapi.dll
      to the library dependency micro test.
      
      Differential Revision: http://reviews.llvm.org/D14027
      
      llvm-svn: 251654
      69e596a5
    • Nico Weber's avatar
      Mark InternalDebugOpt driver options as CoreOptions. · e8df6750
      Nico Weber authored
      Mostly has the effect of making -ccc-print-phases usable from clang-cl.
      
      llvm-svn: 251653
      e8df6750
    • Weiming Zhao's avatar
      [ARM] Remove XFAIL on test/CodeGen/Generic/MachineBranchProb.ll · b00cc621
      Weiming Zhao authored
      Summary: Refer PR23377. This test was XFAIL'ed for Hexagon as well as ARM. But it has now started passing for ARM.
      
      Reviewers: hans, rengolin, aemerson, kparzysz
      
      Subscribers: aemerson, llvm-commits, rengolin
      
      Differential Revision: http://reviews.llvm.org/D14155
      
      llvm-svn: 251652
      b00cc621
    • John McCall's avatar
      Add support for __builtin_{add,sub,mul}_overflow. · 03107a4e
      John McCall authored
      Patch by David Grayson!
      
      llvm-svn: 251651
      03107a4e
    • Nico Weber's avatar
      Suppress uninteresting output from crash-recovery-modules.m · b2542352
      Nico Weber authored
      No behavior change, but it makes this test a bit easier to debug when it fails.
      
      llvm-svn: 251650
      b2542352
    • Saleem Abdulrasool's avatar
      Sanitizer: define WIN32_LEAN_AND_MEAN · d006c936
      Saleem Abdulrasool authored
      Define WIN32_LEAN_AND_MEAN before including Windows.h.  This is already being
      done in some places.  This does it more broadly.  This permits building ASAN on
      Linux for Winndows, as well as reduces the amount of included declarations.
      
      llvm-svn: 251649
      d006c936
    • Eugene Zelenko's avatar
      Fix Clang-tidy modernize-use-nullptr warnings in remaining files in... · 406d446e
      Eugene Zelenko authored
      Fix Clang-tidy modernize-use-nullptr warnings in remaining files in include/lldb/Target; other minor fixes.
      
      llvm-svn: 251648
      406d446e
    • Eugene Zelenko's avatar
      Fix Clang-tidy modernize-use-nullptr warnings in some files in... · cf5f0ee2
      Eugene Zelenko authored
      Fix Clang-tidy modernize-use-nullptr warnings in some files in include/lldb/Target; other minor fixes.
      
      llvm-svn: 251647
      cf5f0ee2
    • Davide Italiano's avatar
      9b71ef92
    • Davide Italiano's avatar
      3300b798
    • George Rimar's avatar
      [ELF2] merge-string.s test fixed for win32 configuration. · 8b8222b0
      George Rimar authored
      Differential revision: http://reviews.llvm.org/D14171
      
      llvm-svn: 251644
      8b8222b0
    • Daniel Jasper's avatar
      clang-format: [JS] Add goog.setTestOnly to the list of stuff that · b488a74f
      Daniel Jasper authored
      is import-statement-like and shouldn't be wrapped.
      
      llvm-svn: 251643
      b488a74f
    • Enrico Granata's avatar
    • Lang Hames's avatar
      [Orc] Rename IndirectStubsManagerBase method 'init' to 'createStubs'. · deadf2a4
      Lang Hames authored
      llvm-svn: 251641
      deadf2a4
    • Chandler Carruth's avatar
      [FunctionAttrs] Provide a single SCC node set to all of the · c518ebdd
      Chandler Carruth authored
      transformations in FunctionAttrs rather than building a new one each
      time.
      
      This isn't trivial because there are different heuristics from different
      passes for exactly what set they want. The primary difference is whether
      an *overridable* function completely disables the synthesis of
      attributes. I've modeled this by directly testing for overridable, and
      using the common set that excludes external and opt-none functions.
      
      This does cause some changes by disabling more optimizations in the face
      of opt-none. Specifically, we were still optimizing *calls* to opt-none
      functions based on their attributes, just not the bodies. It seems
      better to be conservative on both fronts given the intended semanticas
      here (best effort to not assume or disturb anything). I've not tried to
      test this change as it seems complex, brittle, and not important to the
      implicit contract of opt-none. Instead, it seems more like a choice that
      should be dictated by the simplified implementation and the change to be
      acceptable differences within the space of opt-none.
      
      A big benefit here is that these transformations no longer rely on the
      legacy pass manager's SCC types, they just work on generic sets of
      function pointers. This will make it easy to re-use their logic in the
      new pass manager.
      
      I've also made the transforms static functions instead of members where
      trivial while I was touching the signatures.
      
      llvm-svn: 251640
      c518ebdd
    • Sylvestre Ledru's avatar
      add support of the latest Ubuntu (Xenial Xerus) · 43b95717
      Sylvestre Ledru authored
      llvm-svn: 251639
      43b95717
    • Ehsan Akhgari's avatar
      Add a link to the DXR project · f16435d8
      Ehsan Akhgari authored
      DXR is a project developed at Mozilla that implements a code indexing
      and browsing utility on top of libclang that has features such as
      call graph querying.
      
      llvm-svn: 251638
      f16435d8
    • Lang Hames's avatar
      2ed3bf95
    • Hafiz Abid Qadeer's avatar
      Better handle the arguments common to all MI commands. · d122fd8d
      Hafiz Abid Qadeer authored
      Summary:
      I observed that eclipse was passing --thread-group for many other commands
      then we are currently handling. Looking at the MI documentation, the
      following link states that each MI command accept the --thread and
      --frame option. Looking at the GDB implementation, it seems that apart
      from these 2, --thread-group is also handled the same way.
      
      https://sourceware.org/gdb/onlinedocs/gdb/Context-management.html#Context-management
      
      So instead of handling those arguments in every comamnds, I have moved
      them into the base class and removed them from elsewhere. Now any command
      can use these arguments. The patch seems big but most of the changes are
      mechanical.
      
      Reviewers: ki.stfu
      
      Subscribers: lldb-commits
      
      Differential Revision: http://reviews.llvm.org/D14177
      
      llvm-svn: 251636
      d122fd8d
    • Diego Novillo's avatar
      Revert r251593. · 083becab
      Diego Novillo authored
      The patch in r251593 was only papering over the problem. The actual fix
      was committed in r251623.
      
      llvm-svn: 251635
      083becab
    • Jonas Paulsson's avatar
      [SystemZ] Make the CCRegs regclass non-allocatable. · 45d5c673
      Jonas Paulsson authored
      This was discovered to be necessary while running memchr-01.ll with
      -verify-machinstrs, because it is not allowed to have a phys reg live
      accross block boundaries while on SSA form, if the register is
      allocatable (expect in entry block and landing pads).
      
      In this test case, stringRRE pseudos are expanded after isel by adding
      a loop block which produces a live out CC register. To make the test
      pass, it was also necessary to not say that StringRRELoop pseudo uses
      R0L, this is only true for the StringRRE opcode.
      
      -verify-machineinstrs added to memchr-01.ll test.
      
      New test case int-cmp-51.ll to test that MachineCSE can eliminate
      an identical compare (which it couldn't do before).
      
      Reviewed by Ulrich Weigand
      
      llvm-svn: 251634
      45d5c673
  2. Oct 29, 2015
    • Vasileios Kalintiris's avatar
      [mips] Add support for the new mips-mti-linux toolchain. · 45faf47e
      Vasileios Kalintiris authored
      The original commit in r249137 added the mips-mti-linux toolchain. However,
      the newly added tests of that commit failed in few buildbots. This commit
      re-applies the original changes but XFAILs the test file which caused
      the buildbot failures. This will allow us to examine what's going wrong
      without having to commit/revert large changes.
      
      llvm-svn: 251633
      45faf47e
    • Marek Olsak's avatar
      AMDGPU/SI: handle undef for llvm.SI.packf16 · 6f6d318e
      Marek Olsak authored
      llvm-svn: 251632
      6f6d318e
    • Marek Olsak's avatar
      AMDGPU/SI: use S_OR for fneg (fabs f32) · 74d084f4
      Marek Olsak authored
      llvm-svn: 251631
      74d084f4
    • Marek Olsak's avatar
      AMDGPU/SI: use S_AND for i1 trunc · f924dd6f
      Marek Olsak authored
      llvm-svn: 251630
      f924dd6f
    • Zoran Jovanovic's avatar
      [mips] wrong opcode for ll/sc instructions on mipsr6 when -integrated-as is used · 796ed6d9
      Zoran Jovanovic authored
      Summary:
      This commit resolves wrong opcodes for ll and sc instructions for r6 architecutres, which were generated in method MipsTargetLowering::emitAtomicBinary.
      
      Author: Jelena.Losic
      
      Reviewers: dsanders
      
      Subscribers: dsanders, llvm-commits
      
      Differential Revision: http://reviews.llvm.org/D13593
      
      llvm-svn: 251629
      796ed6d9
    • Pavel Labath's avatar
      Fixup lldb-argdumper cmake build · 6e813bbf
      Pavel Labath authored
      forgot to rename in one spot.
      
      llvm-svn: 251628
      6e813bbf
    • Artyom Skrobov's avatar
      Recognize that ARM1176JZ[F]-S support TrustZone · 0ff1ce40
      Artyom Skrobov authored
      Summary:
      ARMv6KZ cores were set up incorrectly in ARM.td; also, the SMI mnemonic
      (the old name for SMC, as defined in ARMv6KZ) wasn't supported.
      
      Reviewers: jmolloy, rengolin
      
      Subscribers: aemerson, rengolin, llvm-commits
      
      Differential Revision: http://reviews.llvm.org/D14154
      
      llvm-svn: 251627
      0ff1ce40
    • Pavel Labath's avatar
      Fix flakyness in TestChangeProcessGroup · 7d557910
      Pavel Labath authored
      The test was verifying that the pid of the child is not equal to its process
      group by searching for text substrings. This failed in the rare cases when the
      pid actually *was* a substring of the process group (even though they were not
      equal).
      
      Change the test to use SB API and do proper numeric comparisons.
      
      llvm-svn: 251626
      7d557910
    • Adhemerval Zanella's avatar
      [compiler-rt] [msan] Unify aarch64 mapping · 689724e5
      Adhemerval Zanella authored
      This patch unify the 39-bit and 42-bit mapping for aarch64 to use only
      one instrumentation algorithm.  A runtime check avoid mapping 42-bit 
      only segments for 39-bit kernels.
      
      The mapping to use now is for 39 and 42-bits:
      
          0x00000000000ULL-0x01000000000ULL  MappingDesc::INVALID
          0x01000000000ULL-0x02000000000ULL  MappingDesc::SHADOW
          0x02000000000ULL-0x03000000000ULL  MappingDesc::ORIGIN
          0x03000000000ULL-0x04000000000ULL  MappingDesc::SHADOW
          0x04000000000ULL-0x05000000000ULL  MappingDesc::ORIGIN
          0x05000000000ULL-0x06000000000ULL  MappingDesc::APP
          0x06000000000ULL-0x07000000000ULL  MappingDesc::INVALID
          0x07000000000ULL-0x08000000000ULL  MappingDesc::APP
      
      And only for 42-bits:
      
          0x08000000000ULL-0x09000000000ULL  MappingDesc::INVALID
          0x09000000000ULL-0x0A000000000ULL  MappingDesc::SHADOW
          0x0A000000000ULL-0x0B000000000ULL  MappingDesc::ORIGIN
          0x0B000000000ULL-0x0F000000000ULL  MappingDesc::INVALID
          0x0F000000000ULL-0x10000000000ULL  MappingDesc::APP
          0x10000000000ULL-0x11000000000ULL  MappingDesc::INVALID
          0x11000000000ULL-0x12000000000ULL  MappingDesc::APP
          0x12000000000ULL-0x17000000000ULL  MappingDesc::INVALID
          0x17000000000ULL-0x18000000000ULL  MappingDesc::SHADOW
          0x18000000000ULL-0x19000000000ULL  MappingDesc::ORIGIN
          0x19000000000ULL-0x20000000000ULL  MappingDesc::INVALID
          0x20000000000ULL-0x21000000000ULL  MappingDesc::APP
          0x21000000000ULL-0x26000000000ULL  MappingDesc::INVALID
          0x26000000000ULL-0x27000000000ULL  MappingDesc::SHADOW
          0x27000000000ULL-0x28000000000ULL  MappingDesc::ORIGIN
          0x28000000000ULL-0x29000000000ULL  MappingDesc::SHADOW
          0x29000000000ULL-0x2A000000000ULL  MappingDesc::ORIGIN
          0x2A000000000ULL-0x2B000000000ULL  MappingDesc::APP
          0x2B000000000ULL-0x2C000000000ULL  MappingDesc::INVALID
          0x2C000000000ULL-0x2D000000000ULL  MappingDesc::SHADOW
          0x2D000000000ULL-0x2E000000000ULL  MappingDesc::ORIGIN
          0x2E000000000ULL-0x2F000000000ULL  MappingDesc::APP
          0x2F000000000ULL-0x39000000000ULL  MappingDesc::INVALID
          0x39000000000ULL-0x3A000000000ULL  MappingDesc::SHADOW
          0x3A000000000ULL-0x3B000000000ULL  MappingDesc::ORIGIN
          0x3B000000000ULL-0x3C000000000ULL  MappingDesc::APP
          0x3C000000000ULL-0x3D000000000ULL  MappingDesc::INVALID
          0x3D000000000ULL-0x3E000000000ULL  MappingDesc::SHADOW
          0x3E000000000ULL-0x3F000000000ULL  MappingDesc::ORIGIN
          0x3F000000000ULL-0x40000000000ULL  MappingDesc::APP
      
      And although complex it provides a better memory utilization that
      previous one.
      
      [1] http://reviews.llvm.org/D13817
      
      llvm-svn: 251625
      689724e5
    • Adhemerval Zanella's avatar
      [sanitizer] [msan] Unify aarch64 mapping · 1edb0849
      Adhemerval Zanella authored
      This patch unify the 39-bit and 42-bit mapping for aarch64 to use only
      one instrumentation algorithm.  This removes compiler flag 
      SANITIZER_AARCH64_VMA requirement for MSAN on aarch64.
      
      The mapping to use now is for 39 and 42-bits:
      
          0x00000000000ULL-0x01000000000ULL  MappingDesc::INVALID
          0x01000000000ULL-0x02000000000ULL  MappingDesc::SHADOW
          0x02000000000ULL-0x03000000000ULL  MappingDesc::ORIGIN
          0x03000000000ULL-0x04000000000ULL  MappingDesc::SHADOW
          0x04000000000ULL-0x05000000000ULL  MappingDesc::ORIGIN
          0x05000000000ULL-0x06000000000ULL  MappingDesc::APP
          0x06000000000ULL-0x07000000000ULL  MappingDesc::INVALID
          0x07000000000ULL-0x08000000000ULL  MappingDesc::APP
      
      And only for 42-bits:
      
          0x08000000000ULL-0x09000000000ULL  MappingDesc::INVALID
          0x09000000000ULL-0x0A000000000ULL  MappingDesc::SHADOW
          0x0A000000000ULL-0x0B000000000ULL  MappingDesc::ORIGIN
          0x0B000000000ULL-0x0F000000000ULL  MappingDesc::INVALID
          0x0F000000000ULL-0x10000000000ULL  MappingDesc::APP
          0x10000000000ULL-0x11000000000ULL  MappingDesc::INVALID
          0x11000000000ULL-0x12000000000ULL  MappingDesc::APP
          0x12000000000ULL-0x17000000000ULL  MappingDesc::INVALID
          0x17000000000ULL-0x18000000000ULL  MappingDesc::SHADOW
          0x18000000000ULL-0x19000000000ULL  MappingDesc::ORIGIN
          0x19000000000ULL-0x20000000000ULL  MappingDesc::INVALID
          0x20000000000ULL-0x21000000000ULL  MappingDesc::APP
          0x21000000000ULL-0x26000000000ULL  MappingDesc::INVALID
          0x26000000000ULL-0x27000000000ULL  MappingDesc::SHADOW
          0x27000000000ULL-0x28000000000ULL  MappingDesc::ORIGIN
          0x28000000000ULL-0x29000000000ULL  MappingDesc::SHADOW
          0x29000000000ULL-0x2A000000000ULL  MappingDesc::ORIGIN
          0x2A000000000ULL-0x2B000000000ULL  MappingDesc::APP
          0x2B000000000ULL-0x2C000000000ULL  MappingDesc::INVALID
          0x2C000000000ULL-0x2D000000000ULL  MappingDesc::SHADOW
          0x2D000000000ULL-0x2E000000000ULL  MappingDesc::ORIGIN
          0x2E000000000ULL-0x2F000000000ULL  MappingDesc::APP
          0x2F000000000ULL-0x39000000000ULL  MappingDesc::INVALID
          0x39000000000ULL-0x3A000000000ULL  MappingDesc::SHADOW
          0x3A000000000ULL-0x3B000000000ULL  MappingDesc::ORIGIN
          0x3B000000000ULL-0x3C000000000ULL  MappingDesc::APP
          0x3C000000000ULL-0x3D000000000ULL  MappingDesc::INVALID
          0x3D000000000ULL-0x3E000000000ULL  MappingDesc::SHADOW
          0x3E000000000ULL-0x3F000000000ULL  MappingDesc::ORIGIN
          0x3F000000000ULL-0x40000000000ULL  MappingDesc::APP
      
      And although complex it provides a better memory utilization that
      previous one.
      
      llvm-svn: 251624
      1edb0849
    • Daniel Jasper's avatar
      Fix use-after-free. Thanks ASAN for giving me a detailed report :-). · 1de905a6
      Daniel Jasper authored
      llvm-svn: 251623
      1de905a6
    • Vasileios Kalintiris's avatar
      [mips] Check the register class before replacing materializations of zero with $zero in microMIPS. · 2f412684
      Vasileios Kalintiris authored
      Summary:
      The microMIPS register class GPRMM16 does not contain the $zero register.
      However, MipsSEDAGToDAGISel::replaceUsesWithZeroReg() would replace uses
      of the $dst register:
      
        [d]addiu, $dst, $zero, 0
      
      with the $zero register, without checking for membership in the register
      class of the target machine operand.
      
      Reviewers: dsanders
      
      Subscribers: llvm-commits, dsanders
      
      Differential Revision: http://reviews.llvm.org/D13984
      
      llvm-svn: 251622
      2f412684
    • Sean Eveson's avatar
      [Analyzer] Widening loops which do not exit · 83390e45
      Sean Eveson authored
      Summary:
      Dear All,
      
      We have been looking at the following problem, where any code after the constant bound loop is not analyzed because of the limit on how many times the same block is visited, as described in bugzillas #7638 and #23438. This problem is of interest to us because we have identified significant bugs that the checkers are not locating. We have been discussing a solution involving ranges as a longer term project, but I would like to propose a patch to improve the current implementation.
      
      Example issue:
      ```
      for (int i = 0; i < 1000; ++i) {...something...}
      int *p = 0;
      *p = 0xDEADBEEF;
      ```
      
      The proposal is to go through the first and last iterations of the loop. The patch creates an exploded node for the approximate last iteration of constant bound loops, before the max loop limit / block visit limit is reached. It does this by identifying the variable in the loop condition and finding the value which is “one away” from the loop being false. For example, if the condition is (x < 10), then an exploded node is created where the value of x is 9. Evaluating the loop body with x = 9 will then result in the analysis continuing after the loop, providing x is incremented.
      
      The patch passes all the tests, with some modifications to coverage.c, in order to make the ‘function_which_gives_up’ continue to give up, since the changes allowed the analysis to progress past the loop.
      
      This patch does introduce possible false positives, as a result of not knowing the state of variables which might be modified in the loop. I believe that, as a user, I would rather have false positives after loops than do no analysis at all. I understand this may not be the common opinion and am interested in hearing your views. There are also issues regarding break statements, which are not considered. A more advanced implementation of this approach might be able to consider other conditions in the loop, which would allow paths leading to breaks to be analyzed.
      
      Lastly, I have performed a study on large code bases and I think there is little benefit in having “max-loop” default to 4 with the patch. For variable bound loops this tends to result in duplicated analysis after the loop, and it makes little difference to any constant bound loop which will do more than a few iterations. It might be beneficial to lower the default to 2, especially for the shallow analysis setting.
      
      Please let me know your opinions on this approach to processing constant bound loops and the patch itself.
      
      Regards,
      
      Sean Eveson
      SN Systems - Sony Computer Entertainment Group
      
      Reviewers: jordan_rose, krememek, xazax.hun, zaks.anna, dcoughlin
      
      Subscribers: krememek, xazax.hun, cfe-commits
      
      Differential Revision: http://reviews.llvm.org/D12358
      
      llvm-svn: 251621
      83390e45
    • Jonas Paulsson's avatar
      [MachineVerifier] Analyze MachineMemOperands for mem-to-mem moves. · 72640f1c
      Jonas Paulsson authored
      Since the verifier will give false reports if it incorrectly thinks MI is
      loading or storing using an FI, it is necessary to scan memoperands and
      find out how the FI is used in the instruction. This should be relatively
      rare.
      
      Needed to make CodeGen/SystemZ/spill-01.ll pass, which now runs with this flag.
      
      Reviewed by Quentin Colombet.
      
      llvm-svn: 251620
      72640f1c
    • NAKAMURA Takumi's avatar
      OrcJITTests: Update libdeps corresponding to r251604. · 3a063db2
      NAKAMURA Takumi authored
      llvm-svn: 251619
      3a063db2
    • Marshall Clow's avatar
      Implement P0004R1 'Remove Deprecated iostreams aliases' · 131733bc
      Marshall Clow authored
      llvm-svn: 251618
      131733bc