profile
viewpoint

llvm/llvm-project 6310

The LLVM Project is a collection of modular and reusable compiler and toolchain technologies. Note: the repository does not accept github pull requests at this moment. Please submit your patches at http://reviews.llvm.org.

sg-dev/multinet.js 9

an online visualization framework for large, dynamic and multi-layered graphs

fhahn/django-gaeauth 8

An Django authentication backend for using the Google App Engine Users and Oauth API for user login/logout.

fhahn/luna 8

A luajit bytecode interpreter written in RPython

fhahn/alive2 0

Automatic verification of LLVM optimizations

fhahn/cargo 0

The Rust package manager

fhahn/cxx-abi 0

C++ ABI Summary

fhahn/django 0

The Web framework for perfectionists with deadlines.

push eventfhahn/llvm-project

Stephan Herhut

commit sha 366d8435b41dcc01013c507681523c65cdee2180

[mlir][gpu] Fix bug in kernel outlining The updated version of kernel outlining did not handle cases correctly where an operand of a candidate for sinking itself was defined by an operation that is a sinking candidate. In such cases, it could happen that sunk operations were inserted in the wrong order, breaking ssa properties. Differential Revision: https://reviews.llvm.org/D89112

view details

Simon Pilgrim

commit sha 556316cf724e5a2c569f07a5e04d27e2ff1a6c66

[InstCombine] foldShiftOfShiftedLogic - replace cast<BinaryOperator> with m_BinOp matcher. NFCI. Allows us to drop the !isa<ConstantExpr> check.

view details

Alexander Kornienko

commit sha fe4715c47f9c02a83b339c12067f1d27a3115fe4

Remove old create(MainFile)?IncludeInsertion overloads Reviewed By: hokein Differential Revision: https://reviews.llvm.org/D89117

view details

Simon Pilgrim

commit sha 9e796d5e71d74abaec07295aac5a60a70eb9b057

[InstCombine] foldShiftOfShiftedLogic - add support for nonuniform constant vectors

view details

Florian Hahn

commit sha 8f56e382f782632c4b137339ab3c362fdbab62a5

[SCEV] Do not apply info from loop guards in AddRecs. We cannot guarantee that the replacement expression is loop-invariant in all AddRecs in the source expression. Use a rewriter that skips AddRecExpr for now. Fixes PR47776.

view details

Stefan Pintilie

commit sha 0741a2c9caca864fc30af2104712d02accdc12e6

[Clang][unittests][NFC] Break up test in Callbacks.cpp The Callbacks.cpp test was taking a long time to compile on some build bots causing timeouts. This patch splits up that test into five separate cpp files and a header file. Reviewed By: gribozavr2 Differential Revision: https://reviews.llvm.org/D88886

view details

LLVM GN Syncbot

commit sha 5e65d384a2ea6c9ef3009ad958a6ec281bdb52c7

[gn build] Port 0741a2c9cac

view details

Tres Popp

commit sha fa200dc3592e1947f55bf68f2cb2a796ee0bf7f0

[mlir] Use PatternRewriter infrastructure for shape.assuming bufferization Without this, legalization might not recursively handle child ops properly. Additionally, this is required for pattern rewriting to properly rollback conversions. Differential Revision: https://reviews.llvm.org/D89122

view details

Louis Dionne

commit sha 86d61365d8cfae8afdb4deb90b21709ddd482b20

[libc++] More consistency with declaring int main(int, char**)

view details

Fanbo Meng

commit sha d91234b21c1a1a34d98157089a8769d8f9a32f06

[SystemZ][z/OS] Update target specific __attribute__((aligned)) value for test z/OS defaults to 16 bytes for __attribute__((aligned)), modify the test to differentiate between z/OS and Linux on s390x. Reviewed By: abhina.sreeskantharajan Differential Revision: https://reviews.llvm.org/D89127

view details

Sam McCall

commit sha 41d2987c7558734cef74151e743645f47d9df501

[clangd] Stop logging in fromJSON, report instead.

view details

Irina Dobrescu

commit sha 63ca276dc64f3869aec9a05250bd64b8f423ab44

[mlir][openmp][NFC]Remove unnecessary brackets and rephrase ParallelOp description in mlir definition Differential Revision: https://reviews.llvm.org/D88740

view details

Louis Dionne

commit sha ddb2baf9fbff3d574c6c2bd69c2c9569100509a4

[libc++] Make sure we don't cache DSL functions too aggressively To make sure we don't store a mutable object (which could be modified by outside code without us noticing) as the cache key, we pickle the cache key to get a byte stream. If two keys are unequal, we know for sure they will not have the same pickling. And if they are equal, there's a large chance they will have the same pickling. If they don't, we might end up not reusing a cached entry when we could have, but at least the behavior we'll have is semantically correct.

view details

Anastasia Stulova

commit sha 71d3b7ec7b62d37dd3c8eb1a921f0b3e1ffdaa7f

[OpenCL] Add new compilation mode for OpenCL 3.0. Extended -cl-std/std flag with CL3.0 and added predefined version macros. Patch by Anton Zabaznov (azabaznov)! Tags: #clang Differential Revision: https://reviews.llvm.org/D88300

view details

Simon Pilgrim

commit sha ccf12607921766d57b0238ee7db5754509935288

[InstCombine] Add tests for X shift (A srem B) -> X shift (A and B-1) pow2 nonuniform constant vectors

view details

Sanjay Patel

commit sha 080e6bc2050e28ae198d82f0e934ca7b4548c3b7

[InstCombine] allow vector splats for add+and with high-mask There might be a better way to specify the pre-conditions, but this is hopefully clearer than the way it was written: https://rise4fun.com/Alive/Jhk3 Pre: C2 < 0 && isShiftedMask(C2) && (C1 == C1 & C2) %a = and %x, C2 %r = add %a, C1 => %a2 = add %x, C1 %r = and %a2, C2

view details

Krzysztof Parzyszek

commit sha 99cafe009477970e2f14415d1b48ceed954dc84b

[Hexagon] Return 1 instead of 0 from getMaxInterleaveFactor

view details

Simon Pilgrim

commit sha 1c040a3e5615e54022cf9786b0f5c440ae3d3205

[InstCombine] commonShiftTransforms - add support for pow2 nonuniform constant vectors in srem fold Note: we already fold srem to undef if any denominator vector element is undef.

view details

Scott Linder

commit sha 4a98cf7867fac7b5d3de7b1ae3285b1d9e6ea3ce

[NFC] Reformat MILexer.cpp:getIdentifierKind Reformat to avoid unrelated changes in diff of future patch. Committed as obvious.

view details

David Green

commit sha 4c3515cd623ed97585a6e625d866c1913f82ab9d

[ARM] Add MVE vecreduce costmodel tests. NFC There were some existing tests that were not super useful. New ones are added for testing MVE specific patterns.

view details

push time in an hour

push eventllvm/llvm-project

Florian Hahn

commit sha 2e580102082293f9f80160bc86413e401c566d8f

[DSE] Do not scan users of memory terminators for further reads. isMemTerminator checks if the current def is a memory terminator that terminates the memory pointed to by DefLoc. We do not have to add any of their users to the worklist, because the follow-on users cannot read the memory in question. This leads to more stores eliminated in the presence of lifetime calls. Previously we added the users of those intrinsics to the worklist, limiting elimination. In terms of removed stores, this gives a nice boost on some benchmarks (MultiSource/SPEC2000/SPEC2006 on X86 with -flto -O3): Same hash: 205 (filtered out) Remaining: 32 Metric: dse.NumFastStores Program base patch diff test-suite...000/197.parser/197.parser.test 4.00 8.00 100.0% test-suite...rolangs-C++/family/family.test 4.00 7.00 75.0% test-suite...marks/7zip/7zip-benchmark.test 1722.00 2189.00 27.1% test-suite...CFP2000/177.mesa/177.mesa.test 30.00 38.00 26.7% test-suite :: External/Nurbs/nurbs.test 44.00 49.00 11.4% test-suite...lications/sqlite3/sqlite3.test 115.00 128.00 11.3% test-suite...006/447.dealII/447.dealII.test 2715.00 3013.00 11.0% test-suite...ProxyApps-C++/CLAMR/CLAMR.test 237.00 261.00 10.1% test-suite...tions/lambda-0.1.3/lambda.test 40.00 44.00 10.0% test-suite...3.xalancbmk/483.xalancbmk.test 1366.00 1475.00 8.0% test-suite...abench/jpeg/jpeg-6a/cjpeg.test 13.00 14.00 7.7% test-suite...oxyApps-C++/miniFE/miniFE.test 43.00 46.00 7.0% test-suite...lications/ClamAV/clamscan.test 230.00 246.00 7.0% test-suite...006/450.soplex/450.soplex.test 284.00 299.00 5.3% test-suite...nsumer-jpeg/consumer-jpeg.test 21.00 22.00 4.8%

