|
LLVM
10.0.0
|
Simple state with integers encoding. More...
#include "llvm/Transforms/IPO/Attributor.h"
Public Types | |
| using | base_t = base_ty |
Static Public Member Functions | |
| static constexpr base_t | getBestState () |
| Return the best possible representable state. More... | |
| static constexpr base_t | getWorstState () |
| Return the worst possible representable state. More... | |
Protected Member Functions | |
| virtual void | handleNewAssumedValue (base_t Value)=0 |
Handle a new assumed value Value. Subtype dependent. More... | |
| virtual void | handleNewKnownValue (base_t Value)=0 |
Handle a new known value Value. Subtype dependent. More... | |
| virtual void | joinOR (base_t AssumedValue, base_t KnownValue)=0 |
Handle a value Value. Subtype dependent. More... | |
| virtual void | joinAND (base_t AssumedValue, base_t KnownValue)=0 |
Handle a new assumed value Value. Subtype dependent. More... | |
Protected Attributes | |
| base_t | Known = getWorstState() |
| The known state encoding in an integer of type base_t. More... | |
| base_t | Assumed = getBestState() |
| The assumed state encoding in an integer of type base_t. More... | |
Simple state with integers encoding.
The interface ensures that the assumed bits are always a subset of the known bits. Users can only add known bits and, except through adding known bits, they can only remove assumed bits. This should guarantee monotoniticy and thereby the existence of a fixpoint (if used corretly). The fixpoint is reached when the assumed and known state/bits are equal. Users can force/inidicate a fixpoint. If an optimistic one is indicated, the known state will catch up with the assumed one, for a pessimistic fixpoint it is the other way around.
Definition at line 1255 of file Attributor.h.
| using llvm::IntegerStateBase< base_ty, BestState, WorstState >::base_t = base_ty |
Definition at line 1256 of file Attributor.h.
|
inline |
Return the assumed state encoding.
Definition at line 1287 of file Attributor.h.
Referenced by llvm::IRPosition::getAttrs(), llvm::IntegerStateBase< base_ty, 0, ~base_ty(0)>::operator&=(), llvm::operator<<(), llvm::IntegerStateBase< base_ty, 0, ~base_ty(0)>::operator==(), llvm::IntegerStateBase< base_ty, 0, ~base_ty(0)>::operator^=(), and llvm::IntegerStateBase< base_ty, 0, ~base_ty(0)>::operator|=().
|
inlinestatic |
Return the best possible representable state.
Definition at line 1259 of file Attributor.h.
|
inline |
Return the known state encoding.
Definition at line 1284 of file Attributor.h.
Referenced by llvm::IntegerStateBase< base_ty, 0, ~base_ty(0)>::operator&=(), llvm::operator<<(), llvm::IntegerStateBase< base_ty, 0, ~base_ty(0)>::operator==(), and llvm::IntegerStateBase< base_ty, 0, ~base_ty(0)>::operator|=().
|
inlinestatic |
Return the worst possible representable state.
Definition at line 1262 of file Attributor.h.
|
protectedpure virtual |
Handle a new assumed value Value. Subtype dependent.
|
protectedpure virtual |
Handle a new known value Value. Subtype dependent.
|
inlineoverridevirtual |
See AbstractState::indicateOptimisticFixpoint(...)
Implements llvm::AbstractState.
Definition at line 1272 of file Attributor.h.
|
inlineoverridevirtual |
See AbstractState::indicatePessimisticFixpoint(...)
Implements llvm::AbstractState.
Definition at line 1278 of file Attributor.h.
Referenced by llvm::IRPosition::getAttrs().
|
inlineoverridevirtual |
See AbstractState::isAtFixpoint()
Implements llvm::AbstractState.
Definition at line 1269 of file Attributor.h.
|
inlineoverridevirtual |
See AbstractState::isValidState() NOTE: For now we simply pretend that the worst possible state is invalid.
Implements llvm::AbstractState.
Definition at line 1266 of file Attributor.h.
|
protectedpure virtual |
Handle a new assumed value Value. Subtype dependent.
|
protectedpure virtual |
Handle a value Value. Subtype dependent.
|
inline |
Definition at line 1313 of file Attributor.h.
|
inline |
Inequality for IntegerStateBase.
Definition at line 1298 of file Attributor.h.
|
inline |
Equality for IntegerStateBase.
Definition at line 1291 of file Attributor.h.
|
inline |
"Clamp" this state with R.
The result is subtype dependent but it is intended that only information assumed in both states will be assumed in this one afterwards.
Definition at line 1305 of file Attributor.h.
|
inline |
Definition at line 1309 of file Attributor.h.
|
protected |
The assumed state encoding in an integer of type base_t.
Definition at line 1334 of file Attributor.h.
|
protected |
The known state encoding in an integer of type base_t.
Definition at line 1331 of file Attributor.h.
1.8.13