llvm-capstone/flang/lib
Jean Perier ec13942e71 [flang] prevent undefined behavior in character MAXLOC folding
When folding MAXLOC/MINLOC, the current element being compared was moved twice
in row in case it became the new extremum. With numeric and logical types, it
made no difference (std::move is a no-op for them), but for characters
where the string storage is actually moved, it caused the new extremum to
be set to the empty string, leading to wrong results.

Note: I could have left the first std::move relating to logical Findloc, but it
brings nothing and makes the code less auditable, so I also removed it.

Differential Revision: https://reviews.llvm.org/D122590
2022-03-29 09:34:09 +02:00
..
Common [flang] Use the Flang cmake-functions to add targets. 2020-04-16 15:51:30 +01:00
Decimal [flang] Runtime performance improvements to real formatted input 2021-11-12 11:40:02 -08:00
Evaluate [flang] prevent undefined behavior in character MAXLOC folding 2022-03-29 09:34:09 +02:00
Frontend [flang][driver] Add support for -mllvm 2022-03-16 10:41:04 +00:00
FrontendTool [flang][driver] Add support for -mllvm 2022-03-16 10:41:04 +00:00
Lower [flang][OpenMP] Added parallel sections translation 2022-03-29 11:16:38 +05:30
Optimizer [mlir] Simplify LoopLikeOpInterface 2022-03-28 18:10:04 +00:00
Parser Revert "[flang] Add & use a better visit()" 2022-03-28 10:46:47 +00:00
Semantics Revert "[flang] Add & use a better visit()" 2022-03-28 10:46:47 +00:00
CMakeLists.txt [flang][driver] Delete f18 (i.e. the old Flang driver) 2021-08-05 12:57:15 +00:00