HAL  v4.5.0-83-g30c8f0afc
The Hardware Analyzer - a comprehensive reverse engineering and manipulation framework for gate-level netlists.
hal::BV_ConstantPropagation Namespace Reference

Functions

BooleanFunction And (const std::vector< BooleanFunction::Value > &p0, const std::vector< BooleanFunction::Value > &p1)
 
BooleanFunction Or (const std::vector< BooleanFunction::Value > &p0, const std::vector< BooleanFunction::Value > &p1)
 
BooleanFunction Not (const std::vector< BooleanFunction::Value > &p)
 
BooleanFunction Xor (const std::vector< BooleanFunction::Value > &p0, const std::vector< BooleanFunction::Value > &p1)
 
BooleanFunction Add (const std::vector< BooleanFunction::Value > &p0, const std::vector< BooleanFunction::Value > &p1)
 
BooleanFunction Sub (const std::vector< BooleanFunction::Value > &p0, const std::vector< BooleanFunction::Value > &p1)
 
BooleanFunction Mul (const std::vector< BooleanFunction::Value > &p0, const std::vector< BooleanFunction::Value > &p1)
 
BooleanFunction Sle (const std::vector< BooleanFunction::Value > &p0, const std::vector< BooleanFunction::Value > &p1)
 
BooleanFunction Slt (const std::vector< BooleanFunction::Value > &p0, const std::vector< BooleanFunction::Value > &p1)
 
BooleanFunction Ule (const std::vector< BooleanFunction::Value > &p0, const std::vector< BooleanFunction::Value > &p1)
 
BooleanFunction Ult (const std::vector< BooleanFunction::Value > &p0, const std::vector< BooleanFunction::Value > &p1)
 
BooleanFunction Ite (const std::vector< BooleanFunction::Value > &p0, const std::vector< BooleanFunction::Value > &p1, const std::vector< BooleanFunction::Value > &p2)
 
Result< BooleanFunctionconstant_propagation (const BooleanFunction::Node &node, std::vector< BooleanFunction > &&p)
 

Function Documentation

◆ Add()

BooleanFunction hal::BV_ConstantPropagation::Add ( const std::vector< BooleanFunction::Value > &  p0,
const std::vector< BooleanFunction::Value > &  p1 
)

Helper function to simplify a constant ADD operation.

Parameters
[in]p0- Boolean function parameter 0.
[in]p1- Boolean function parameter 1.
Returns
Boolean function with a simplified constant value.

Definition at line 135 of file simplification.cpp.

References hal::carry, and hal::BooleanFunction::Const().

Referenced by constant_propagation().

◆ And()

BooleanFunction hal::BV_ConstantPropagation::And ( const std::vector< BooleanFunction::Value > &  p0,
const std::vector< BooleanFunction::Value > &  p1 
)

Helper function to simplify a constant AND operation.

Parameters
[in]p0- Boolean function parameter 0.
[in]p1- Boolean function parameter 1.
Returns
Boolean function with a simplified constant value.

Definition at line 20 of file simplification.cpp.

References hal::BooleanFunction::Const().

Referenced by constant_propagation().

◆ constant_propagation()

◆ Ite()

BooleanFunction hal::BV_ConstantPropagation::Ite ( const std::vector< BooleanFunction::Value > &  p0,
const std::vector< BooleanFunction::Value > &  p1,
const std::vector< BooleanFunction::Value > &  p2 
)

Helper function to simplify a constant ITE operation.

Parameters
[in]p0- Boolean function parameter 0.
[in]p1- Boolean function parameter 1.
[in]p2- Boolean function parameter 2.
Returns
Boolean function with a simplified constant value.

Definition at line 356 of file simplification.cpp.

References hal::BooleanFunction::Const().

◆ Mul()

BooleanFunction hal::BV_ConstantPropagation::Mul ( const std::vector< BooleanFunction::Value > &  p0,
const std::vector< BooleanFunction::Value > &  p1 
)

Helper function to simplify a constant MUL operation.

Parameters
[in]p0- Boolean function parameter 0.
[in]p1- Boolean function parameter 1.
Returns
Boolean function with a simplified constant value.

