| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
[flang] Store KindMapping by value in FirOpBuilder Previously only a constant reference was stored in the FirOpBuilder. However, a lot of code was merged using FirOpBuilder builder{rewriter, getKindMapping(mod)}; This is incorrect because the KindMapping returned will go out of scope as soon as FirOpBuilder's constructor had run. This led to an infinite loop running some tests using HLFIR (because the stack space containing the kind mapping was re-used and corrupted). One solution would have just been to fix the incorrect call sites, however, as a large number of these had already made it past review, I decided to instead change FirOpBuilder to store its own copy of the KindMapping. This is not costly because nearly every time we construct a KindMapping is exclusively to construct a FirOpBuilder. To make this common pattern simpler, I added a new constructor to FirOpBuilder which calls getKindMapping(). Differential Revision: https://reviews.llvm.org/D151881 | 3 年前 | |
[flang] Accept BaseBoxType in couple of fir.array_* operations Couple of operation are expecting BoxType but can totally handle ClassType as well. This patch updates couple of locations to support BaseBoxType instead of BoxType only. Reviewed By: jeanPerier, PeteSteinfeld Differential Revision: https://reviews.llvm.org/D138422 | 3 年前 | |
[flang] Remove 'using namespace mlir; from header files Currently, CGOps.h and FIROps.h contain using namespace mlir;. Every file that includes one of these header files (directly and transitively) will have the MLIR namespace enabled. With name-clashes within sub-projects (LLVM and MLIR, MLIR and Flang), this is not desired. Also, it is not possible to "un-use" a namespace once it is "used". Instead, we should try to limit using namespace to implementation files (i.e. *.cpp). This patch removes using namespace mlir; from header files and adjusts other files accordingly. In header and TableGen files, extra namespace qualifier is added when referring to symbols defined in MLIR. Similar approach is adopted in source files that didn't require many changes. In files that would require a lot of changes, using namespace mlir;` is added instead. Differential Revision: https://reviews.llvm.org/D120897 | 4 年前 | |
[flang] Add PowerPC vec_add, vec_and, vec_mul, vec_sub and vec_xor intrinsics Differential Revision: https://reviews.llvm.org/D151857 | 3 年前 | |
[flang] Add comdats to functions with linkonce linkage (#66516) This fixes a bug where functions generated by the MLIR Math dialect, for example ipowi, would fail to link with link.exe on Windows due to having linkonce linkage but no associated comdat. Adding the comdat on ELF also allows linkers to perform better garbage collection in the binary. Simply adding comdats to all functions with this linkage type should also cover future cases where linkonce or linkonce_odr functions might be necessary. (cherry picked from commit 5f476b80e3d472f672f5f6a719eebe2c0aadf52c) | 2 年前 | |
[flang] Generate TBAA information. This is initial version of TBAA information generation for Flang generated IR. The desired behavior is that TBAA type descriptors are generated for FIR types during FIR to LLVM types conversion, and then TBAA access tags are attached to memory accessing operations when they are converted to LLVM IR dialect. In the initial version the type conversion is not producing TBAA type descriptors, and all memory accesses are just partitioned into two sets of box and non-box accesses, which can never alias. The TBAA generation is enabled by default at >O0 optimization levels. TBAA generation may also be enabled via apply-tbaa option of fir-to-llvm-ir conversion pass. -mllvm -disable-tbaa engineering option allows disabling TBAA generation to override Flang's default (e.g. when -O1 is used). SPEC CPU2006/437.leslie3d speeds up by more than 2x on Icelake. Reviewed By: jeanPerier, clementval Differential Revision: https://reviews.llvm.org/D141820 | 3 年前 | |
[flang][fir] Add the pre-code gen rewrite pass and codegen ops. Before the conversion to LLVM-IR dialect and ultimately LLVM IR, FIR is partially rewritten into a codegen form. This patch adds that pass, the fircg dialect, and the small set of Ops in the fircg (sub) dialect. Fircg is not part of the FIR dialect and should never be used outside of the (closed) conversion to LLVM IR. Authors: Eric Schweitz, Jean Perier, Rajan Walia, et.al. Differential Revision: https://reviews.llvm.org/D98063 | 5 年前 | |
Break circular dependency between FIR dialect and utilities | 3 年前 | |
[mlir][flang] Convert TBAA metadata to an attribute representation The current representation of TBAA is the very last in-tree user of the llvm.metadata operation. Using ops to model metadata has a few disadvantages: * Building a graph has to be done through some weakly typed indirection mechanism such as SymbolRefAttr * Creating the metadata has to be done through a builder within a metadata op. * It is not multithreading safe as operation insertion into the same block is not thread-safe This patch therefore converts TBAA metadata into an attribute representation, in a similar manner as it has been done for alias groups and access groups in previous patches. This additionally has the large benefit of giving us more "correctness by construction" as it makes things like cycles in a TBAA graph, or references to an incorrectly typed metadata node impossible. Differential Revision: https://reviews.llvm.org/D155444 | 2 年前 | |
[flang] Complex numbers in function arguments on Windows Function arguments or return values that are complex floating point values aren't correctly lowered for Windows x86 32-bit and 64-bit targets. See: https://github.com/llvm/llvm-project/issues/61976 Add targets that are specific for these platforms and OS. With thanks to @mstorsjo for pointing out the fix. Reviewed By: vzakhari Differential Revision: https://reviews.llvm.org/D147768 | 3 年前 | |
[flang] Store KindMapping by value in FirOpBuilder Previously only a constant reference was stored in the FirOpBuilder. However, a lot of code was merged using FirOpBuilder builder{rewriter, getKindMapping(mod)}; This is incorrect because the KindMapping returned will go out of scope as soon as FirOpBuilder's constructor had run. This led to an infinite loop running some tests using HLFIR (because the stack space containing the kind mapping was re-used and corrupted). One solution would have just been to fix the incorrect call sites, however, as a large number of these had already made it past review, I decided to instead change FirOpBuilder to store its own copy of the KindMapping. This is not costly because nearly every time we construct a KindMapping is exclusively to construct a FirOpBuilder. To make this common pattern simpler, I added a new constructor to FirOpBuilder which calls getKindMapping(). Differential Revision: https://reviews.llvm.org/D151881 | 3 年前 | |
[mlir][flang] Convert TBAA metadata to an attribute representation The current representation of TBAA is the very last in-tree user of the llvm.metadata operation. Using ops to model metadata has a few disadvantages: * Building a graph has to be done through some weakly typed indirection mechanism such as SymbolRefAttr * Creating the metadata has to be done through a builder within a metadata op. * It is not multithreading safe as operation insertion into the same block is not thread-safe This patch therefore converts TBAA metadata into an attribute representation, in a similar manner as it has been done for alias groups and access groups in previous patches. This additionally has the large benefit of giving us more "correctness by construction" as it makes things like cycles in a TBAA graph, or references to an incorrectly typed metadata node impossible. Differential Revision: https://reviews.llvm.org/D155444 | 2 年前 |
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
| 3 年前 | ||
| 3 年前 | ||
| 4 年前 | ||
| 3 年前 | ||
| 2 年前 | ||
| 3 年前 | ||
| 5 年前 | ||
| 3 年前 | ||
| 2 年前 | ||
| 3 年前 | ||
| 3 年前 | ||
| 2 年前 |