view details

push time in 2 hours

push eventllvm/llvm-project

Florian Hahn

commit sha 6439fde6d403d3e01e265fb84b0beffe67f745c5

[DSE] Bail out from getLocForWriteEx if call is not argmemonly/inacc_mem. This change should currently not have any impact, but guard against further inconsistencies between MemoryLocation and function attributes.

view details

push time in 4 hours

push eventllvm/llvm-project

Florian Hahn

commit sha f558256939c47b8b5f59c19c71e04324df8ca26a

[DSE] Add test to make sure memccpy does not kill stores. It is not known how many bytes are written by memccpy, so it cannot kill any stores.

view details

push time in 5 hours

push eventllvm/llvm-project

Florian Hahn

commit sha 3cbdae22b91b94d21c0ca348e5ceea7081c9887d

[SCEV] Add tests where assumes can be used to improve tripe multiple. This patch adds a set of tests where information from assumes can be used to improve the trip multiple. See PR47904.

view details

push time in a day

push eventllvm/llvm-project

Florian Hahn

commit sha f5cf7f544b7abe8488f76945537044f700b5548a

[DSE] Do not consider 'noop' intrinsics as read-clobbers. isNoopIntrinsic returns true for some intrinsics that are modeled in MemorySSA but do not actually read or write any memory and do not block DSE. Such intrinsics should not be considered as read-clobbers.

view details

push time in 2 days

push eventllvm/llvm-project

Florian Hahn

commit sha b86595c93f66c1b58b13b0f2385901cae88ac7e5

[DSE] Add tests for elimination at end of function with lifetime.

view details

push time in 2 days

push eventllvm/llvm-project

Florian Hahn

commit sha 7081db99eee0123f955ab01e550bdfdfce606dd2

[DSE] Add tests with noalias store between noop load/store. This adds 2 new tests from PR47887 and regenerates the check lines for the file.

view details

push time in 2 days

push eventllvm/llvm-project

Florian Hahn

commit sha f085b7cbc1a673e89f74926961e44ba468411619

[SCEV] Add additional tests where the max BTC is limited by wrapping.

view details

push time in 4 days

push eventllvm/llvm-project

Florian Hahn

commit sha e034c3f7043a0f5a0b0af834a4b84d06e6b8948e

[SCEV] Add a few test cases where the max BTC is limited by wrapping.

view details

push time in 4 days

push eventllvm/llvm-project

Florian Hahn

commit sha 51ff04567b2f8d06b2062bd3ed72eab2e93e4466

Recommit "[DSE] Switch to MemorySSA-backed DSE by default." After investigation by @asbirlea, the issue that caused the revert appears to be an issue in the original source, rather than a problem with the compiler. This patch enables MemorySSA DSE again. This reverts commit 915310bf14cbac58a81fd60e0fa9dc8d341108e2.

view details

push time in 4 days

push eventllvm/llvm-project

Florian Hahn

commit sha 89c0124273339076b25bf860f6c2ee765ab96db3

[LoopVersion] Unify SCEVChecks and alias check handling (NFC). This is an initial cleanup of the way LoopVersioning interacts with LAA. Currently LoopVersioning has 2 ways of initializing things: 1. Passing LAI and passing UseLAIChecks = true 2. Passing UseLAIChecks = false, followed by calling setSCEVChecks and setAliasChecks. Both ways of initializing lead to the same result and the duplication seems more complicated than necessary. This patch removes the UseLAIChecks flag from the constructor and the setSCEVChecks & setAliasChecks helpers and move initialization exclusively to the constructor. This simplifies things, by providing a single way to initialize LoopVersioning and reducing duplication. Reviewed By: Meinersbur, lebedev.ri Differential Revision: https://reviews.llvm.org/D84406

view details

push time in 5 days

push eventllvm/llvm-project

Florian Hahn

commit sha 93f6c6b79c500f776072fc50e57ff7e281e3941c

Recommit "[VPlan] Use VPValue def for VPMemoryInstructionRecipe." This reverts the revert commit 710aceb645e7dba4de7053eef2c616311b9163d4 and includes a fix for a memsan failure. Original message: This patch turns VPMemoryInstructionRecipe into a VPValue and uses it during VPlan construction and codegeneration instead of the plain IR reference where possible.

view details

push time in 6 days

push eventllvm/llvm-project

Florian Hahn

commit sha 2322080bc3889145b7fb3c8798016467fe5e3b10

[ConstraintElimination] Add add/sub/and/or test cases. This adds a new set of tests for upcoming constraint elimination changes.

view details

push time in 7 days

push eventllvm/llvm-project

Florian Hahn

commit sha 525b085a65d30a5f2ae2af38c0be252fe8d4781b

[VPlan] Use VPValue def for VPMemoryInstructionRecipe. This patch turns VPMemoryInstructionRecipe into a VPValue and uses it during VPlan construction and codegeneration instead of the plain IR reference where possible. Reviewed By: dmgreen Differential Revision: https://reviews.llvm.org/D84680

view details

push time in 8 days

push eventllvm/llvm-project

Florian Hahn

commit sha ea058d289cbf54e5b33aac7f7a13d0d58625f1b9

[VPlan] Use operands for printing of VPWidenMemoryInstructionRecipe. Now that operands of the recipe are managed through VPUser, we can simplify the printing by just using the operands.

view details

push time in 8 days

push eventllvm/llvm-project

Florian Hahn

commit sha ad5541045a63fe3049fc910d843bcbb78f7c7056

[LoopDeletion] Remove over-eager SCEV verification. 60b852092c98dbdc6248d60109d90ae6f8ad841c introduced SCEV verification to deleteDeadLoop, but it appears this check is currently a bit over-eager and some users of deleteDeadLoop appear to only patch up SE after calling it (e.g. PR47753). Remove the extra check for now. We can consider adding it back after we tracked down the source of the inconsistency for PR47753.

view details

push time in 8 days

push eventllvm/llvm-project

Florian Hahn

commit sha d48b249b71628f3a73540734f50c6aae21828566

[SCEV] Add test cases where the max BTC is imprecise, due to step != 1. Add a test case where we fail to compute a tight max backedge taken count, due to the step being != 1. This is part of the issue with PR40961.

view details

push time in 10 days

push eventllvm/llvm-project

Florian Hahn

commit sha 2e9fd754b41cba2253c066e9e8a7ab4770432550

[SCEV] Handle ULE in applyLoopGuards. Handle ULE predicate in similar fashion to ULT predicate in applyLoopGuards.

view details

push time in 10 days

push eventllvm/llvm-project

Florian Hahn

commit sha 2c6fc28aba749e1316ba29999ec5d1f3a44e07df

[SCEV] Add a test case with ULE loop guard.

view details

push time in 10 days

push eventllvm/llvm-project

Florian Hahn

commit sha 8f56e382f782632c4b137339ab3c362fdbab62a5

[SCEV] Do not apply info from loop guards in AddRecs. We cannot guarantee that the replacement expression is loop-invariant in all AddRecs in the source expression. Use a rewriter that skips AddRecExpr for now. Fixes PR47776.

view details

push time in 11 days

push eventllvm/llvm-project

Florian Hahn

commit sha a73166a45204378f6f8b4a6ff2d962f0ff56d51e

[LAA] Use DL to get element size for bound computation. Currently LAA uses getScalarSizeInBits to compute the size of an element when computing the end bound of an access. This does not work as expected for pointers to pointers, because getScalarSizeInBits will return 0 for pointer types. By using DataLayout to get the size of the element we can also correctly handle pointer element types. Note the changes to the existing test, which seems to also use the wrong offset for the end. Fixes PR47751. Reviewed By: anemet Differential Revision: https://reviews.llvm.org/D88953

view details

push time in 13 days

push eventllvm/llvm-project

Florian Hahn

commit sha 20cfd5fa3362c71d0184639decf5c2acb743e4e6

[LAA] Add test for PR47751, which currently uses wrong bounds.

view details

push time in 13 days

push eventllvm/llvm-project

Mauri Mustonen

