- Sep 26, 2015
-
-
Michael Kruse authored
There are three possible reasons to add a memory memory access: For explicit load and stores, for llvm::Value defs/uses, and to emulate PHI nodes (the latter two called implicit accesses). Previously MemoryAccess only stored IsPHI. Register accesses could be identified through the isScalar() method if it was no IsPHI. isScalar() determined the number of dimensions of the underlaying array, scalars represented by zero dimensions. For the work on de-LICM, implicit accesses can have more than zero dimensions, making the distinction of isScalars() useless, hence now stored explicitly in the MemoryAccess. Instead, we replace it by isImplicit() and avoid the term scalar for zero-dimensional arrays as it might be confused with llvm::Value which are also often referred to as scalars (or alternatively, as registers). No behavioral change intended, under the condition that it was impossible to create explicit accesses to zero-dimensional "arrays". llvm-svn: 248616
-
Rafael Espindola authored
Thanks to Rui for the suggestion. llvm-svn: 248615
-
Sanjoy Das authored
r248606: "[SCEV] Exploit A < B => (A+K) < (B+K) when possible" r248608: "[SCEV] Teach isLoopBackedgeGuardedByCond to exploit trip counts." llvm-svn: 248614
-
Justin Bogner authored
llvm-svn: 248613
-
Sean Callanan authored
There are still a bunch of dependencies on the plug-in, but this helps to identify them. There are also a few more bits we need to move (and abstract, for example the ClangPersistentVariables). llvm-svn: 248612
-
Matt Arsenault authored
If a virtual register is copied and another copy was already seen, replace with the previous copy. This only handles the simplest cases for now. This pattern shows up from various operand restrictions AMDGPU has which require inserting copies depending on the register class of the operands. llvm-svn: 248611
-
Chad Rosier authored
llvm-svn: 248610
-
Sanjay Patel authored
llvm-svn: 248609
-
Sanjoy Das authored
Summary: If the trip count of a specific backedge is `N`, then we know that backedge is effectively guarded by the condition `{0,+,1} u< N`. This change teaches SCEV to use this condition to prove things in `isLoopBackedgeGuardedByCond`. Depends on D12948 Depends on D12949 Reviewers: atrick, reames, majnemer, hfinkel Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D12950 llvm-svn: 248608 -
Sanjoy Das authored
Summary: This new helper routine will be used in a subsequent change. Reviewers: hfinkel Subscribers: hfinkel, sanjoy, llvm-commits Differential Revision: http://reviews.llvm.org/D12949 llvm-svn: 248607
-
Sanjoy Das authored
Summary: This change teaches SCEV's `isImpliedCond` two new identities: A u< B u< -C => (A + C) u< (B + C) A s< B s< INT_MIN - C => (A + C) s< (B + C) While these are useful on their own, they're really intended to support D12950. Reviewers: atrick, reames, majnemer, nlewycky, hfinkel Subscribers: aadg, sanjoy, llvm-commits Differential Revision: http://reviews.llvm.org/D12948 llvm-svn: 248606
-
Rafael Espindola authored
Patch by George Rimar! llvm-svn: 248605
-
Rafael Espindola authored
llvm-svn: 248604
-
Michael Kruse authored
This makes the intent of each created object clearer and allows to add more specific asserts. The bug fixed in r248535 has been discovered this way. No functional change intended; everything should behave as before. llvm-svn: 248603
-
Rafael Espindola authored
Thanks to David Blaikie for noticing. llvm-svn: 248602
-
Dawn Perchik authored
llvm-svn: 248601
-
Matt Arsenault authored
llvm-svn: 248600
-
Rafael Espindola authored
llvm-svn: 248599
-
Matt Arsenault authored
This matches how it is defined in the generated implementation. llvm-svn: 248598
-
Dawn Perchik authored
Fix assignment operator in CMIUtilString to not crash the debugger if it is passed a NULL pointer, which can happen in code like the following: SBValue val; CMIUtilString s; //... s = val.GetSummary(); Patch from evgeny.leviant@gmail.com Reviewed by: clayborg, ki.stfu Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D13094 llvm-svn: 248597 -
Manuel Klimek authored
Patch by Sergey Kalinichev. llvm-svn: 248596
-
George Burgess IV authored
This patch fixes the order in which we evaluate the different ways that a function call could be disallowed. Now, if you call a non-overloaded function with an incomplete type and failing enable_if, we'll prioritize reporting the more obvious error (use of incomplete type) over reporting the failing enable_if. Thanks to Ettore Speziale for the patch! llvm-svn: 248595
-
Alexander Kornienko authored
llvm-svn: 248594
-
Chad Rosier authored
llvm-svn: 248593
-
Eric Christopher authored
logic to select an alternate target based on the executable it was called as. For instance, if you symlink i686-linux-android-gcc to clang and invoke it, the driver will act as though it were called with another argument ("-target i686-linux-android"). This leads to visible effects even in syntax-only compilations (like the ANDROID preprocessor symbol being defined). This behavior is not replicated for tool invocations--for instance, clang::createInvocationFromCommandLine will not choose an alternate target based on ArgList[0]. This means that configurations stored in compilation databases aren't accurately replayed. This patch separates the logic for selecting a mode flag and target from the executable name into a new member function on ToolChain. It should have no functional effects (but will allow other code to reuse the target/mode selection logic). Patch by Luke Zarko! llvm-svn: 248592 -
Matt Arsenault authored
Don't run passes related to stack maps, garbage collection, exceptions since these aren't useful for GPUs. There might be a few more to turn off that I'm less sure about (e.g. ShrinkWrapping) or I'm not sure how to disable (SafeStack and StackProtector) llvm-svn: 248591
-
Rafael Espindola authored
llvm-svn: 248590
-
Matt Arsenault authored
This fixes a select error when the i64 source was also bitcasted to v2i32 in the original source. Instead of awkwardly trying to select the modified source value and the store, replace before isel begins. Uses a worklist to avoid possible problems from mutating the DAG, although it seems to work OK without it. llvm-svn: 248589
-
Jonathan Peyton authored
This patch adjusts the buffer size when reducing the buffer used for printing. This solves the memory corruption in Windows debug library, and potential memory corruption in other builds. llvm-svn: 248588
-
Matt Arsenault authored
SIFixSGPRCopies does not modify the CFG, but this was being recomputed before running SIFoldOperands. llvm-svn: 248587
-
Rafael Espindola authored
llvm-svn: 248586
-
Matt Arsenault authored
When buffer resource descriptors were built, the upper two components of the descriptor were first composed into a 64-bit register because legalizeOperands assumed all operands had the same register class. Fix that problem, but keep the workaround. I'm not sure anything actually is actually emitting such a REG_SEQUENCE now. If multiple resource descriptors are set up with different base pointers, this is copied with a single s_mov_b64. We probably should fix this better by recognizing a pair of s_mov_b32 later, but for now delete the dead code. llvm-svn: 248585
-
Matt Arsenault authored
This avoids needting to re-legalize the new REG_SEQUENCE. llvm-svn: 248584
-
Matt Arsenault authored
This was only set on the final _si/_vi version, but not on the pseudos most of codegen sees. No test since these instructions aren't used yet. llvm-svn: 248583
-
Matt Arsenault authored
These were all using the default 32-bit VALU write class, but the i64/f64 compares are half rate. I'm not sure this is really correct, because they are still using the write to VALU write class, even though they really write to the SALU. llvm-svn: 248582
-
Rui Ueyama authored
There's actually a room to improve this patch. Instead of not merging sections that have different alignements, we can choose the section that has the largest alignment requirement among all sections that are otherwise considered the same. Then all section alignments are satisfied, so we can merge them. I don't know if that improvement could make any difference for real-world input, so I'll leave it alone. Would be interesting to revisit later. llvm-svn: 248581
-
Rui Ueyama authored
This is intended to be 64-bit integer, but size_t is not guranteed to be the same or larger type than uint64_t. llvm-svn: 248580
-
Rui Ueyama authored
This pointer points to a replacement for this chunk. Ptr was not a good name. llvm-svn: 248579
-
Greg Bedwell authored
Revert "This patch adds missing pieces to clang, including the PS4 toolchain definition, added warnings, PS4 defaults, and Driver changes needed for our compiler." This reverts commit r248546 to get our bot green again while we discuss the best way forward. llvm-svn: 248578
-
Ed Maste authored
These tests used to hang on the old FreeBSD buildbot, which has been retired. They do not hang when run locally, but do fail. llvm.org/pr24939 llvm-svn: 248577
-