1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-22 18:54:02 +01:00
llvm-mirror/include/llvm/Transforms
Shilei Tian 08c004d674 [Attributor] Add support for compound assignment for ChangeStatus
A common use of `ChangeStatus` is as follows:
```
ChangeStatus Changed = ChangeStatus::UNCHANGED;
Changed |= foo();
```
where `foo` returns `ChangeStatus` as well. Currently `ChangeStatus` doesn't
support compound assignment, we have to write as
```
Changed = Changed | foo();
```
which is not that convenient.

This patch add the support for compound assignment for `ChangeStatus`. Compound
assignment is usually implemented as a member function, and binary arithmetic
operator is therefore implemented using compound assignment. However, unlike
regular C++ class, enum class doesn't support member functions. As a result, they
can only be implemented in the way shown in the patch.

Reviewed By: jdoerfert

Differential Revision: https://reviews.llvm.org/D106109
2021-07-15 23:51:46 -04:00
..
AggressiveInstCombine
Coroutines [Coroutine] [Debug] Insert dbg.declare to entry.resume to print alloca in the coroutine frame under O2 2021-03-31 10:37:06 +08:00
InstCombine [InstCombine] isFreeToInvert(): constant expressions aren't free to invert (PR50370) 2021-05-17 14:58:05 +03:00
Instrumentation [clang-cl][sanitizer] Add -fsanitize-address-use-after-return to clang. 2021-06-11 12:07:35 -07:00
IPO [Attributor] Add support for compound assignment for ChangeStatus 2021-07-15 23:51:46 -04:00
Scalar [NewPM][SimpleLoopUnswitch] Add option to not trivially unswitch 2021-07-13 16:09:42 -07:00
Utils Partial Reapply "[DebugInfo] Use variadic debug values to salvage BinOps and GEP instrs with non-const operands" 2021-06-24 09:46:38 +01:00
Vectorize [LV] Parallel annotated loop does not imply all loads can be hoisted. 2021-06-10 23:37:57 +02:00
CFGuard.h
Coroutines.h [Coroutine] [Debug] Insert dbg.declare to entry.resume to print alloca in the coroutine frame under O2 2021-03-31 10:37:06 +08:00
Instrumentation.h
IPO.h Function Specialization Pass 2021-06-11 09:11:29 +01:00
ObjCARC.h
Scalar.h Revert "[Passes] Add relative lookup table converter pass" 2021-03-30 14:13:37 +02:00
Utils.h
Vectorize.h