commit sha cef0de5eb59dde6369645d37883f393354c99acd

[VPlan] Add vplan native path vectorization test case for inner loop reduction Regarding this bug I posted earlier: https://bugs.llvm.org/show_bug.cgi?id=47035 After reading through LLVM source code and getting familiar with VPlan I was able to vectorize the code using by enabling VPlan native path. After talking with @fhahn he suggested that I contribute this as a test case. So here it is. I tried to follow the available guides how to do this best I could. I modified IR code by hand to have more clear variable names instead of numbers. One thing what I'd like to get input from someone is that is current CHECK lines sufficient enough to verify that the inner loop has been vectorized properly? Reviewed By: fhahn Differential Revision: https://reviews.llvm.org/D87564

view details

push time in 14 days

push eventllvm/llvm-project

Florian Hahn

commit sha 348d85a6c7950a5f14ee6c8741380b5876d99afd

[VPlan] Clean up uses/operands on VPBB deletion. Update the code responsible for deleting VPBBs and recipes to properly update users and release operands. This is another preparation for D84680 & following patches towards enabling modeling def-use chains in VPlan.

view details

push time in 15 days

push eventllvm/llvm-project

Florian Hahn

commit sha 357bbaab666b212c5bfb65df80e76aace5367eff

[VPlan] Add VPRecipeBase::toVPUser helper (NFC). This adds a helper to convert a VPRecipeBase pointer to a VPUser, for recipes that inherit from VPUser. Once VPRecipeBase directly inherits from VPUser this helper can be removed.

view details

push time in 16 days

push eventllvm/llvm-project

Florian Hahn

commit sha f5fe7abe8a8c8150b7b305bae963b429f15ea217

[VPlan] Account for removed users in replaceAllUsesWith. Make sure we do not iterate using an invalid iterator. Another small fix/step towards traversing the def-use chains in VPlan.

view details

push time in 16 days

push eventllvm/llvm-project

Florian Hahn

commit sha 82dcd383c422f03c2b399af5b94701365cdf1afa

[VPlan] Properly update users when updating operands. When updating operands of a VPUser, we also have to adjust the list of users for the new and old VPValues. This is required once we start transitioning recipes to become VPValues.

view details

push time in 17 days

push eventllvm/llvm-project

Florian Hahn

commit sha ef72591de971ee22dd47a949583fd1be38ba0d1b

[LV] Add another test case with unsinkable first-order recurrences.

view details

push time in 17 days

push eventllvm/llvm-project

Florian Hahn

commit sha 0867a9e85ace8ed0b11f6a7fc4c9e4bb1606263b

[VPlan] Use isa<> instead of directly checking VPRecipeID (NFC). getVPRecipeID is intended to be only used in `classof` helpers. Instead of checking it directly, use isa<> with the correct recipe type.

view details

push time in 18 days

push eventllvm/llvm-project

Florian Hahn

commit sha bb448a248371b48dbca8d647b7aaf9393154cf3d

[SLP] Add test where reduction result is used in PHI. Test case for PR47670.

view details

push time in 18 days

push eventllvm/llvm-project

Florian Hahn

commit sha 6481a764950055a08a5b8e0ba728e7f7299f932c

[PhaseOrdering] Add test that requires peeling before vectorization. Test case for PR47671.

view details

push time in 18 days

push eventllvm/llvm-project

Alexandre Rames

commit sha 700e63293eea4a23440f300b1e9125ca2e80c6e9

[Sema] Support Comma operator for fp16 vectors. The current half vector was enforcing an assert expecting "(LHS is half vector) == (RHS is half vector)" for comma. Reviewed By: ahatanak, fhahn Differential Revision: https://reviews.llvm.org/D88265

view details

push time in 20 days

issue commentAliveToolkit/alive2

Semantics of readnone function calls is wrong

Is the following correct? %x = call @use(1) %y = call @use(1) => %x = call @use(1) %y = %x ; RAUW

I think that should be allowed.

I think it would be good to clarify the wording of read none at least. In the first paragraph, it says accessing any mutable state visible to the caller is UB. In the last paragraph, it says it is UB to read/write any memory visible to the program.

With the wording from the first paragraph, it seems like reading some static memory and reading memory only visible to the function locally is OK.

fhahn

comment created time in 20 days

push eventllvm/llvm-project

Florian Hahn

commit sha d8563654701c79fb9ab28ecf94567d9934baed05

[VPlan] Change recipes to inherit from VPUser instead of a member var. Now that VPUser is not inheriting from VPValue, we can take the next step and turn the recipes that already manage their operands via VPUser into VPUsers directly. This is another small step towards traversing def-use chains in VPlan. This is NFC with respect to the generated code, but makes the interface more powerful.

view details

push time in 20 days

push eventllvm/llvm-project

Florian Hahn

commit sha 0eab9d5823815c6520697f8d725c402c88e5d050

[SCEV] Verify that all mapped SCEV AddRecs refer to valid loops. This check helps to guard against cases where expressions referring to invalidated/deleted loops are not properly invalidated. The additional check is motivated by the reproducer shared for 8fdac7cb7abb and I think in general make sense as a sanity check. Reviewed By: reames Differential Revision: https://reviews.llvm.org/D88166

view details

push time in 20 days

push eventllvm/llvm-project

Florian Hahn

commit sha 7bae2bc5a8dd11c016c895e3a691fb93575773f3

[LoopUtils] Only verify SE in builds with assertions. Follow up to 60b852092c98.

view details

push time in 21 days

push eventllvm/llvm-project

Florian Hahn

commit sha 60b852092c98dbdc6248d60109d90ae6f8ad841c

[LoopDeletion] Forget loop before setting values to undef After D71539, we need to forget the loop before setting the incoming values of phi nodes in exit blocks, because we are looking through those phi nodes now and the SCEV expression could depend on the loop phi. If we update the phi nodes before forgetting the loop, we miss those users during invalidation. Reviewed By: reames Differential Revision: https://reviews.llvm.org/D88167

view details

push time in 21 days

push eventllvm/llvm-project

Florian Hahn

commit sha b76df593eb660d1e4c9f1384a75b404ee5bcd06f

Revert "Recommit "[SCCP] Do not replace deref'able ptr with un-deref'able one."" Looks like there is still another remaining issue: http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-bootstrap-msan/builds/22273/steps/build%20libcxx%2Fmsan/logs/stdio This reverts commit 86a20d9e34f5a9989da72097f23f3b0a44157e73.

view details

push time in 21 days

push eventllvm/llvm-project

Florian Hahn

commit sha 86a20d9e34f5a9989da72097f23f3b0a44157e73

Recommit "[SCCP] Do not replace deref'able ptr with un-deref'able one." This version includes an small fix allowing function pointers to be unconditionally replaced for now. This reverts commit 4c5e4aa89b11ec3253258b8df5125833773d1b1e.

view details

push time in 21 days

push eventllvm/llvm-project

Florian Hahn

commit sha 0ad793f321ed8714870cacf0421e60cf9a3b7468

[SCEV] Also use info from assumes in applyLoopGuards. Similar to collecting information from branches guarding a loop, we can also collect information from assumes dominating the loop header. Fixes PR47247. Reviewed By: jdoerfert Differential Revision: https://reviews.llvm.org/D87854

view details

push time in 22 days

push eventllvm/llvm-project

Florian Hahn

commit sha 915310bf14cbac58a81fd60e0fa9dc8d341108e2

Revert "[DSE] Switch to MemorySSA-backed DSE by default." There appears to be a mis-compile with MemorySSA-backed DSE in combination with llvm.lifetime.end. It currently appears like DSE is doing the right thing and the llvm.lifetime.end markers are incorrect. The reverted patch uncovers the mis-compile. This patch temporarily switches back to the legacy DSE implementation, while we investigate. This reverts commit 9d172c8e9c845a36b61dc12c27de8acdbef8b247.

view details

push time in 24 days

push eventllvm/llvm-project

Florian Hahn

commit sha 8f0466edc0cb3782af4108bfe8840e2ad3de9b49

[DSE] Unify & fix mem terminator location checks. When looking for memory defs killed by memory terminators the code currently incorrectly ignores the size argument of llvm.lifetime.end. This patch updates the code to use isMemTerminator and updates isMemTerminator to use isOverwrite() to make sure locations that are outside the range marked as dead by llvm.lifetime.end are not considered. Note that isOverwrite is only used for llvm.lifetime.end, because free-like functions make the whole underlying object dead.

