llvm-project/flang/lib/Lower
Mehdi Amini ca0ed40e00 Remove builder that takes SSA value instead of Attribute on ExtractValueOp, InsetValueOp, and InsertOnRangeOp
This builder exposed a somehow "unsafe" API: it pretends we can
construct an InsertOnRangeOp from a range of SSA values, even though
this will crash if these aren't the result of `arith.constant` since
the operation actually needs attribute values (a build method can't
fail gracefully).
That means that the caller must check for the producer, at which
point they can just assemble the attribute array directly and call
the existing builder.

The existing call-sites were even in a worse state here: they would
actually create a constant operation that wouldn't be used and only
serve to carry the attribute through the builder API.

Differential Revision: https://reviews.llvm.org/D112946
2021-11-02 22:35:47 +00:00
..
.clang-format [flang] [LLVMify F18] Compiler module folders should have capitalised names (flang-compiler/f18#980) 2020-02-25 07:11:52 -08:00
.clang-tidy [flang] Add clang-tidy check for braces around if 2021-06-16 09:13:53 +00:00
CMakeLists.txt [fir] Split FIROptimizer lib into several smaller libraries 2021-10-05 14:02:32 +02:00
CharacterExpr.cpp Remove builder that takes SSA value instead of Attribute on ExtractValueOp, InsetValueOp, and InsertOnRangeOp 2021-11-02 22:35:47 +00:00
CharacterRuntime.cpp [MLIR] Replace std ops with arith dialect ops 2021-10-13 03:07:03 +00:00
Coarray.cpp [flang] Add coarray lowering hooks. 2020-06-29 14:24:13 -07:00
ComplexExpr.cpp [MLIR] Replace std ops with arith dialect ops 2021-10-13 03:07:03 +00:00
ConvertExpr.cpp [flang] Fix shared library builds for lib/Lower. 2020-07-16 10:18:14 +01:00
ConvertType.cpp [flang][fir] Update FIR's character type. 2021-02-08 08:20:04 -08:00
DoLoopHelper.cpp [MLIR] Replace std ops with arith dialect ops 2021-10-13 03:07:03 +00:00
FIRBuilder.cpp [MLIR] Replace std ops with arith dialect ops 2021-10-13 03:07:03 +00:00
IO.cpp [MLIR] Replace std ops with arith dialect ops 2021-10-13 03:07:03 +00:00
IntervalSet.h [flang][fir] Upstream the pre-FIR tree changes. 2021-03-10 07:45:58 -08:00
IntrinsicCall.cpp [MLIR] Replace std ops with arith dialect ops 2021-10-13 03:07:03 +00:00
Mangler.cpp [flang][fir] Add support to mangle/deconstruct namelist group name 2021-09-24 22:10:39 +02:00
OpenACC.cpp [flang][NFC] Add source line to lowering TODO messages 2021-02-23 09:01:35 +01:00
OpenMP.cpp [flang][OpenMP] Remove `OmpEndLoopDirective` handles from code. 2021-04-16 00:00:07 +05:30
PFTBuilder.cpp [flang] iwyu fixes after ba7a92c01e 2021-04-21 11:10:45 -04:00
RTBuilder.h [flang] Improve runtime interface with C99 complex 2021-10-01 08:45:24 +02:00
SymbolMap.h [flang] Add CHARACTER type lowering helpers and runtime. 2020-06-26 11:01:52 -07:00