- Apr 22, 2015
-
-
Duncan P. N. Exon Smith authored
Factor the loop for linking input files together into a combined module into a separate function. This is in preparation for an upcoming patch that runs the logic twice. Patch by Luqman Aden! llvm-svn: 235472
-
Hans Wennborg authored
For example, a function taking a parameter with internal linkage will itself have internal linkage since it cannot be called outside the translation unit. Differential Revision: http://reviews.llvm.org/D9182 llvm-svn: 235471
-
Nico Weber authored
llvm-svn: 235470
-
Craig Topper authored
Revert "[TableGen] Use cast instead of dyn_cast where result isn't checked before being dereferenced." Turns out I misread the parentheses. Though I'm pretty sure its always a RecordRecTy and non of the callers really seem to expect null. But until I'm completely sure I'm going to revert this. llvm-svn: 235469
-
Craig Topper authored
llvm-svn: 235468
-
Craig Topper authored
llvm-svn: 235467
-
Craig Topper authored
llvm-svn: 235466
-
Craig Topper authored
[TableGen] Use 'isa' to identify UnsetInits rather than comparing with the singleton object created by UnsetInit::get(). Makes it more consistent with the other types. llvm-svn: 235465
-
Richard Smith authored
llvm-svn: 235464
-
Craig Topper authored
llvm-svn: 235463
-
Craig Topper authored
llvm-svn: 235462
-
Richard Smith authored
This graph will be used to determine the current set of active macros. This is foundation work for getting macro visibility correct across submodules of the current module. No functionality change for now. llvm-svn: 235461
-
Sanjay Patel authored
With SSE2, we can generate a 'movq' or other 64-bit store op on a 32-bit system even though 64-bit integers are not legal types. So instead of producing this: pshufd $229, %xmm0, %xmm1 ## xmm1 = xmm0[1,1,2,3] movd %xmm0, (%eax) movd %xmm1, 4(%eax) We can do: movq %xmm0, (%eax) This is a fix for the problem noted in D7296. Differential Revision: http://reviews.llvm.org/D9134 llvm-svn: 235460
-
Reid Kleckner authored
We should also teach the inliner to collapse framerecover of frameaddress of the current frame down to an alloca, but that can happen later. llvm-svn: 235459
-
David Blaikie authored
Calls to llvm::Value::mutateType are becoming extra-sensitive now that instructions have extra type information that will not be derived from operands or result type (alloca, gep, load, call/invoke, etc... ). The special-handling for mutateType will get more complicated as this work continues - it might be worth making mutateType virtual & pushing the complexity down into the classes that need special handling. But with only two significant uses of mutateType (vectorization and linking) this seems OK for now. Totally open to ideas/suggestions/improvements, of course. With this, and a bunch of exceptions, we can roundtrip an indirect call site through bitcode and IR. (a direct call site is actually trickier... I haven't figured out how to deal with the IR deserializer's lazy construction of Function/GlobalVariable decl's based on the type of the entity which means looking through the "pointer to T" type referring to the global) llvm-svn: 235458
-
NAKAMURA Takumi authored
llvm-svn: 235457
-
Hans Wennborg authored
Patch by Daniel Cheng! Differential Revision: http://reviews.llvm.org/D9175 llvm-svn: 235456
-
Wei Mi authored
https://llvm.org/bugs/show_bug.cgi?id=23163. Gep merging sometimes behaves like a reverse CSE/LICM optimization, which has negative impact on performance. In this patch we restrict gep merging to happen only when the indexes to be merged are both consts, which ensures such merge is always beneficial. The patch makes gep merging only happen in very restrictive cases. It is possible that some analysis/optimization passes rely on the merged geps to get better result, and we havn't notice them yet. We will be ready to further improve it once we see the cases. Differential Revision: http://reviews.llvm.org/D8911 llvm-svn: 235455
-
Chaoren Lin authored
llvm-svn: 235454
-
Wei Mi authored
llvm-svn: 235453
-
Artem Belevich authored
- Changed CUDALaunchBounds arguments from integers to Expr* so they can be saved in AST for instantiation. - Added support for template instantiation of launch_bounds attrubute. - Moved evaluation of launch_bounds arguments to NVPTXTargetCodeGenInfo:: SetTargetAttributes() where it can be done after template instantiation. - Added a warning on negative launch_bounds arguments. - Amended test cases. Differential Revision: http://reviews.llvm.org/D8985 llvm-svn: 235452
-
Wei Mi authored
https://llvm.org/bugs/show_bug.cgi?id=23163. Gep merging sometimes behaves like a reverse CSE/LICM optimizations, which has negative impact on performance. In this patch we restrict gep merging to happen only when the indexes to be merged are both consts, which ensures such merge is always beneficial. The patch makes gep merging only happen in very restrictive cases. It is possible that some analysis/optimization passes rely on the merged geps to get better result, and we havn't notice them yet. We will be ready to further improve it once we see the cases. Differential Revision: http://reviews.llvm.org/D9007 llvm-svn: 235451
-
Andrew Kaylor authored
llvm-svn: 235450
-
Artem Belevich authored
Added cuda_builtin_vars.h which implements built-in CUDA variables using __declattr(property). Fields of built-in variables (except for warpSize) are implemented using __declattr(property) which replaces read/write of a member field with a call to a getter/setter member function, in this case with appropriate NVPTX builtin. Added a test case to check diagnostics on attempt to construct or improperly access a built-in variable. Differential Revision: http://reviews.llvm.org/D9064 llvm-svn: 235448
-
Enrico Granata authored
Add properties to SBExecutionContext to access the several entities it stores in a more Pythonic fashion llvm-svn: 235447
-
Richard Smith authored
[modules] Move list of exported module macros from IdentifierInfo lookup table to separate storage, adjacent to the macro directive history. This is substantially simpler, provides better space usage accounting in bcanalyzer, and gives a more compact representation. No functionality change intended. llvm-svn: 235420
-
Ahmed Bougacha authored
MemIntrinsic::getDest() looks through pointer casts, and using it directly when building the new GEP+memset results in stuff like: %0 = getelementptr i64* %p, i32 16 %1 = bitcast i64* %0 to i8* call ..memset(i8* %1, ...) instead of the correct: %0 = bitcast i64* %p to i8* %1 = getelementptr i8* %0, i32 16 call ..memset(i8* %1, ...) Instead, use getRawDest, which just gives you the i8* value. While there, use the memcpy's dest, as it's live anyway. In most cases, when the optimization triggers, the memset and memcpy sizes are the same, so the built memset is 0-sized and eliminated. The problem occurs when they're different. Fixes a regression caused by r235232: PR23300. llvm-svn: 235419
-
Krzysztof Parzyszek authored
llvm-svn: 235418
-
Lang Hames authored
llvm-svn: 235417
-
Daniel Berlin authored
Summary: This lets us use range based for loops. Reviewers: chandlerc Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D9169 llvm-svn: 235416
-
Jingyue Wu authored
Summary: With D9096 and D9101, there's no need to run DCE after SLSR and SeparateConstOffsetFromGEP. Test Plan: no regression Reviewers: jholewinski, meheff Subscribers: jholewinski, llvm-commits Differential Revision: http://reviews.llvm.org/D9172 llvm-svn: 235415
-
Sanjoy Das authored
The comment was made stale in r171735. llvm-svn: 235414
-
Duncan P. N. Exon Smith authored
Remove the `DIArray` and `DITypeArray` typedefs, preferring the underlying types (`DebugNodeArray` and `MDTypeRefArray`, respectively). llvm-svn: 235413
-
Duncan P. N. Exon Smith authored
An upcoming LLVM commit will remove the `DIArray` and `DITypeArray` typedefs that shadow `DebugNodeArray` and `MDTypeRefArray`, respectively. Use those types directly. llvm-svn: 235412
-
Sergey Matveev authored
llvm-svn: 235411
-
Jingyue Wu authored
Summary: After we rewrite a candidate, the instructions used by the old form may become unused. This patch cleans up these unused instructions so that we needn't run DCE after SLSR. Test Plan: removed -dce in all the SLSR tests Reviewers: broune, meheff Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D9101 llvm-svn: 235410
-
Jingyue Wu authored
Summary: so that we needn't run DCE after this pass. Test Plan: removed -dce from the commandline in split-gep.ll and split-gep-and-gvn.ll Reviewers: meheff Subscribers: llvm-commits, HaoLiu, hfinkel, jholewinski Differential Revision: http://reviews.llvm.org/D9096 llvm-svn: 235409
-
Yaron Keren authored
llvm-svn: 235408
-
Duncan P. N. Exon Smith authored
Use `MDType*` instead of `MDNode*` in `DITypeIdentifierMap`, since all the members should be types. llvm-svn: 235407
-
Daniel Berlin authored
Summary: MemorySSA uses this algorithm as well, and this enables us to reuse the code in both places. There are no actual algorithm or datastructure changes in here, just code movement. Reviewers: qcolombet, chandlerc Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D9118 llvm-svn: 235406
-