- Nov 12, 2019
-
-
Florian Hahn authored
This patch adds a new IRTransformations directory to llvm/examples/. This is intended to serve as a new home for example transformations/analysis code used by various tutorials. If LLVM_BUILD_EXAMPLES is enabled, the ExamplesIRTransforms library is linked into the opt binary and the example passes become available. To start off with, it contains the CFG simplifications used in the IR part of the 'Getting Started With LLVM: Basics' tutorial at the US LLVM Developers Meeting 2019. Reviewers: paquette, jfb, meikeb, lhames, kbarton Reviewed By: paquette Differential Revision: https://reviews.llvm.org/D69416
-
Muhammad Omair Javaid authored
This reverts commit 3f594ed1. This change has cause LLDB expression evaluation to fail on Arm Linux. Differential Revision: https://reviews.llvm.org/D63540
-
Pavel Labath authored
This warning triggers when a class defines a copy constructor but not a copy-assignment operator (which then gets auto-generated by the compiler). Fix the warning by deleting the other operator too, as the default implementation works just fine.
-
Pavel Labath authored
-
Alex Denisov authored
Summary: getAsInstruction is the only non-const member method. It is impossible to enforce const-correctness because of it. Reviewers: jmolloy, majnemer Reviewed By: jmolloy Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D70113
-
Tim Northover authored
-
Michał Górny authored
Differential Revision: https://reviews.llvm.org/D70060
-
Florian Hahn authored
If the MOVi operand was renamable, the operands of the expanded instructions are also renamable. Reviewers: thegameg, samparker, zatrazz Reviewed By: thegameg Differential Revision: https://reviews.llvm.org/D70061
-
Diana Picus authored
Don't try to canonicalize loads to scalable vector types to loads of integers. This removes one assertion when trying to use a TypeSize as a parameter to DataLayout::isLegalInteger. It does not handle the second part of the function (which looks at bitcasts). This patch also contains a NFC fix for Load Analysis, where a variable initialization that would cause the same assertion is moved closer to its use. This allows us to run the new test for InstCombine without having to teach LocationSize to play nicely with scalable vectors. Differential Revision: https://reviews.llvm.org/D70075
-
Simon Pilgrim authored
-
Simon Pilgrim authored
Fixes cppcheck warning.
-
Simon Pilgrim authored
Additional coverage for D70079
-
Tatyana Krasnukha authored
-
Florian Hahn authored
Currently we have limited support for outer loops with multiple basic blocks after the inner loop exit. But the current checks for creating PHIs for loop exit values only assumes the header and latches of the outer loop. It is better to just skip incoming values defined in the original inner loops. Those are handled earlier. Reviewers: efriedma, mcrosier Reviewed By: efriedma Differential Revision: https://reviews.llvm.org/D70059
-
Raphael Isemann authored
We know should_stop_here is false here, so we might as well return false directly.
-
Pavel Labath authored
Summary: This patch extracts the logic for computing the "absolute" locations, which was partially present in the debug_loclists dumper, completes it, and moves it into a separate function. This makes it possible to later reuse the same logic for uses other than dumping. The dumper is changed to reuse the location list interpreter, and its format is changed somewhat. In "verbose" mode it prints the "raw" value of a location list, the interpreted location (if available) and the expression itself. In non-verbose mode it prints only one of the location forms: it prefers the interpreted form, but falls back to the "raw" format if interpretation is not possible (for instance, because we were not given a base address, or the resolution of indirect addresses failed). This patch also undos some of the changes made in D69672, namely the part about making all functions static. The main reason for this is that I learned that the original approach (dumping only fully resolved locations) meant that it was impossible to rewrite one of the existing tests. To make that possible (and make the "inline location" dump work in more cases), I now reuse the same dumping mechanism as is used for section-based dumping. As this required having more objects know about the various location lists classes, it seemed like a good idea to create an interface abstracting the difference between them. Therefore, I now create a DWARFLocationTable class, which will serve as a base class for the location list classes. DWARFDebugLoclists is made to inherit from that. DWARFDebugLoc will follow. Another positive effect of this change is that section-based dumping code will not need to use templates (as originally) envisioned, and that the argument lists of the dumping functions become shorter. Reviewers: dblaikie, probinson, JDevlieghere, aprantl, SouraVX Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D70081
-
David Zarzycki authored
Preparation for: https://reviews.llvm.org/D70079 https://reviews.llvm.org/D70077
-
mydeveloperday authored
Summary: https://bugs.llvm.org/show_bug.cgi?id=36294 Addressing bug related to returning after return type not being honoured for some operator types. ``` $ bin/clang-format --style="{BasedOnStyle: llvm, AlwaysBreakAfterReturnType: TopLevelDefinitions}" /tmp/foo.cpp class Foo { public: bool operator!() const; bool operator<(Foo const &) const; bool operator*() const; bool operator->() const; bool operator+() const; bool operator-() const; bool f() const; }; bool Foo::operator!() const { return true; } bool Foo::operator<(Foo const &) const { return true; } bool Foo::operator*() const { return true; } bool Foo::operator->() const { return true; } bool Foo::operator+() const { return true; } bool Foo::operator-() const { return true; } bool Foo::f() const { return true; } ``` Reviewers: mitchell-stellar, klimek, owenpan, sammccall, rianquinn Reviewed By: sammccall Subscribers: merge_guards_bot, cfe-commits Tags: #clang-format, #clang-tools-extra, #clang Differential Revision: https://reviews.llvm.org/D69573
-
Raphael Isemann authored
-
Raphael Isemann authored
Summary: swift-lldb currently has to patch the ExpressionKind enum to add support for Swift expressions. If we implement LLVM's RTTI with a static ID variable instead of a centralised enum we can drop that patch. Reviewers: labath, davide Reviewed By: labath Subscribers: JDevlieghere, lldb-commits Tags: #upstreaming_lldb_s_downstream_patches, #lldb Differential Revision: https://reviews.llvm.org/D70070
-
Raphael Isemann authored
Reviewers: davide, xiaobai Reviewed By: davide, xiaobai Subscribers: davide, JDevlieghere, lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D70074
-
Raphael Isemann authored
We call IsPossibleDynamicType but we also need to check if this is a Clang type, otherwise other languages with dynamic types (like Swift) might end up being interpreted as potential Obj-C dynamic types.
-
Daniil Suchkov authored
Reviewers: spatel, RKSimon, lebedev.ri, apilipenko Reviewed-By: apilipenko Tags: #llvm Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D68263
-
Tim Renouf authored
In MachineCopyPropagation, when propagating the source of a copy into the operand of a later instruction, bail if a destination overlaps (partly defines) the copy source. If the instruction where the substitution is happening is also a copy, allowing the propagation confuses the tracking mechanism. Differential Revision: https://reviews.llvm.org/D69953 Change-Id: Ic570754f878f2d91a4a50a9bdcf96fbaa240726d
-
Craig Topper authored
-
Craig Topper authored
-
Mikael Holmen authored
E.g. the buildbot at http://lab.llvm.org:8011/builders/ppc64le-lld-multistage-test/builds/7259/steps/build-stage2-unified-tree/logs/stdio failed with /home/buildbots/ppc64le-lld-multistage-test/ppc64le-lld-multistage-test/llvm-project/llvm/unittests/Transforms/Utils/VFABIUtils.cpp:50:22: error: unused variable 'FnAttrs' [-Werror,-Wunused-variable] const AttributeSet FnAttrs = Attrs.getFnAttributes(); ^ 1 error generated.
-
Georgii Rymar authored
This converts elf-linker-options.ll to use yaml2obj instead of llc, improves and cleanups it a bit. This opens a road to add an additional tests for checking the broken cases. Differential revision: https://reviews.llvm.org/D70004
-
Georgii Rymar authored
SHT_LLVM_LINKER_OPTIONS section contains pairs of null-terminated strings. This patch adds support for them. Differential revision: https://reviews.llvm.org/D69895
-
Hideto Ueno authored
Summary: This patch introduces align attribute deduction for callsite argument, function argument, function returned and floating value based on must-be-executed-context. Reviewers: jdoerfert, sstefan1 Reviewed By: jdoerfert Subscribers: hiraditya, jfb, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D69797
-
Nick Terrell authored
* Add inline to the helper functions because gcc-9 won't inline all of them without the hint. I've avoided `__attribute__((always_inline))` because gcc and clang will inline without it, and improves compatibility. * Replace the byte-by-byte copy in update() with endian::readbe32() since perf reports that 1/2 of the time is spent copying into the buffer before this patch. When lld uses --build-id=sha1 it spends 30-45% of CPU in SHA1 depending on the binary (not wall-time since it is parallel). This patch speeds up SHA1 by a factor of 2 on clang-8 and 3 on gcc-6. This leads to a >10% improvement in overall linking time. lld-speed-test benchmarks run on an Intel i9-9900k with Turbo disabled on CPU 0 compiled with clang-9. Stats recorded with `perf stat -r 5`. All inputs are using `--build-id=sha1`. | Input | Before (seconds) | After (seconds) | | --- | --- | --- | | chrome | 2.14 | 1.82 (-15%) | | chrome-icf | 2.56 | 2.29 (-10%) | | clang | 0.65 | 0.53 (-18%) | | clang-fsds | 0.69 | 0.58 (-16%) | | clang-gdb-index | 21.71 | 19.3 (-11%) | | gold | 0.42 | 0.34 (-19%) | | gold-fsds | 0.431 | 0.355 (-17%) | | linux-kernel | 0.625 | 0.575 (-8%) | | llvm-as | 0.045 | 0.039 (-14%) | | llvm-as-fsds | 0.035 | 0.039 (-11%) | | mozilla | 11.3 | 9.8 (-13%) | | mozilla-gc | 11.84 | 10.36 (-12%) | | mozilla-O0 | 8.2 | 5.84 (-28%) | | scylla | 5.59 | 4.52 (-19%) | Reviewed By: ruiu, MaskRay Differential Revision: https://reviews.llvm.org/D69295
-
Fangrui Song authored
-
Fangrui Song authored
-
Vasileios Porpodas authored
Summary: This patch introduces a new heuristic for guiding operand reordering. The new "look-ahead" heuristic can look beyond the immediate predecessors. This helps break ties when the immediate predecessors have identical opcodes (see lit test for examples). Reviewers: RKSimon, ABataev, dtemirbulatov, Ayal, hfinkel, rnk Reviewed By: RKSimon, dtemirbulatov Subscribers: xbolva00, Carrot, hiraditya, phosek, rnk, rcorcs, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D60897
-
Thomas Finch authored
Summary: The attached test case replicates a null dereference crash in `yaml::Document::skip()`. This was fixed by adding a check and early return in the method. Reviewers: Bigcheese, hintonda, beanz Reviewed By: hintonda Subscribers: hiraditya, dexonsmith, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D69974
-
LLVM GN Syncbot authored
-
Francesco Petrogalli authored
The attribute is stored at the `FunctionIndex` attribute set, with the name "vector-function-abi-variant". The get/set methods of the attribute have assertion to verify that: 1. Each name in the attribute is a valid VFABI mangled name. 2. Each name in the attribute correspond to a function declared in the module. Differential Revision: https://reviews.llvm.org/D69976
-
António Afonso authored
Summary: I want to be able to specify which python framework to use for lldb in macos. With python2.7 we could just rely on the MacOS one but python3.7 is not shipped with the OS. An alternative is to use the one shipped with Xcode but that could be path dependent or maybe the user doesn't have Xcode installed at all. A definite solution is to just ship a python framework with lldb. To make this possible I added "@loader_path/../../../" to the rpath so it points to the same directory as the LLDB.framework, this way we can just drop any frameworks there. Reviewers: hhb, sgraenitz, xiaobai, smeenai, beanz, labath Reviewed By: labath Subscribers: beanz, labath, mgorny, lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D69931
-
aqjune authored
Summary: - Add llvm::SimplifyFreezeInst - Add InstCombiner::visitFreeze - Add llvm tests Reviewers: majnemer, sanjoy, reames, lebedev.ri, spatel Reviewed By: reames, lebedev.ri Subscribers: reames, lebedev.ri, filcab, regehr, trentxintong, llvm-commits Differential Revision: https://reviews.llvm.org/D29013
-
Nemanja Ivanovic authored
The author of the patch forgot to add -verify-machineinstrs to the RUN lines which would have made the issue appear on all bots. Added that as well as a fix for the undefined register issue (after the hoisting).
-