- Sep 15, 2023
-
-
Kunwar Grover authored
The CMake file for IRDL was not generating documentation on the mlir website. This patch fixes this.
-
Rainer Orth authored
LLVM fails to build on 32-bit Solaris/SPARC: several programs fail to link due to undefined references to `__multi3`. This reference is from `lib/libLLVMScalarOpts.a(LoopStrengthReduce.cpp.o)`. However, This function exists neither in the 32-bit `libgcc.a` nor in `libclang_rt.builtins-sparc.a`. It's only defined in their 64-bit counterparts. The same issue affects several 32-bit targets, e.g. 32-bit PowerPC as described in Issue #54460. The fix is the same: inhibit the libcall for 32-bit compilations. This patch does just that, regenerating the affected testcases. It allows the build to complete. Tested on `sparc-sun-solaris2.11`.
-
Jonas Devlieghere authored
Add a configuration entry for whether LLDB was configured with wide character support in Editline and use it in a decorator to guard the UTF-8 prompt test.
-
Nikita Popov authored
Duplicate phi nodes were being directly removed, without invalidating MDA. This could result in a new phi node being allocated at the same address, incorrectly reusing a cache entry. Fix this by optionally allowing EliminateDuplicatePHINodes() to collect phi nodes to remove into a vector, which allows GVN to handle removal itself. Fixes https://github.com/llvm/llvm-project/issues/64598. Differential Revision: https://reviews.llvm.org/D158849
-
Wang Pengcheng authored
`VMCLR` and `VMSET` will be expanded before MC emitting, so we don't need them being in RISCVVPseudosTable.
-
Marc Auberer authored
This removes a oneUse check, that is actually unnecessary. Alive2: https://alive2.llvm.org/ce/z/qEkUEf Original patch: https://reviews.llvm.org/D159380
-
Cyndy Ishida authored
Both Swift & LLD use TextAPI reader/writer apis to interface with TBD files. Add doc strings to document what each API does. Also, add shortcut APIs for validating input is a TBD file. This reduces the differences between downstream and how tapi calls into these APIs.
-
Christopher Bate authored
This change refactors some of the utilities used to unroll larger vector computations into smaller vector computations. In fact, the indexing computations used here are rather generic and are useful in other dialects or downstream projects. Therefore, a utility for iterating over all possible tile offsets for a particular pair of static (shape, tiled shape) is introduced in IndexingUtils and replaces the existing computations in the vector unrolling transformations. This builds off of the refactoring of IndexingUtils introduced in 203fad47. Reviewed By: nicolasvasilache Differential Revision: https://reviews.llvm.org/D150000
-
Jakub Kuderski authored
This is plugged in as an alternative lowering path in the gpu to spirv dialect conversion. Add custom op builders for coop matrix ops to make the create functions nicer to work with and less error-prone. The latter is accomplished by following the op syntax and also requiring stride to be a constant op to avoid confusion around the order of arguments. The remaining lowering patterns will be added in a future patch.
-
Stella Laurenzo authored
Only construction and type casting are implemented. The method to create is explicitly named "unsafe" and the documentation calls out what the caller is responsible for. There really isn't a better way to do this and retain the power-user feature this represents.
-
Brad Smith authored
-
ChiaHungDuan authored
It uses `T max( std::initializer_list<T> ilist )` which may not be included in the build path in some build systems.
-
Eymen Ünay authored
Add support for static Arm relocations of R_ARM_MOVT_ABS and R_ARM_MOVW_ABS_NC which are emitted by movt and movw instructions. The implementation contains relocation fixup and its testing as well as its encode/decode functions for reading and writing immediate values together with its unittests.
-
Alexey Bataev authored
-
Yinying Li authored
**Dense** `lvlTypes = [ "dense", "dense" ]` to `map = (d0, d1) -> (d0 : dense, d1 : dense)` `lvlTypes = [ "dense", "dense" ], dimToLvl = affine_map<(i,j) -> (j,i)>` to `map = (d0, d1) -> (d1 : dense, d0 : dense)` **DCSR** `lvlTypes = [ "compressed", "compressed" ]` to `map = (d0, d1) -> (d0 : compressed, d1 : compressed)` **DCSC** `lvlTypes = [ "compressed", "compressed" ], dimToLvl = affine_map<(i,j) -> (j,i)>` to `map = (d0, d1) -> (d1 : compressed, d0 : compressed)` **Block Row** `lvlTypes = [ "compressed", "dense" ]` to `map = (d0, d1) -> (d0 : compressed, d1 : dense)` **Block Column** `lvlTypes = [ "compressed", "dense" ], dimToLvl = affine_map<(i,j) -> (j,i)>` to `map = (d0, d1) -> (d1 : compressed, d0 : dense)` This is an ongoing effort: #66146, #66309
-
Leonard Chan authored
Prior to this, we would check if the end of the allocator cache was located before the end of the chunk passed to the tls check. However, if the actual allocator cache comes after the end of the chunk, then the sub in the `end - params->allocator_caches[i]` bit overflows. Since the resulting type is an unsigned uptr, this is not UB, but if the signed result would be a negative value (ie. `end < params->allocator_caches[i]`) then this will actually result in a very large unsigned value much bigger than the compared `sizeof(AllocatorCache)` which will almost always be true. This can cause ScanRangeForPointers to accept incorrect values: a begin pointing to some address, and `params->allocator_caches[i]` pointing to some much larger address way past the end of the chunk which can result in a page fault/stack overflow. Differential Revision: https://reviews.llvm.org/D159518
-
Aart Bik authored
Rationale: Some compiler settings don't like the size_t vs uint64_t setup.
-
ChiaHungDuan authored
The fragmentation of secondary cache is the difference between mapped page size and the user request size
-
Daniil Dudkin authored
This patch is part of a larger initiative aimed at fixing floating-point `max` and `min` operations in MLIR: https://discourse.llvm.org/t/rfc-fix-floating-point-max-and-min-operations-in-mlir/72671. The commit addresses the task 1.4 of the RFC by adding LLVM lowering to the corresponding LLVM intrinsics. Please **note**: this PR is part of a stack of patches and depends on #66429.
-
Arthur Eubanks authored
Currently clang's medium code model treats all data as large, putting them in a large data section and using more expensive instruction sequences to access them. Following gcc's -mlarge-data-threshold, which allows putting data under a certain size in a normal data section as opposed to a large data section. This allows using cheaper code sequences to access some portion of data in the binary (which will be implemented in LLVM in a future patch). And under the medium codel mode, only put data above the large data threshold into large data sections, not all data. Reviewed By: MaskRay, rnk Differential Revision: https://reviews.llvm.org/D149288
-
Fabian Mora authored
This patch adds an NVPTX compilation path that enables JIT compilation on NVIDIA targets. The following modifications were performed: 1. Adding a format field to the GPU object attribute, allowing the translation attribute to use the correct runtime function to load the module. Likewise, a dictionary attribute was added to add any possible extra options. 2. Adding the `createObject` method to `GPUTargetAttrInterface`; this method returns a GPU object from a binary string. 3. Adding the function `mgpuModuleLoadJIT`, which is only available for NVIDIA GPUs, as there is no equivalent for AMD. 4. Adding the CMake flag `MLIR_GPU_COMPILATION_TEST_FORMAT` to specify the format to use during testing.
-
Daniil Dudkin authored
This patch refactors the `AtomicRMWOpConverter` class to use the dedicated operations from Arith dialect instead of using `cmpf` + `select` pattern. Also, a test for `minimumf` kind of `atomic_rmw` has been added.
-
Daniil Dudkin authored
This patch is part of a larger initiative aimed at fixing floating-point `max` and `min` operations in MLIR: https://discourse.llvm.org/t/rfc-fix-floating-point-max-and-min-operations-in-mlir/72671. Here we introduce new operations for floating-point numbers: `minnum` and `maxnum`. These operations have different semantics than `minumumf` and `maximumf` ops. They follow the eponymous LLVM intrinsics semantics, which differs in the handling positive and negative zeros and NaNs. This patch addresses the 1.3 task from the RFC.
-
Douglas Yung authored
-
Arthur Eubanks authored
This will make it easy for callers to see issues with and fix up calls to createTargetMachine after a future change to the params of TargetMachine. This matches other nearby enums. For downstream users, this should be a fairly straightforward replacement, e.g. s/CodeGenOpt::Aggressive/CodeGenOptLevel::Aggressive or s/CGFT_/CodeGenFileType::
-
Jakub Kuderski authored
Include conversion passes and tools.
-
Joseph Huber authored
Summary: The previous patch moved the implementations of these to generic/ and accidentally did not add the unlocked variants. This patch fixes that
-
Jakub Kuderski authored
Also improve the documentation (code and website).
-
eric authored
Atomic is implemented by Clang, and Clang already implements the behavior in the DR. This was initially noticed by Zoe Carver.
-
Joseph Huber authored
Summary: This patch implements the `fgets`, `getc`, `fgetc`, and `getchar` functions on the GPU. Their implementations are straightforward enough. One thing worth noting is that the implementation of `fgets` will be extremely slow due to the high latency to read a single char. A faster solution would be to make a new RPC call to call `fgets` (due to the special rule that newline or null breaks the stream). But this is left out because performance isn't the primary concern here.
-
Adrian Prantl authored
-
Yaxun (Sam) Liu authored
Currently, clang emits LLVM IR that fails verifier for the following code: ``` template<typename T> __global__ void foo(T x); void bar() { foo<<<1, 1>>>(0); } ``` This is due to clang putting the kernel handle for foo into comdat, which is not allowed, since the kernel handle is a declaration. The siutation is similar to calling a declaration-only template function. The callee will be a declaration in LLVM IR and won't be put into comdat. This is in contrast to calling a template function with body, which will be put into comdat. Fixes: SWDEV-419769 -
Christopher Bate authored
This change removes the requirement that the row stride be statically known when converting `vector.transfer_read` and `vector.transfer_write` to distributed SIMT operations in the `nvgpu` lowering path. It also adds a check to verify that the last dimension of the source memref is statically known to have stride 1 since this is assumed in the conversion logic. No other change should be required since the generated `vector.load` operations are never created across dimensions other than the last. The routines for checking preconditions on `vector.transfer_read/write` are moved to under nvgpu utilities. The change is NFC with respect to the GPU dialect lowering path. Reviewed By: ThomasRaoux Differential Revision: https://reviews.llvm.org/D155753
-
Adrian Prantl authored
-
Alexey Bataev authored
If the non-instruction gets vectorized, no need to account its extract cost, it won't be removed and replaced by extractelement instruction.
-
Alexey Bataev authored
-
Christopher Ferris authored
Fix all the places where the tests are doing implicit conversions.
-
Louis Dionne authored
When we implemented C++20's P0674R1, we didn't enable the part of P0674R1 that was resolving LWG2070 as a DR. This patch fixes that and makes sure that we consistently go through the allocator when constructing and destroying the underlying object in std::allocate_shared. Fixes #54365.
-
Amir Ayupov authored
Reviewed By: #bolt, maksfb Differential Revision: https://reviews.llvm.org/D159516
-
Kinuko Yasuda authored
In C++ it seems it is legit to use base class's operator (e.g. `using Base::operator=`) to perform copy if the base class is the common ancestor of the source and destination object. In such a case we shouldn't try to access fields beyond that of the base class, however such a case seems to be very rare (typical code would implement a copy constructor instead), and could add complexities, so in this patch we simply bail if the method operator's parent class is different from the type of the destination object that this framework recognizes.
-