Definition at line 189 of file simplification.cpp.

References hal::carry, and hal::BooleanFunction::Const().

Referenced by constant_propagation().

◆ Not()

BooleanFunction hal::BV_ConstantPropagation::Not ( const std::vector< BooleanFunction::Value > &  p)

Helper function to simplify a constant NOT operation.

Parameters
[in]p- Boolean function parameter.
Returns
Boolean function with a simplified constant value.

Definition at line 77 of file simplification.cpp.

References hal::BooleanFunction::Const().

Referenced by constant_propagation().

◆ Or()

BooleanFunction hal::BV_ConstantPropagation::Or ( const std::vector< BooleanFunction::Value > &  p0,
const std::vector< BooleanFunction::Value > &  p1 
)

Helper function to simplify a constant OR operation.

Parameters
[in]p0- Boolean function parameter 0.
[in]p1- Boolean function parameter 1.
Returns
Boolean function with a simplified constant value.

Definition at line 49 of file simplification.cpp.

References hal::BooleanFunction::Const().

Referenced by constant_propagation().

◆ Sle()

BooleanFunction hal::BV_ConstantPropagation::Sle ( const std::vector< BooleanFunction::Value > &  p0,
const std::vector< BooleanFunction::Value > &  p1 
)

Helper function to simplify a constant SLE operation.

Parameters
[in]p0- Boolean function parameter 0.
[in]p1- Boolean function parameter 1.
Returns
Boolean function with a simplified constant value.

Definition at line 219 of file simplification.cpp.

References hal::carry, and hal::BooleanFunction::Const().

◆ Slt()

BooleanFunction hal::BV_ConstantPropagation::Slt ( const std::vector< BooleanFunction::Value > &  p0,
const std::vector< BooleanFunction::Value > &  p1 
)

Helper function to simplify a constant SLT operation.

Parameters
[in]p0- Boolean function parameter 0.
[in]p1- Boolean function parameter 1.
Returns
Boolean function with a simplified constant value.

Definition at line 259 of file simplification.cpp.

References hal::carry, and hal::BooleanFunction::Const().

◆ Sub()

BooleanFunction hal::BV_ConstantPropagation::Sub ( const std::vector< BooleanFunction::Value > &  p0,
const std::vector< BooleanFunction::Value > &  p1 
)

Helper function to simplify a constant SUB operation.

Parameters
[in]p0- Boolean function parameter 0.
[in]p1- Boolean function parameter 1.
Returns
Boolean function with a simplified constant value.

Definition at line 162 of file simplification.cpp.

References hal::carry, and hal::BooleanFunction::Const().

Referenced by constant_propagation().

◆ Ule()

BooleanFunction hal::BV_ConstantPropagation::Ule ( const std::vector< BooleanFunction::Value > &  p0,
const std::vector< BooleanFunction::Value > &  p1 
)

Helper function to simplify a constant ULE operation.

Parameters
[in]p0- Boolean function parameter 0.
[in]p1- Boolean function parameter 1.
Returns
Boolean function with a simplified constant value.

Definition at line 297 of file simplification.cpp.

References hal::BooleanFunction::Const().

◆ Ult()

BooleanFunction hal::BV_ConstantPropagation::Ult ( const std::vector< BooleanFunction::Value > &  p0,
const std::vector< BooleanFunction::Value > &  p1 
)

Helper function to simplify a constant ULT operation.

Parameters
[in]p0- Boolean function parameter 0.
[in]p1- Boolean function parameter 1.
Returns
Boolean function with a simplified constant value.

Definition at line 326 of file simplification.cpp.

References hal::BooleanFunction::Const().

◆ Xor()

BooleanFunction hal::BV_ConstantPropagation::Xor ( const std::vector< BooleanFunction::Value > &  p0,
const std::vector< BooleanFunction::Value > &  p1 
)

Helper function to simplify a constant XOR operation.

Parameters
[in]p0- Boolean function parameter 0.
[in]p1- Boolean function parameter 1.
Returns
Boolean function with a simplified constant value.

Definition at line 106 of file simplification.cpp.

References hal::BooleanFunction::Const().

Referenced by constant_propagation().