view details

push time in 24 days

push eventllvm/llvm-project

Florian Hahn

commit sha b2c0193afa2b25afc718bc32751147c5dc1bfd63

[DSE] Add tests with lifetime.end that only mark parts of the obj as dead. llvm.lifetime.end accepts a size parameters to limit the size of the location marked as dead. Add a few tests with stores to locations after the part that has been marked as dead.

view details

push time in 24 days

push eventllvm/llvm-project

Florian Hahn

commit sha 3a69ebf0ad018561c79fc52d9d3986fdc21d8d5c

[SCEV] Add another test using info from loop guards for BTC with NE.

view details

Florian Hahn

commit sha 7d274aa9bed00cdf1197b2f05140635be90f3362

[SCEV] Add support for `x != 0` to CollectCondition. Add support for NE predicates with 0 constants. Those can be translated to UMaxExpr(x, 1).

view details

push time in 25 days

push eventllvm/llvm-project

Florian Hahn

commit sha b5a3b901c73082c82f6eb387323cd61525423e2d

[SCEV] Add support for `x == constant` to CollectCondition. Add support for EQ predicates with constant operand. In that case, using the constant instead of an unknown expression should always be beneficial.

view details

push time in 25 days

push eventllvm/llvm-project

Florian Hahn

commit sha 8858340bd380b821bbad773c7b3a022a9bb5b2d9

[SCEV] Swap operands if LHS is not unknown. Currently we only use information from guards for unknown expressions. Swap LHS/RHS and predicate, if LHS is not unknown.

view details

push time in 25 days

push eventllvm/llvm-project

Florian Hahn

commit sha df77ce7cad081bf55042cf098b61b118dcdfc7e9

[SCEV] Extract code to collect conditions to lambda (NFC). This makes re-using the common functionality easier in follow-up patches.

view details

push time in 25 days

push eventllvm/llvm-project

Florian Hahn

commit sha 1fa06162c1cf648a6d4fac837e02b709a205f4df

[SCEV] Add more tests using info from loop guards for BTC.

view details

push time in 25 days

push eventllvm/llvm-project

Florian Hahn

commit sha d4ddf63fc40cfbbc348adcc45cdc6f6d78268c5c

[SCEV] Use loop guard info when computing the max BE taken count in howFarToZero. For some expressions, we can use information from loop guards when we are looking for a maximum. This patch applies information from loop guards to the expression used to compute the maximum backedge taken count in howFarToZero. It currently replaces an unknown expression X with UMin(X, Y), if the loop is guarded by X ult Y. This patch is minimal in what conditions it applies, and there are a few TODOs to generalize. This partly addresses PR40961. We will also need an update to LV to address it completely. Reviewed By: reames Differential Revision: https://reviews.llvm.org/D67178

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 31923f6b360300b8b148ad257419766999dfe504

[VPlan] Disconnect VPValue and VPUser. This refactors VPuser to not inherit from VPValue to facilitate introducing operations that introduce multiple VPValues (e.g. VPInterleaveRecipe). Reviewed By: Ayal Differential Revision: https://reviews.llvm.org/D84679

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha c671e34bf2ae0eaa78d214b849ddd5de30b3b5be

[VPlan] Add dump() helper to VPValue & VPRecipeBase. This provides a convenient way to print VPValues and recipes in a debugger. In particular it saves the user from instantiating VPSlotTracker to print recipes or values.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 3cbdfe424fec923b5ac1912742c62c22f856fb29

[SCEV] Add additional max BTC tests with loop guards.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 11dccf8d3aa5d55210f8b886fb21926c7a8353ca

Recommit "[SCEV] Look through single value PHIs." This commit was originally because it was suspected to cause a crash, but a reproducer did not surface. A crash that was exposed by this change was fixed in 1d8f2e52925b. This reverts the revert commit 0581c0b0eeba03da590d1176a4580cf9b9e8d1e3.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 57ae9bb9323548b2ad4ba8274c3910bf9c764983

[LSR] Preserve MSSA when using SplitCriticalEdge. LSR claims to MemorySSA, but we also have to make sure it is preserved when splitting critical edges. This can be done by passing MSSAU to SplitCriticalEdge. Fixes PR47557.

view details

push time in a month

create barnchfhahn/llvm-project

branch : perf/scev-guards

created branch time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 1d8f2e52925b3a3ab52726c745169f273239329d

[SCEVExpander] Support expanding nonintegral pointers with constant base. Currently SCEVExpander creates inttoptr for non-integral pointers if the base is a null constant for example. This results in invalid IR. This patch changes InsertNoopCastOfTo to emit a GEP & bitcast to convert to a non-integral pointer. First, a GEP of i8* null is generated and the integral value is used as index. The GEP is then bitcasted to the target type. This was exposed by D71539. Reviewed By: efriedma Differential Revision: https://reviews.llvm.org/D87827

view details

push time in a month

create barnchfhahn/llvm-project

branch : perf/adce-placement

created branch time in a month

create barnchfhahn/llvm-project

branch : llvm-patch-script

created branch time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 762fbbe536996acf7175b551ce0e2c310165b135

[Polly] Update map passed to SCEVParameterReweriter. The type of the map the SCEVParameterRewriter takes has been changed in 4635f6050b10. Update the single use in polly to use SCEV* as type of the values.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 9d172c8e9c845a36b61dc12c27de8acdbef8b247

Recommit "[DSE] Switch to MemorySSA-backed DSE by default." This switches to using DSE + MemorySSA by default again, after fixing the issues reported after the first commit. Notable fixes fc8200633122, a0017c2bc258. This reverts commit 3a59628f3cc26eb085acfc9cbdc97243ef71a6c5.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 4635f6050b105f13138ca6d7a85ae797415803a0

[SCEV] Generalize SCEVParameterRewriter to accept SCEV expression as target. This patch extends SCEVParameterRewriter to support rewriting unknown epxressions to arbitrary SCEV expressions. It will be used by further patches. Reviewed By: reames Differential Revision: https://reviews.llvm.org/D67176

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha a0017c2bc258690146f18491317144e487ddb101

[MemorySSA] Be more conservative when traversing MemoryPhis. I think we need to be even more conservative when traversing memory phis, to make sure we catch any loop carried dependences. This approach updates fillInCurrentPair to use unknown sizes for locations when we walk over a phi, unless the location is guaranteed to be loop-invariant for any possible loop. Using an unknown size for locations should ensure we catch all memory accesses to locations after the given memory location, which includes loop-carried dependences. Reviewed By: asbirlea Differential Revision: https://reviews.llvm.org/D87778

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 51973a607dfa4681037aff43e295f3ea1fb0f3f4

[SCEV] Add test cases for max BTC with loop guard info. This adds test cases for PR40961 and PR47247. They illustrate cases in which the max backedge-taken count can be improved by information from the loop guards.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 9dc1e53787abbf4f2624c73272bf00e23fdffba0

[MemorySSA] Add another loop clobber test case.

view details

push time in a month

push eventllvm/llvm-project

Dangeti Tharun kumar

commit sha 01e2b394ee16502440dbbb5440502a1e2aaf1477

[Partial Inliner] Compute intrinsic cost through TTI https://bugs.llvm.org/show_bug.cgi?id=45932 assert(OutlinedFunctionCost >= Cloner.OutlinedRegionCost && "Outlined function cost should be no less than the outlined region") getting triggered in computeBBInlineCost. Intrinsics like "assume" are considered regular function calls while computing costs. This patch enables computeBBInlineCost to queries TTI for intrinsic call cost. Reviewed By: fhahn Differential Revision: https://reviews.llvm.org/D87132

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha cb9528a0420e01caf7f3dc8288a11258fcf1425d

[DSE] Add another test cases with loop carried dependence.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 3d42d549554889ca182e1f3d31b23fa1383c6678

[ConstraintElimination] Add constraint elimination pass. This patch is a first draft of a new pass that adds a more flexible way to eliminate compares based on more complex constraints collected from dominating conditions. In particular, it aims at simplifying conditions of the forms below using a forward propagation approach, rather than instcomine-style ad-hoc backwards walking of def-use chains. if (x < y) if (y < z) if (x < z) <- simplify or if (x + 2 < y) if (x + 1 < y) <- simplify assuming no wraps The general approach is to collect conditions and blocks, sort them by dominance and then iterate over the sorted list. Conditions are turned into a linear inequality and add it to a system containing the linear inequalities that hold on entry to the block. For blocks, we check each compare against the system and see if it is implied by the constraints in the system. We also keep a stack of processed conditions and remove conditions from the stack and the constraint system once they go out-of-scope (= do not dominate the current block any longer). Currently there still are the least the following areas for improvements * Currently large unsigned constants cannot be added to the system (coefficients must be represented as integers) * The way constraints are managed currently is not very optimized. Reviewed By: spatel Differential Revision: https://reviews.llvm.org/D84547

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 3a59628f3cc26eb085acfc9cbdc97243ef71a6c5

