- Dec 20, 2022
-
-
gonglingqin authored
Further, after MUL is decomposed, use ALSL instead of SLLI and ADD Differential Revision: https://reviews.llvm.org/D140282
-
Nikita Popov authored
One test case was testing the case where a bitcasted function pointer is passed to an X constraint. With opaque pointers, this is no longer a thing, and it gets treated the same way as a non-bitcasted function pointer. Per the comment, this is a desirable change.
-
Archibald Elliott authored
-
Nikita Popov authored
Nothing interesting, but required some fixups to MIR.
-
Nikita Popov authored
There is a minor change in register allocation in one test case, which doesn't have impact on codegen quality though. Probably due to differences in SCEVExpander behavior with opaque pointers.
-
Nikita Popov authored
And regenerate check lines.
-
Jessica Del authored
These tests show suboptimal code generation that will be improved by the changes in D140208
-
Archibald Elliott authored
This is a fairly large changeset, but it can be broken into a few pieces: - `llvm/Support/*TargetParser*` are all moved from the LLVM Support component into a new LLVM Component called "TargetParser". This potentially enables using tablegen to maintain this information, as is shown in https://reviews.llvm.org/D137517. This cannot currently be done, as llvm-tblgen relies on LLVM's Support component. - This also moves two files from Support which use and depend on information in the TargetParser: - `llvm/Support/Host.{h,cpp}` which contains functions for inspecting the current Host machine for info about it, primarily to support getting the host triple, but also for `-mcpu=native` support in e.g. Clang. This is fairly tightly intertwined with the information in `X86TargetParser.h`, so keeping them in the same component makes sense. - `llvm/ADT/Triple.h` and `llvm/Support/Triple.cpp`, which contains the target triple parser and representation. This is very intertwined with the Arm target parser, because the arm architecture version appears in canonical triples on arm platforms. - I moved the relevant unittests to their own directory. And so, we end up with a single component that has all the information about the following, which to me seems like a unified component: - Triples that LLVM Knows about - Architecture names and CPUs that LLVM knows about - CPU detection logic for LLVM Given this, I have also moved `RISCVISAInfo.h` into this component, as it seems to me to be part of that same set of functionality. If you get link errors in your components after this patch, you likely need to add TargetParser into LLVM_LINK_COMPONENTS in CMake. Differential Revision: https://reviews.llvm.org/D137838
-
Nikita Popov authored
-
Dmitry Preobrazhensky authored
Summary of changes: - Enable register tuples with 9, 10, 11 and 12 registers (https://reviews.llvm.org/D138205). - Small improvements and clarifications. - Correct typos.
-
Nikita Popov authored
-
Guillaume Chatelet authored
As discussed on the patch the Align type is probably not a good fit for linkers. This reverts commit cfe77f23.
-
Sebastian Neubauer authored
Using CMAKE_CFG_INTDIR in paths that are used in configure_file, resulted in a folder that is literally called '${CONFIGURATION}' for the multi-config ninja build. I think this is a regression from a while ago. Fix this by replacing CMAKE_CFG_INTDIR with '.'. We can only create one of the LLVMConfig.cmake files as the consuming CMake project can only import a single file. This creates LLVMConfig.cmake and others in the place where they were previously and where they are for a single-config build. Differential Revision: https://reviews.llvm.org/D139623 -
Timm Bäder authored
This reverts commit d20101db. Lifetime of the string is not what I thought it was it seems.
-
eopXD authored
Reviewed By: craig.topper Differential Revision: https://reviews.llvm.org/D139025
-
Timm Bäder authored
PathStorage is only used in one of the if branches, so doesn't need to be a std::optional anyway.
-
Archibald Elliott authored
This change is rather more invasive than intended. The main intention here is to make CommandLine.cpp not rely on llvm/Support/Host.h. Right now, this reliance is only in 3 superficial places: - Choosing how to expand response files (in two places) - Printing the default triple and current CPU in `--version` output. The built in version system has a method for adding "extra version printers", commonly used by several tools (such as llc) to report the registered targets in the built version of LLVM. It was reasonably easy to move the logic for printing the default triple and current CPU into a similar function, and register it with any relevant binaries. The incompatible change here is that now, even if LLVM_VERSION_PRINTER_SHOW_HOST_TARGET_INFO is defined, most binaries will no longer print out the default target triple and cpu when provided with `--version`, for instance llvm-as and llvm-dis. This breakage is intended, but the changes in this patch keep printing the default target and detected in `llc` and `opt` as these were remarked as important binaries in the LLVM install. The change to expanding response files may also be controversial, but I believe that these macros should correspond exactly to the host triple introspection used before. Differential Revision: https://reviews.llvm.org/D137837
-
Kadir Cetinkaya authored
Fixes https://github.com/llvm/llvm-project/issues/59541. Differential Revision: https://reviews.llvm.org/D140380
-
Piyou Chen authored
RVV intrinsic function has several policy variants. Include TU, TA, TAMU, TAMA, TUMU, TUMA, MU, MA, TUM, TAM Currently, the clang side enumerates these policies, but it's hard to add a new policy. This patch use structure to replace the origin policy enumeration, and enhance some policy transform logic. This is a clean-up job that will not affect the RVV intrinsic functionality and make sure riscv_vector_builtin_cg.inc is the same as the original one. Reviewed By: kito-cheng Differential Revision: https://reviews.llvm.org/D139995
-
Qiu Chaofan authored
-
Nikita Popov authored
During scalar promotion, if there are additional potentially-aliasing loads outside the promoted set, we can still perform a load-only promotion. As the stores are retained, any potentially-aliasing loads will still read the correct value. This increases the number of load promotions in llvm-test-suite by a factor of two: | Old | New licm.NumPromotionCandidates | 4448 | 6038 licm.NumLoadPromoted | 479 | 1069 licm.NumLoadStorePromoted | 1459 | 1459 Unfortunately, this does have some impact on compile-time: http://llvm-compile-time-tracker.com/compare.php?from=57f7f0d6cf0706a88e1ecb74f3d3e8891cceabfa&to=72b811738148aab399966a0435f13b695da1c1c8&stat=instructions In part this is because we now have less early bailouts from promotion, but also due to second order effects (e.g. for one case I looked at we spend more time in SLP now). Differential Revision: https://reviews.llvm.org/D133192 -
Muhammad Omair Javaid authored
This patch fixes a typo in test/CodeGen/c-strings.c. Test was failing on AArch64/Windows.
-
Haojian Wu authored
-
Ramkumar Ramachandra authored
This is part of an effort to migrate from llvm::Optional to std::optional. 22426110 changed the way mlir-tblgen generates .inc files, emitting std::optional when an Optional attribute is specified in a .td file. It also changed several .td files hard-coding llvm::Optional to use std::optional. However, the patch excluded a few .td files in SPIRV and Bufferization hard-coding llvm::Optional. This patch fixes that defect, and after this patch, references to llvm::Optional in .cpp and .h files can be replaced mechanically. See also: https://discourse.llvm.org/t/deprecating-llvm-optional-x-hasvalue-getvalue-getvalueor/63716 Signed-off-by:
Ramkumar Ramachandra <r@artagnon.com> Differential Revision: https://reviews.llvm.org/D140329
-
Jean Perier authored
Hlfir.designate was made to support substrings but so far substrings were not yet lowered to it. Implement support for them. Differential Revision: https://reviews.llvm.org/D140310
-
Carl Ritson authored
Accelerate finding the base class for a physical register by building a statically mapping table from physical registers to base classes using TableGen. Replace uses of SIRegisterInfo::getPhysRegClass with TargetRegisterInfo::getPhysRegBaseClass in order to use the computed table. Reviewed By: arsenm, foad Differential Revision: https://reviews.llvm.org/D139422
-
Carl Ritson authored
Allow targets to define a mapping from registers to register classes such that each register has exactly one base class. As registers may be in multiple register classes the base class is determined by the container class with the lowest BaseClassOrder. Only register classes with BaseClassOrder set are considered when determining the base classes. By default BaseClassOrder is unset in RegisterClass so no code is generated unless a target explicit defines one or more base register classes. Reviewed By: arsenm, foad Differential Revision: https://reviews.llvm.org/D139616
-
Sameer Sahasrabuddhe authored
This fixes the buildbot failure on reverse iteration: https://lab.llvm.org/buildbot/#/builders/54/builds/3034
-
Craig Topper authored
It's much more common to use a register class rather than a type. Add an additional i64 cast to the patterns where needed to avoid increasing isel table size.
-
Craig Topper authored
Missed this in the review of D139394. Not a functional issue because select only makes it to isel with XVentanaCondOps.
-
Craig Topper authored
-
Craig Topper authored
Removes some extra andi instructions.
-
Johannes Doerfert authored
-
Johannes Doerfert authored
With this patch we: - pick more sensible defaults for the number of teams, inspired by the old plugin, and configured via LIBOMPTARGET_AMDGPU_TEAMS_PER_CU. - check the input signal of a kernel launch late, after the queue lock was taken, to avoid a barrier packet more often. - copy the kernel arguments in one swoop into the appropriate memory. - manually specialize the callbacks to avoid potential indirect calls.
-
Luke Nicholson authored
21U is the default group size, which demonstrates ~15mb reduction in heap size for some highly fragmented heaps on Fuchsia, and a general 5mb savings when devices are under no load. Microbenchmarks show no performance regressions, but most of our benchmarks perform no significant mallocs. So we are choosing the default setting, and monitoring for potential performance issues. Reviewed By: Chia-hungDuan Differential Revision: https://reviews.llvm.org/D140311
-
Johannes Doerfert authored
This reverts commit 3b052558. This patch got reverted due to an unrelated memory leak that has been fixed.
-
Matt Arsenault authored
Stop trying to delete a select in one combine since it would be deleting the CSE'd instruction if that happened.
-
LLVM GN Syncbot authored
-
Sameer Sahasrabuddhe authored
Uniformity analysis is a generalization of divergence analysis to include irreducible control flow: 1. The proposed spec presents a notion of "maximal convergence" that captures the existing convention of converging threads at the headers of natual loops. 2. Maximal convergence is then extended to irreducible cycles. The identity of irreducible cycles is determined by the choices made in a depth-first traversal of the control flow graph. Uniformity analysis uses criteria that depend only on closed paths and not cycles, to determine maximal convergence. This makes it a conservative analysis that is independent of the effect of DFS on CycleInfo. 3. The analysis is implemented as a template that can be instantiated for both LLVM IR and Machine IR. Validation: - passes existing tests for divergence analysis - passes new tests with irreducible control flow - passes equivalent tests in MIR and GMIR Based on concepts originally outlined by Nicolai Haehnle <nicolai.haehnle@amd.com> With contributions from Ruiling Song <ruiling.song@amd.com> and Jay Foad <jay.foad@amd.com>. Support for GMIR and lit tests for GMIR/MIR added by Yashwant Singh <yashwant.singh@amd.com>. Differential Revision: https://reviews.llvm.org/D130746 -
Hanhan Wang authored
The pattern generalizes a tensor::UnPackOp into a sequence of tensor + Linalg ops, when the outer dims are all 1s. It uses the trick of rank-reduced tensor.extract_slice to get the tile; transpose the tile; extract sub tile for incomplete cases if needed; use tensor.insert_slice to insert it to the destination tensor. Reviewed By: tyb0807, chelini Differential Revision: https://reviews.llvm.org/D140254
-