summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Fixup load pointer type in testcaseupstream/users/koachan/sparc-prefer-rdpc-over-call-to-implement-getpcx-for-64-bit-targetKoakuma2024-01-142-2/+2
| | | | Created using spr 1.3.4
* Add nounwind to test casesKoakuma2024-01-142-22/+6
| | | | Created using spr 1.3.4
* Implement suggestions & clarify comment on RDPC emissionKoakuma2024-01-107-30/+131
|\ | | | | | | Created using spr 1.3.4
| * [𝘀𝗽𝗿] changes introduced through rebaseKoakuma2024-01-103-9/+8
| | | | | | | | | | | | Created using spr 1.3.4 [skip ci]
* | [𝘀𝗽𝗿] initial versionKoakuma2024-01-067-16/+72
|\| | | | | | | Created using spr 1.3.4
| * [𝘀𝗽𝗿] changes to main this commit is based onKoakuma2024-01-064-10/+21
|/ | | | | | Created using spr 1.3.4 [skip ci]
* [NFC] Fix typos in commentsPhoebe Wang2023-11-191-2/+2
|
* [clang] Remove unused selStructPtrTy in CGObjCGNU.cpp (NFC)Jie Fu2023-11-191-2/+0
| | | | | | | /llvm-project/clang/lib/CodeGen/CGObjCGNU.cpp:3674:15: error: variable 'selStructPtrTy' set but not used [-Werror,-Wunused-but-set-variable] llvm::Type *selStructPtrTy = SelectorTy; ^ 1 error generated.
* [clang] Remove ConstantAggregateBuilderBase::addBitCast (NFC)Youngsuk Kim2023-11-182-35/+24
| | | | | | | | * Replace all existing uses of ConstantAggregateBuilderBase::addBitCast, as they involve a no-op ptr-to-ptr bitcast * Remove method ConstantAggregateBuilderBase::addBitCast Opaque ptr cleanup effort (NFC)
* [DebugInfo][RemoveDIs] Support finding DPValues like dbg.values (#71952)Jeremy Morse2023-11-185-10/+167
| | | | | | | | | | This patch extends findDbgValue and friends to optionally fill out a vector of DPValue pointers, containing DPValues that refer to the sought Value. This will allow us to incrementally add instrumentation to other optimisation passes one-at-a-time, while un-instrumented passes will not (yet) update DPValues. Unit tests to check this behaves in the same way as dbg.values.
* Apply clang-tidy fixes for performance-unnecessary-value-param in ↵Mehdi Amini2023-11-181-8/+11
| | | | IRInterfaces.cpp (NFC)
* Apply clang-tidy fixes for misc-include-cleaner in IRInterfaces.cpp (NFC)Mehdi Amini2023-11-181-0/+10
|
* Apply clang-tidy fixes for readability-identifier-naming in IRCore.cpp (NFC)Mehdi Amini2023-11-181-3/+3
|
* Apply clang-tidy fixes for misc-include-cleaner in IRCore.cpp (NFC)Mehdi Amini2023-11-181-2/+26
|
* Apply clang-tidy fixes for llvm-else-after-return in IRCore.cpp (NFC)Mehdi Amini2023-11-181-2/+1
|
* Apply clang-tidy fixes for performance-unnecessary-value-param in ↵Mehdi Amini2023-11-181-1/+1
| | | | IRAttributes.cpp (NFC)
* [CGObjCMac] Replace calls to ConstantAggregateBuilderBase::addBitCast (NFC)Youngsuk Kim2023-11-181-17/+11
| | | | | | | Replace calls to `ConstantAggregateBuilderBase::addBitCast` that involve a no-op ptr-to-ptr bitcast. Opaque ptr cleanup effort (NFC)
* Revert rGbfbfd1caa4da "[X86] combineLoad - try to reuse existing constant ↵Simon Pilgrim2023-11-189-1751/+1781
| | | | | | pool entries for smaller vector constant data" Investigating reports of this causing infinite loops
* [DAG] Fix ShrinkDemandedOp doxygen description to match behaviour. NFC.Simon Pilgrim2023-11-182-5/+7
| | | | ShrinkDemandedOp checks for both isTruncateFree AND isZExtFree but extends with ANY_EXTEND.
* [LV] Don't crash on vector masks during scalar VPReductionRecipe::exec.Florian Hahn2023-11-182-1/+172
| | | | | | | | VPReductionRecipe may be executed for scalar VFs. Make sure to access part 0 of the condition, as it could be an active-lane-mask, which is a vector <1 x i1> Fixes https://github.com/llvm/llvm-project/issues/72720.
* [LV] Retain mask-reversal comment as suggested after e5e71af.Florian Hahn2023-11-181-1/+4
| | | | Address post-commit comment to retain comment.
* [RISCV][GISel] Instruction selection for G_JUMP_TABLE and G_BRJT. (#71987)Craig Topper2023-11-187-0/+1257
|
* [RISCV][GISel] Add s32 G_SELECT instruction select test for RV64. NFCCraig Topper2023-11-181-0/+30
|
* [Github] Add build Flang docs in CI if autogenerated files change (#72721)Aiden Grossman2023-11-181-0/+3
| | | | | Currently, when changes are made to the tablegen files that build the docs, the docs build is not tested. This should rarely cause breakages, but it's cheap to test and there isn't a major reason not to.
* [AArch64] Add some testing for BE shuffles. NFCDavid Green2023-11-181-152/+452
|
* [CGObjCGNU] Remove unneeded method 'CGObjCGNUstep2::EnforceType' (NFC)Youngsuk Kim2023-11-181-8/+2
| | | | | | | Method CGObjCGNUstep2::EnforceType is called from 2 call-sites to perform bitcasts which are no-ops given that opaque pointers are enabled in LLVM. Remove the method. Opaque ptr cleanup effort (NFC).
* [bazel] Port dc4786b4877d67d73d3892c45baf6811af0e6f57Benjamin Kramer2023-11-181-0/+1
|
* [mlir][affine] Remove unused capturesBenjamin Kramer2023-11-181-7/+3
|
* [RISCV][GISel] Remove the rv32/rv64 subdirectories for legalizer tests. NFCCraig Topper2023-11-1886-0/+0
| | | | | Add -rv32 -rv64 as suffix to test name. First step towards trying to merge the content of these tests.
* [MC] Remove duplicate Contents field from MCLEBFragment.Craig Topper2023-11-181-3/+1
| | | | | | | There's already a Contents field in the MCEncodedFragmentWithFixups base class. The Contents field in MCLEBFragment is private and there is no accessor for it. It is initialized in the constructor, but that should probably initialize the base class version.
* [mlir][affine] remove divide zero check when simplifer affineMap (#64622) ↵long.chen2023-11-198-112/+255
| | | | | | | | | | | (#68519) When performing constant folding on the affineApplyOp, there is a division of 0 in the affine map. [related issue](https://github.com/llvm/llvm-project/issues/64622) --------- Co-authored-by: Javier Setoain <jsetoain@users.noreply.github.com>
* [SelectionDAG] Fix crash for salvaging with indirect debug values (#72645)David Stenberg2023-11-182-0/+107
| | | | | | | | | | | | | | | | | | This is a follow-up to #68981, and fix for #72630, #72447. We may end up in SelectionDAG::salvageDebugInfo() with indirect debug values, and attempting to salvage ADD nodes with non-constant RHS would lead us to try to turn those indirect debug values variadic, which is not allowed. This triggered the following assert in the SDDbgValue constructor: Assertion `!(IsVariadic && IsIndirect)' failed. This also adds a lit test for salvaging when having an indirect debug value and constant RHS, as there seems like there was no such lit test. However, I am not sure if the use of the stack_value operation is correct in that case (which is existing behavior before #68981), but that at least documents the current behavior.
* [LLVM][DWARF] Add support for monolithic types in .debug_names (#70515)Alexander Yermolovich2023-11-1817-161/+536
| | | | | | Enable Type Units with DWARF5 accelerator tables for monolithic DWARF. Implementation relies on linker to tombstone offset in LocalTU list to -1 when it deduplciates type units using COMDAT.
* [clang-tidy] Improve alternate snake case warnings (#71385)J.C. Moyer2023-11-184-4/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Improves the accuracy of `readability-identifier-naming` for cases `Camel_Snake_Case` and `camel_Snake_Back`. Prior to this commit, these cases matched identifiers with **only** a leading upper case letter or leading lower case letter respectively. Now, uppercase letters can only appear at the start of an identifier or directly following an underscore. --- Currently, the regex for `Camel_Snake_Case` matches any identifier that starts with a capital letter: ``` ^[A-Z]([a-z0-9]*(_[A-Z])?)* ^^^^^^^^^-- underscore + capital letter after the first capital is optional ``` This means that `Camel_Snake_Case` matches other cases - in particular `CamelCase` and `Leading_upper_snake_case` - which causes clang-tidy to sometimes not flag incorrect casing. It also matches `UPPER_CASE`, but I think it's reasonable to consider this a subset of `Camel_Snake_Case` since some users may prefer e.g. `XML_Parser` to `Xml_Parser`. It's really easy to accidentally type an identifier that clang-tidy doesn't catch; all you have to do is omit an underscore or forget to capitalize a letter. The same problem also applies to `camel_Snake_Back` except that any identifier starting with a lower case letter matches, so I went ahead and adjusted its regex too. Fixing it also uncovered a minor error in an existing test.
* [CodeGen][DebugInfo] Add missing debug info for jump table BB (#71021)HaohaiWen2023-11-185-17/+24
| | | | | | | visitJumpTable is called on FinishBasicBlock. At that time, getCurSDLoc will always return SDLoc without DebugLoc since CurInst was set to nullptr after visiting each instruction. This patch passes SDLoc to buildJumpTable when visiting SwitchInst so that visitJumpTable can use it later.
* [llvm][RelLookupTableConverter] Remove no-op ptr-to-ptr bitcast (NFC)Youngsuk Kim2023-11-181-2/+1
| | | | Opaque ptr cleanup effort (NFC).
* [CGOpenMPRuntimeGPU] Replace unneeded use of ↵Youngsuk Kim2023-11-181-3/+1
| | | | | | CreatePointerBitCastOrAddrSpaceCast (NFC) Opaque ptr cleanup effort (NFC)
* [GreedyRA] Improve RA for nested loop induction variables (#72093)David Green2023-11-185-25/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Imagine a loop of the form: ``` preheader: %r = def header: bcc latch, inner inner1: .. inner2: b latch latch: %r = subs %r bcc header ``` It can be possible for code to spend a decent amount of time in the header<->latch loop, not going into the inner part of the loop as much. The greedy register allocator can prefer to spill _around_ %r though, adding spills around the subs in the loop, which can be very detrimental for performance. (The case I am looking at is actually a very deeply nested set of loops that repeat the header<->latch pattern at multiple different levels). The greedy RA will apply a preference to spill to the IV, as it is live through the header block. This patch attempts to add a heuristic to prevent that in this case for variables that look like IVs, in a similar regard to the extra spill weight that gets added to variables that look like IVs, that are expensive to spill. That will mean spills are more likely to be pushed into the inner blocks, where they are less likely to be executed and not as expensive as spills around the IV. This gives a 8% speedup in the exchange benchmark from spec2017 when compiled with flang-new, whilst importantly stabilising the scores to be less chaotic to other changes. Running ctmark showed no difference in the compile time. I've tried to run a range of benchmarking for performance, most of which were relatively flat not showing many large differences. One matrix multiply case improved 21.3% due to removing a cascading chains of spills, and some other knock-on effects happen which usually cause small differences in the scores.
* [Github] Print diff in code format helper (#72742)Aiden Grossman2023-11-181-0/+4
| | | | | | | | | | Currently, when the code format action fails, it leaves no log of the diff in the output within the action itself. This has caused confusion for some users of the action, especially when the comment becomes buried in a 100+ comment review and someone isn't super familiar with the inner workings of the CI. This patch prints the diff produced by the code formatter to stdout so that it is viewable by clicking on the failed action. This should have very little cost and make things slightly less confusing for those that run into this situation.
* Change libc++ builder group name to match what I am using in the infraeric2023-11-181-4/+7
| | | | | Also change over to using group names instead of specific runner names. This will prevent future downtime.
* [InstCombine] Infer shift flags with unknown shamt (#72535)Yingwei Zheng2023-11-1834-217/+204
| | | | | | | Alive2: https://alive2.llvm.org/ce/z/82Wr3q Related patch: https://github.com/llvm/llvm-project/commit/2dd52b4527667837cc525aa48435ab5cbfa30a0b
* [SimplifyCFG] Add optimization for switches of powers of two (#70977)Daniil2023-11-183-4/+431
| | | | | | Optimization reduces the range for switches whose cases are positive powers of two by replacing each case with count_trailing_zero(case). Resolves #70756
* [ELF] -r: rename orphan SHT_REL/SHT_RELA when the relocated input section is ↵Fangrui Song2023-11-173-5/+9
| | | | | | | | placed in an output section This ports https://reviews.llvm.org/D40652 (--emit-relocs) to -r and matches GNU ld. Close #67910
* Revert "[mlir][sparse] stress test BSR" (#72735)Mehdi Amini2023-11-171-178/+0
| | | | | Reverts llvm/llvm-project#72712 This causes timeouts on the bots.
* [clang-format][NFC] Remove a redundant isLiteral() callOwen Pan2023-11-171-3/+1
|
* [LV] Pre-committing tests for changing loop interleaving count computation ↵Nilanjana Basu2023-11-172-17/+344
| | | | | (#70272) Added tests for evaluating changes to loop interleaving count computation and for removing loop interleaving threshold in subsequent patches.
* [test][msan] Remove redundant --check-prefixesVitaly Buka2023-11-171-13/+13
|
* [RISCV][GISel] Allow G_SELECT to have s32 type on RV64.Craig Topper2023-11-177-72/+162
|
* [msan][aarch64] Improve argument classificationVitaly Buka2023-11-173-30/+46
| | | | | | | | | | Arm64 use multiple registers (varg slots) to pass arrays. Reviewers: kstoimenov, thurstond Reviewed By: thurstond Pull Request: https://github.com/llvm/llvm-project/pull/72728
* [msan][test] Add ptr test caseVitaly Buka2023-11-171-0/+3
|