Revert "[DSE] Switch to MemorySSA-backed DSE by default." This reverts commit fb109c42d91c30c8c7497ef1fd7aff6f2969c6e7. Temporarily revert due to a mis-compile pointed out at D87163.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 802d21cdf08ea43d5c32924ac29c44b00c4a841f

[ConstraintElimination] Add initial tests.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha db22e70d010744573df19d69ed3de5b84ea60d1c

[ConstraintSolver] Add isConditionImplied helper. This patch adds a isConditionImplied function that takes a constraint and returns true if the constraint is implied by the current constraints in the system. Reviewed By: spatel Differential Revision: https://reviews.llvm.org/D84545

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha cd4edf94cd43754954aff0ddabd704de0f8f7ac0

Recommit "[ConstraintSystem] Add helpers to deal with linear constraints." This patch recommits "[ConstraintSystem] Add helpers to deal with linear constraints." (it reverts the revert commit 8da6ae4ce1b686c5c13698e4c5ee937811fda6f7). The reason for the revert was using __builtin_multiply_overflow, which is not available for all compilers. The patch has been updated to use MulOverflow from MathExtras.h

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha f07f3c72375b872bfb988f7531d4e0485233ade1

[MemorySSA] Precommit test case for PR47498.

view details

Florian Hahn

commit sha c4f1b3144184e4c276a7e7c801cbcd4ac3c573ba

[MemorySSA] Make sure PerformedPhiTrans is updated for each visited def. 1ce82015f6d0 added a fix to restrict phi optimizations after phi translations. But the current use of performedPhiTranslation only checked whether phi translation happened for the first iterator and missed cases where phi translations happens at subsequent iterators/upwards defs. This patch changes upward_defs_iteartor to take a pointer to a bool, so we can easily ensure the final value includes all visited defs, while still being able to conveniently use it with make_range & co.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha eef30334d1daaddf8b4e465be7c0f4aa4f98e208

[DSE] Precommit test case for invalid elimination of store in loop.

view details

Florian Hahn

commit sha f715d81c9df3fb3e047a54899fc749f57c84aeb5

[DSE] Only eliminate candidates that always store the same loc. AliasAnalysis/MemoryLocation does not account for loops. Two MemoryLocation can be must-overwrite, even if the first one writes multiple locations in a loop. This patch prevents removing such stores, by only considering candidates that are known to be loop invariant, or executed in the same BB. Currently the invariant check is quite conservative and only considers Alloca and Alloca-like instructions and arguments as invariant base pointers. It also considers GEPs with all constant indices and invariant bases as invariant. This can be improved in the future, but the current implementation has only minor impact on the total number of stores eliminated (25903 vs 26047 for the baseline). There are some 2-10% swings for some individual benchmarks. In roughly half of the cases, the number of stores removed increases actually, because we skip candidates that are unlikely to be valid candidates early.

view details

push time in a month

create barnchfhahn/llvm-project

branch : dse-mssa-compile-time

created branch time in a month

create barnchfhahn/llvm-project

branch : implied-cond-elimination

created branch time in a month

create barnchfhahn/llvm-project

branch : lv-memchecks-before-new

created branch time in a month

delete branch llvm/llvm-project

delete branch : lv-memchecks-before-new

delete time in a month

create barnchllvm/llvm-project

branch : lv-memchecks-before-new

created branch time in a month

create barnchfhahn/llvm-project

branch : loop-interchange-inbounds-version

created branch time in a month

create barnchfhahn/llvm-project

branch : laa-small-refactor

created branch time in a month

create barnchfhahn/llvm-project

branch : vp-disconnect-vpuser-vpvalue

created branch time in a month

create barnchfhahn/llvm-project

branch : scev-guard

created branch time in a month

create barnchfhahn/llvm-project

branch : constraint-elimination-stripped

created branch time in a month

create barnchfhahn/llvm-project

branch : dse-bfs

created branch time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha d85ac6d577ac5d4a7812e6cd3b0171f5e356c805

[DSE] Adjust coroutines test after e082dee2b588.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 3de9e3e493baed93e1aa0e99b04a0b11f370a939

[DSE] Precommit test case with loop carried dependence.

view details

Florian Hahn

commit sha e082dee2b5885bba65e20b22b088bcaca5546984

[DSE] Bail out on MemoryPhis when deleting stores at end of function. When deleting stores at the end of a function, we have to do PHI translation, otherwise we might miss reads in different iterations of a loop. See multiblock-loop-carried-dependence.ll for details. This fixes a mis-compile and surprisingly also increases the number of eliminated stores from 26047 to 26572 for MultiSource/SPEC2000/SPEC2006 on X86 with -O3 -flto. This is most likely because we save budget by not exploring through MemoryPhis, which are less likely to result in valid candidates for elimination. The issue was reported post-commit for fb109c42d91c.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha a874d63344093752c912d01de60211f65745ea6f

[Clang] Add option to allow marking pass-by-value args as noalias. After the recent discussion on cfe-dev 'Can indirect class parameters be noalias?' [1], it seems like using using noalias is problematic for current C++, but should be allowed for C-only code. This patch introduces a new option to let the user indicate that it is safe to mark indirect class parameters as noalias. Note that this also applies to external callers, e.g. it might not be safe to use this flag for C functions that are called by C++ functions. In targets that allocate indirect arguments in the called function, this enables more agressive optimizations with respect to memory operations and brings a ~1% - 2% codesize reduction for some programs. [1] : http://lists.llvm.org/pipermail/cfe-dev/2020-July/066353.html Reviewed By: rjmccall Differential Revision: https://reviews.llvm.org/D85473

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 8da6ae4ce1b686c5c13698e4c5ee937811fda6f7

Revert "[ConstraintSystem] Add helpers to deal with linear constraints." This reverts commit 3eb141e5078a0ce9d92eadc721bc49d214d23056. This uses __builtin_mul_overflow which is not available everywhere.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 3eb141e5078a0ce9d92eadc721bc49d214d23056

[ConstraintSystem] Add helpers to deal with linear constraints. This patch introduces a new ConstraintSystem class, that maintains a set of linear constraints and uses Fourier–Motzkin elimination to eliminate constraints to check if there are solutions for the system. It also adds a convert-constraint-log-to-z3.py script, which can parse the debug output of the constraint system and convert it to a python script that feeds the constraints into Z3 and checks if it produces the same result as the LLVM implementation. This is for verification purposes. Reviewed By: spatel Differential Revision: https://reviews.llvm.org/D84544

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha c0825fa5fc367bb7dc04a4b9dd4cc62abde04521

