#ifndef GOOSE_CIR_INSTRUCTION_H
#define GOOSE_CIR_INSTRUCTION_H
namespace goose::cir
{
class CFG;
template< typename T >
concept Op = requires
{
Omlkps(declval< T >());
};
using Instruction = variant
<
monostate,
Call,
InlineCall,
CallCheck,
VarAddr,
TempAddr,
Select,
PushConstant,
CreateTemporary,
GetTemporary,
AllocVar,
Load,
Store,
Phi,
Not,
And,
Or,
Xor,
Shl,
LShr,
AShr,
Add,
Sub,
Mul,
UDiv,
SDiv,
URem,
SRem,
Eq,
Neq,
UGT,
UGE,
ULT,
ULE,
SGT,
SGE,
SLT,
SLE,
Assert,
GhostCall,
PHOverrideSet,
PHOverrideClear,
Placeholder,
ForAllSetup,
ForAll,
Implies,
IsPrefixOf,
PushType,
PushStringId
>;
class InstrSeq : public list< Instruction > {};
extern bool CanBeExecuted( const Instruction& instr );
extern bool CanBeEagerlyEvaluated( const Instruction& instr );
extern bool HaveSideEffects( const Instruction& instr );
extern ostream& operator<<( ostream& out, const Instruction& instr );
}
#endif