Revert "[ORC] Make MaterializationResponsibility immovable, pass by unique_ptr." This reverts commit c74900ca67241bf963b7a4cfa1fae8eadf6bb8cd. This appears to be breaking some builds on macOS and has been causing build failures on Green Dragon (see below). I am reverting this for now, to unblock testing on Green Dragon. http://green.lab.llvm.org/green/job/clang-stage1-cmake-RA-incremental/18144/console [65/187] /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ -DBUILD_EXAMPLES -DGTEST_HAS_RTTI=0 -D_DEBUG -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Iexamples/ThinLtoJIT -I/Users/buildslave/jenkins/workspace/clang-stage1-cmake-RA-incremental/llvm-project/llvm/examples/ThinLtoJIT -Iinclude -I/Users/buildslave/jenkins/workspace/clang-stage1-cmake-RA-incremental/llvm-project/llvm/include -fPIC -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wstring-conversion -fdiagnostics-color -O3 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.9 -fno-exceptions -fno-rtti -UNDEBUG -std=c++14 -MD -MT examples/ThinLtoJIT/CMakeFiles/ThinLtoJIT.dir/ThinLtoDiscoveryThread.cpp.o -MF examples/ThinLtoJIT/CMakeFiles/ThinLtoJIT.dir/ThinLtoDiscoveryThread.cpp.o.d -o examples/ThinLtoJIT/CMakeFiles/ThinLtoJIT.dir/ThinLtoDiscoveryThread.cpp.o -c /Users/buildslave/jenkins/workspace/clang-stage1-cmake-RA-incremental/llvm-project/llvm/examples/ThinLtoJIT/ThinLtoDiscoveryThread.cpp FAILED: examples/ThinLtoJIT/CMakeFiles/ThinLtoJIT.dir/ThinLtoDiscoveryThread.cpp.o /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ -DBUILD_EXAMPLES -DGTEST_HAS_RTTI=0 -D_DEBUG -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Iexamples/ThinLtoJIT -I/Users/buildslave/jenkins/workspace/clang-stage1-cmake-RA-incremental/llvm-project/llvm/examples/ThinLtoJIT -Iinclude -I/Users/buildslave/jenkins/workspace/clang-stage1-cmake-RA-incremental/llvm-project/llvm/include -fPIC -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wstring-conversion -fdiagnostics-color -O3 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.9 -fno-exceptions -fno-rtti -UNDEBUG -std=c++14 -MD -MT examples/ThinLtoJIT/CMakeFiles/ThinLtoJIT.dir/ThinLtoDiscoveryThread.cpp.o -MF examples/ThinLtoJIT/CMakeFiles/ThinLtoJIT.dir/ThinLtoDiscoveryThread.cpp.o.d -o examples/ThinLtoJIT/CMakeFiles/ThinLtoJIT.dir/ThinLtoDiscoveryThread.cpp.o -c /Users/buildslave/jenkins/workspace/clang-stage1-cmake-RA-incremental/llvm-project/llvm/examples/ThinLtoJIT/ThinLtoDiscoveryThread.cpp In file included from /Users/buildslave/jenkins/workspace/clang-stage1-cmake-RA-incremental/llvm-project/llvm/examples/ThinLtoJIT/ThinLtoDiscoveryThread.cpp:7: /Users/buildslave/jenkins/workspace/clang-stage1-cmake-RA-incremental/llvm-project/llvm/examples/ThinLtoJIT/ThinLtoInstrumentationLayer.h:37:68: error: non-virtual member function marked 'override' hides virtual member function void emit(MaterializationResponsibility R, ThreadSafeModule TSM) override; ^ /Users/buildslave/jenkins/workspace/clang-stage1-cmake-RA-incremental/llvm-project/llvm/include/llvm/ExecutionEngine/Orc/Layer.h:103:16: note: hidden overloaded virtual function 'llvm::orc::IRLayer::emit' declared here: type mismatch at 1st parameter ('std::unique_ptr<MaterializationResponsibility>' vs 'llvm::orc::MaterializationResponsibility') virtual void emit(std::unique_ptr<MaterializationResponsibility> R, ^ 1 error generated.

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha fb109c42d91c30c8c7497ef1fd7aff6f2969c6e7

[DSE] Switch to MemorySSA-backed DSE by default. The tests have been updated and I plan to move them from the MSSA directory up. Some end-to-end tests needed small adjustments. One difference to the legacy DSE is that legacy DSE also deletes trivially dead instructions that are unrelated to memory operations. Because MemorySSA-backed DSE just walks the MemorySSA, we only visit/check memory instructions. But removing unrelated dead instructions is not really DSE's job and other passes will clean up. One noteworthy change is in llvm/test/Transforms/Coroutines/ArgAddr.ll, but I think this comes down to legacy DSE not handling instructions that may throw correctly in that case. To cover this with MemorySSA-backed DSE, we need an update to llvm.coro.begin to treat it's return value to belong to the same underlying object as the passed pointer. There are some minor cases MemorySSA-backed DSE currently misses, e.g. related to atomic operations, but I think those can be implemented after the switch. This has been discussed on llvm-dev: http://lists.llvm.org/pipermail/llvm-dev/2020-August/144417.html For the MultiSource/SPEC2000/SPEC2006 the number of eliminated stores goes from ~17500 (legayc DSE) to ~26300 (MemorySSA-backed). More numbers and details in the thread on llvm-dev. Impact on CTMark: ``` Legacy Pass Manager exec instrs size-text O3 + 0.60% - 0.27% ReleaseThinLTO + 1.00% - 0.42% ReleaseLTO-g. + 0.77% - 0.33% RelThinLTO (link only) + 0.87% - 0.42% RelLO-g (link only) + 0.78% - 0.33% ``` http://llvm-compile-time-tracker.com/compare.php?from=3f22e96d95c71ded906c67067d75278efb0a2525&to=ae8be4642533ff03803967ee9d7017c0d73b0ee0&stat=instructions ``` New Pass Manager exec instrs. size-text O3 + 0.95% - 0.25% ReleaseThinLTO + 1.34% - 0.41% ReleaseLTO-g. + 1.71% - 0.35% RelThinLTO (link only) + 0.96% - 0.41% RelLO-g (link only) + 2.21% - 0.35% ``` http://195.201.131.214:8000/compare.php?from=3f22e96d95c71ded906c67067d75278efb0a2525&to=ae8be4642533ff03803967ee9d7017c0d73b0ee0&stat=instructions Reviewed By: asbirlea, xbolva00, nikic Differential Revision: https://reviews.llvm.org/D87163

view details

push time in a month

delete branch fhahn/llvm-project

delete branch : perf/dt-use-smallvector

delete time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha a5ec99da6ea75a013ed201eb9c80066bd6f4131d

[DSE] Support eliminating memcpy.inline. MemoryLocation has been taught about memcpy.inline, which means we can get the memory locations read and written by it. This means DSE can handle memcpy.inline

view details

push time in a month

push eventfhahn/llvm-project

Florian Hahn

commit sha c410fbe9518f62d96dac34a4c6c96c2c9fd48bd3

Revert "[MemDep] Use BatchAA when computing pointer dependencies" This reverts commit 3a54b6a4b71c21cf3bab4f132cbc2904fb9d997e. Revert "Handle masked loads and stores in MemoryLocation/Dependence" This reverts commit 055d2095898dfbb58b71322c02fbba7e71e8f76a.

view details

Florian Hahn

commit sha b31f39fa739f804749ff573e2c8c4a31ce62cddc

[DSE] Switch to MemorySSA-backed DSE by default.

view details

Florian Hahn

commit sha adfd684c0c6984a4287bec3711acdc78b0128569

[DSE,MemorySSA] Use optimized access, if available.

view details

Florian Hahn

commit sha ad0eba2e8e73a6aeff18e89d44e3585717c4f018

[Passes] Move ADCE before DSE & LICM. The adjustment seems to have very little impact on optimizations. The only binary change with -O3 MultiSource/SPEC2000/SPEC2006 on X86 is in consumer-typeset and the size there actually decreases by -0.1%, with not significant changes in the stats. On its own, it is mildly positive in terms of compile-time, most likely due to LICM & DSE having to process slightly less instructions. It should also be unlikely that DSE/LICM make new code dead. http://llvm-compile-time-tracker.com/compare.php?from=df63eedef64d715ce1f31843f7de9c11fe1e597f&to=e3bdfcf94a9eeae6e006d010464f0c1b3550577d&stat=instructions With DSE & MemorySSA, it gives some nice compile-time improvements, due to the fact that DSE can re-use the PDT from ADCE, if it does not make any changes: http://llvm-compile-time-tracker.com/compare.php?from=15fdd6cd7c24c745df1bb419e72ff66fd138aa7e&to=481f494515fc89cb7caea8d862e40f2c910dc994&stat=instructions Differential Revision: https://reviews.llvm.org/D87322

view details

Florian Hahn

commit sha c23eefa765ec8cc4e0468516bd0da54bb02095e3

[DSE,MemorySSA] Handle LoadInst explicitly in isReadClobber.

view details

push time in a month

push eventfhahn/llvm-project

Christian Sigg

commit sha 3a577f544618d9713aca5052e55143142d23f427

Rename MemRefDescriptor::getElementType() to MemRefDescriptor::getElementPtrType(). Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D87284

view details

Mirko Brkusanin

commit sha 43af2a6faa272565cde4e3eec7dfeac593d29701

[AMDGPU] Workaround for LDS Misalignment bug on GFX10 Add subtarget feature check to avoid using ds_read/write_b96/128 with too low alignment if a bug is present on that specific hardware. Add this "feature" to GFX 10.1.1 as it is also affected. Add global-isel test.

view details

Sjoerd Meijer

commit sha 8cb8cea1bd7f03330fc310b8993a3be89da90c1d

[ARM] Fixup of a few test cases. NFC. After changing the semantics of get.active.lane.mask, I missed a few tests that should use now the tripcount instead of the backedge taken count.

view details

Florian Hahn

commit sha 3a61bfb027a623807a30adb496ab62203c9b4ba5

[DomTree] Use SmallVector<DomTreeNodeBase *, 4> instead of std::vector. Currentl DomTreeNodeBase is using std::vectot to store it's children. Using SmallVector should be more efficient in terms of compile-time. A size of 4 seems to be the sweet-spot in terms of compile-time, according to http://llvm-compile-time-tracker.com/compare.php?from=9933188c90615c9c264ebb69117f09726e909a25&to=d7a801d027648877b20f0e00e822a7a64c58d976&stat=instructions This results in the following geomean improvements ``` geomean insts max rss O3 -0.31 % +0.02 % ReleaseThinLTO -0.35 % -0.12 % ReleaseLTO -0.28 % -0.12 % O0 -0.06 % -0.02 % NewPM O3 -0.36 % +0.05 % ReleaseThinLTO (link only) -0.44 % -0.10 % ReleaseLTO-g (link only): -0.32 % -0.03 % ``` I am not sure if there's any other benefits of using std::vector over SmallVector. Reviewed By: kuhar, asbirlea Differential Revision: https://reviews.llvm.org/D87319

view details

Vitaly Buka

commit sha b5bc56da8aa23dc57db9d286b0591dbcf9b1bdd3

[NFC][Asan] Fit ChunkHeader into redzone In code as-is min redzone and ChunkHeader are 16 byte. This patch just makes sure that redzone is calculated correctly if we extend ChunkHeader.

view details

Simon Pilgrim

commit sha 24ecfdac7b7d195795b6cb0e373cba8bfa7911f4

[APFloat] Fix uninitialized variable in IEEEFloat constructors Some constructors of IEEEFloat do not initialize member variable exponent. Fix it by initializing exponent with the following values: For NaNs, the `exponent` is `maxExponent+1`. For Infinities, the `exponent` is `maxExponent+1`. For Zeroes, the `exponent` is `maxExponent-1`. Patch by: @nullptr.cpp (Yang Fan) Differential Revision: https://reviews.llvm.org/D86997

view details

Simon Pilgrim

commit sha f16b2d83154aed71aaf9a0717fbb0199d027f312

ARMTargetParser.cpp - use auto const references in for range loops. NFCI. Fix static analysis warnings about unnecessary copies.

view details

Simon Pilgrim

commit sha 455cce3e216ba3cac0844b4ee9cf85791c1ac046

TrigramIndex.cpp - remove unnecessary includes. NFCI. TrigramIndex.h already includes most of these.

view details

Juneyoung Lee

commit sha 25ce1e0497259711836f949005297125e92a6e93

[ValueTracking] Add UndefOrPoison/Poison-only version of relevant functions This patch adds isGuaranteedNotToBePoison and programUndefinedIfUndefOrPoison. isGuaranteedNotToBePoison will be used at D75808. The latter function is used at isGuaranteedNotToBePoison. Reviewed By: nikic Differential Revision: https://reviews.llvm.org/D84242

view details

Irina Dobrescu

commit sha 0fd425af071a9bc5c0891a4db09f4d9a466b7be9

[flang]Add Semantic Checks for OpenMP Allocate Clause Reviewed By: kiranchandramohan, clementval, kiranktp, raghavendhra Differential Revision: https://reviews.llvm.org/D86051

view details

Juneyoung Lee

commit sha 36c8621638d18c830efe2c6a2a6d0a0338b0f79d

[BuildLibCalls] Add more noundef to library functions This patch follows D85345 and adds more noundef attributes to return values/arguments of library functions that are mostly about accessing the file system or processes. A few functions like `chmod` or `times` use typedef `mode_t` and `clock_t`. They are neither struct nor union, so they cannot contain undef even if they're lowered to iN in IR. So, it is fine to add noundef to them. - clock_t's actual type is size_t (C17, 7.27.1.3), so it isn't struct or union. - For mode_t, either int or long is used in practice because programmers use bit manipulation. So, I think it is okay that it's never aggregate in practice. After this patch, the remaining library functions are those that eagerly participate in optimizations: they can be removed, reordered, or introduced by a transformation from primitive IR operations. For them, a few testings is needed, since it may not be valid to add noundef anymore even if C standard says it's okay. Reviewed By: jdoerfert Differential Revision: https://reviews.llvm.org/D85894

view details

David Stenberg

commit sha 48fc781438767bd8337facf2e232c695b0426fb4

[UnifyFunctionExitNodes] Fix Modified status for unreachable blocks If a function had at most one return block, the pass would return false regardless if an unified unreachable block was created. This patch fixes that by refactoring runOnFunction into two separate helper functions for handling the unreachable blocks respectively the return blocks, as suggested by @bjope in a review comment. This was caught using the check introduced by D80916. Reviewed By: serge-sans-paille Differential Revision: https://reviews.llvm.org/D85818

view details

Jakub Lichman

commit sha edf244217a48b91c8e9c860848885106fbcc5c4b

[mlir][Linalg] Integration tests for convolutions added. This commit introduces end-to-end integration tests for convolutions that test multiple ways of ConvOps lowering. Differential Revision: https://reviews.llvm.org/D87277

view details

Diana Picus

commit sha d4b88ac1658d681e143482336cac27c6a74b8b24

[cmake] Use absolute paths for modules search For out of tree builds, the user generally needs to specify LLVM_DIR and MLIR_DIR on the command line so that the correct LLVM and MLIR installations are picked up. If the provided paths are absolute, everything works fine, however for buildbots it is customary to work with relative paths, and that makes it difficult for CMake to find the right modules to include. This patch changes CMakeLists.txt to convert LLVM_DIR and MLIR_DIR to absolute paths before adding them to CMAKE_MODULE_PATH. The inputs are assumed to be relative to the source directory (llvm-project/flang). Differential Revision: https://reviews.llvm.org/D87083

view details

Xing GUO

commit sha 25f3cc0ced1759af1911c2446ac40fab4f5e5571

[elf2yaml] Fix dumping a debug section whose name is not recognized. If the debug section's name isn't recognized, it should be dumped as a raw content section. Reviewed By: jhenderson, grimar Differential Revision: https://reviews.llvm.org/D87346

view details

Simon Pilgrim

commit sha 1eaf7babf2dcc3ab8fb429171c991556ffa98291

APInt.h - return directly from clearUnusedBits in single word cases. NFCI. Consistently use the same pattern of returning *this from the clearUnusedBits() call to allow us to early out from the isSingleWord() path and avoid an else statement.

view details

Simon Pilgrim

commit sha d816499f95d673bbad297d0231cbeaf5efbbc5de

[KnownBits] Move SelectionDAG::computeKnownBits ISD::ABS handling to KnownBits::abs Move the ISD::ABS handling to a KnownBits::abs handler, to simplify future implementations in ValueTracking/GlobalISel.

view details

Ronak Chauhan

commit sha f078577f31cc96b6e8a064f628f81a376f21e2e2

Revert "[AMDGPU] Support disassembly for AMDGPU kernel descriptors" This reverts commit 487a80531006add8102d50dbcce4b6fd729ab1f6. Tests fail on big endian machines.

view details

Simon Pilgrim

commit sha b29bdab8c76dbeda7786ef8e0d1bf58376955795

CommandLine.h - use auto const reference in ValuesClass::apply for range loop. NFCI.

view details

Denis Antrushin

commit sha 4358fa782e3def5176f6e70c72de8e65702aeb0f

[Statepoints] Update DAG root after emitting statepoint. Since we always generate CopyToRegs for statepoint results, we must update DAG root after emitting statepoint, so that these copies are scheduled before any possible local uses. Note: getControlRoot() flushes all PendingExports, not only those we generates for relocates. If that'll become a problem, we can change it to flushing relocate exports only. Reviewed By: reames Differential Revision: https://reviews.llvm.org/D87251

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 9969c317ff0877ed6155043422c70e1d4c028a35

[DSE,MemorySSA] Handle atomic stores explicitly in isReadClobber. Atomic stores are modeled as MemoryDef to model the fact that they may not be reordered, depending on the ordering constraints. Atomic stores that are monotonic or weaker do not limit re-ordering, so we do not have to treat them as potential read clobbers. Note that llvm/test/Transforms/DeadStoreElimination/MSSA/atomic.ll already contains a set of negative test cases. Reviewed By: asbirlea Differential Revision: https://reviews.llvm.org/D87386

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 3a61bfb027a623807a30adb496ab62203c9b4ba5

[DomTree] Use SmallVector<DomTreeNodeBase *, 4> instead of std::vector. Currentl DomTreeNodeBase is using std::vectot to store it's children. Using SmallVector should be more efficient in terms of compile-time. A size of 4 seems to be the sweet-spot in terms of compile-time, according to http://llvm-compile-time-tracker.com/compare.php?from=9933188c90615c9c264ebb69117f09726e909a25&to=d7a801d027648877b20f0e00e822a7a64c58d976&stat=instructions This results in the following geomean improvements ``` geomean insts max rss O3 -0.31 % +0.02 % ReleaseThinLTO -0.35 % -0.12 % ReleaseLTO -0.28 % -0.12 % O0 -0.06 % -0.02 % NewPM O3 -0.36 % +0.05 % ReleaseThinLTO (link only) -0.44 % -0.10 % ReleaseLTO-g (link only): -0.32 % -0.03 % ``` I am not sure if there's any other benefits of using std::vector over SmallVector. Reviewed By: kuhar, asbirlea Differential Revision: https://reviews.llvm.org/D87319

view details

push time in a month

push eventfhahn/llvm-project

Ehsan Toosi

commit sha 4e9f4d0b9d1dbf2c1d3e389b870a16c3dbd5c302

[mlir] Fix bug in copy removal A crash could happen due to copy removal. The bug is fixed and two more test cases are added. Differential Revision: https://reviews.llvm.org/D87128

view details

Raul Tambre

commit sha 86bd8f82cc74725a08a40efe176d3d6b9c9cef92

[CMake] Remove dead FindPythonInterp code LLVM has bumped the minimum required CMake version to 3.13.4, so this has become dead code. Reviewed By: #libc, ldionne Differential Revision: https://reviews.llvm.org/D87189

view details

Denys Petrov

commit sha e67405141836fcd88183863758eeb42f32e847a6

[analyzer] [NFC] Introduce refactoring of PthreadLockChecker Change capitalization of some names due to LLVM naming rules. Change names of some variables to make them more speaking. Rework similar bug reports into one common function. Prepare code for the next patches to reduce unrelated changes. Differential Revision: https://reviews.llvm.org/D87138

view details

Sanjay Patel

commit sha 4964d75d7078b932ac6b17c1990adaa6eada75c1

[InstCombine] add bitwise logic fold tests for D86395; NFC

view details

Frank Derry Wanye

commit sha 156b127945a8c923d141e608b7380427da024376

Add a new altera check for structure packing and alignment. The altera struct pack align lint check finds structs that are inefficiently packed or aligned and recommends packing/aligning of the structs using the packed and aligned attributes as needed in a warning.

view details

Haojian Wu

commit sha 9c9974c3ccb6468cc83f759240293538cf123fcd

[clang] Limit the maximum level of fold-expr expansion. Introduce a new diagnostic, and respect the bracket-depth (256) by default. Differential Revision: https://reviews.llvm.org/D86936

view details

Benjamin Kramer

commit sha 51d30c3429fa0f46bf8c0e4a38840952c11be4f9

[mlir][VectorOps] Fix more GCC5 weirdness VectorToSCF.cpp:515:47: error: specialization of 'template<class TransferOpTy> mlir::LogicalResult mlir::VectorTransferRewriter<TransferOpTy>::matchAndRewrite(mlir::Operation*, mlir::PatternRewriter&) const' in different namespace [-fpermissive]

view details

Sam Parker

commit sha 94cfbef0a74ec3e5490878dc417fea5ecfcf2a6a

[NFC][ARM] Precommit test

view details

Florian Hahn

commit sha c7b7c32f4a25d15e992215c8524871bef47d959b

[DSE,MemorySSA] Increase walker limit a bit. This slightly bumps the walker limit so that it covers more cases while not increasing compile-time too much: http://llvm-compile-time-tracker.com/compare.php?from=0fc1c2b51ba0cfb9145139af35be638333865251&to=91144a50ea4fa82c0c877e77784f60371640b263&stat=instructions

view details

Nico Weber

commit sha e09e1d97c112ef9488b2f88db560d3d459c0652e

[gn build] (manually) port 156b127945a8

view details

Nico Weber

commit sha 9933188c90615c9c264ebb69117f09726e909a25

StructPackAlignCheck: Fix a -Winconsistent-missing-override warning

view details

Hans Wennborg

commit sha 2d9d270e77918dfc19ad9b3150ee7d40eeb8ca79

Revert 3e782bf809 "[Sema][MSVC] warn at dynamic_cast when /GR- is given" This caused more warnings than expected, see https://crbug.com/1126019 Also reverts the follow-up 7907e5516. > Differential Revision: https://reviews.llvm.org/D86369

view details

Haojian Wu

commit sha 32ae37b038b16a1ff9c81428ae4f003377439a22

[clang-tidy] Fix dynamic build failures after 156b127945a8c923d141e608b7380427da024376

view details

Jonas Paulsson

commit sha 6dc3e22b575267d2ede36f741bb9eb2455f36cff

[DAGTypeLegalizer] Handle ZERO_EXTEND of promoted type in WidenVecRes_Convert. On SystemZ, a ZERO_EXTEND of an i1 vector handled by WidenVecRes_Convert() always ended up being scalarized, because the type action of the input is promotion which was previously an unhandled case in this method. This fixes https://bugs.llvm.org/show_bug.cgi?id=47132. Differential Revision: https://reviews.llvm.org/D86268 Patch by Eli Friedman. Review: Ulrich Weigand

view details

Louis Dionne

commit sha 6454140ab34cb29cc0b9de4f1e80199d717f1a97

[libc++] Make sure we always print all available features Previously, we'd only print the features added through the new config, however printing all the features is important for debugging purposes.

view details

Louis Dionne

commit sha c2f6a0012882ba9b39ccee53f3d7f4f1aedf2181

[libc++] Allow overriding the cached value of LIBCXX_TEST_CONFIG

view details

mydeveloperday

commit sha c81dd3d159ab03d46e4280c458d3c29e56648218

[clang-format] Handle shifts within conditions In some situation shifts can be treated as a template, and is thus formatted as one. So, by doing a couple extra checks to assure that the condition doesn't contain a template, and is in fact a bit shift should solve this problem. This is a fix for [[ https://bugs.llvm.org/show_bug.cgi?id=46969 | bug 46969 ]] Reviewed By: MyDeveloperDay Patch By: Saldivarcher Differential Revision: https://reviews.llvm.org/D86581

view details

Ronak Chauhan

commit sha 487a80531006add8102d50dbcce4b6fd729ab1f6

[AMDGPU] Support disassembly for AMDGPU kernel descriptors Decode AMDGPU Kernel descriptors as assembler directives. Reviewed By: scott.linder, jhenderson, kzhuravl Differential Revision: https://reviews.llvm.org/D80713

view details

Heejin Ahn

commit sha 71133e8b5bceaf68a2cee59af371df570a1aed79

[clang-tidy] Fix linking for FrontendOpenMP Without this, builds with `-DBUILD_SHARED_LIBS=ON` fail.

view details

Lubomir Litchev

commit sha e2394245eb28695d5eed5d7c015e99141993c723

Add an option for unrolling loops up to a factor. Currently, there is no option to allow for unrolling a loop up to a specific factor (specified by the user). The code for doing that is there and there are benefits when unrolling is done to smaller loops (smaller than the factor specified). Reviewed By: bondhugula Differential Revision: https://reviews.llvm.org/D87111

view details

push time in a month

push eventllvm/llvm-project

Florian Hahn

commit sha 2bcc4db761768f1b7431237920f26360549ca268

[EarlyCSE] Explicitly require AAResultsWrapperPass. The MemorySSAWrapperPass depends on AAResultsWrapperPass and if MemorySSA is preserved but AAResultsWrapperPass is not, this could lead to a crash when updating the last user of the MemorySSAWrapperPass. Alternatively AAResultsWrapperPass could be marked preserved by GVN, but I am not sure if that would be safe. I am not sure what is required in order to preserve AAResultsWrapperPass. At the moment, it seems like a couple of passes that do similar transforms to GVN are preserving it. Reviewed By: asbirlea Differential Revision: https://reviews.llvm.org/D87137

view details

push time in a month

more