Go to the documentation of this file.
38 #ifndef __CPU_INST_RES_HH__
39 #define __CPU_INST_RES_HH__
41 #include <type_traits>
80 static_assert(std::is_integral<T>::value ^
81 std::is_floating_point<T>::value,
82 "Parameter type is neither integral nor fp, or it is both");
83 if (std::is_integral<T>::value) {
85 }
else if (std::is_floating_point<T>::value) {
117 panic(
"Assigning result from unknown result type");
127 if (this->type != that.
type)
141 panic(
"Unknown type of result: %d\n", (
int)
type);
197 panic_if(!
isPred(),
"Converting scalar (or invalid) to predicate!!");
204 #endif // __CPU_INST_RES_HH__
bool isScalar() const
Checks.
InstResult(const VecPredRegContainer &v, const ResultType &t)
Predicate result.
Generic predicate register container.
VecReg::Container VecRegContainer
const VecRegContainer & asVector() const
VecPredReg::Container VecPredRegContainer
InstResult(const VecRegContainer &v, const ResultType &t)
Vector result.
InstResult(T i, const ResultType &t)
Scalar result from scalar.
bool isVecElem() const
Is this a vector element result?.
const VecPredRegContainer & asPred() const
bool isValid() const
Is this a valid result?.
bool isPred() const
Is this a predicate result?.
const uint64_t & asIntegerNoAssert() const
Cast to integer without checking type.
const uint64_t & asInteger() const
Explicit cast-like operations.
bool operator!=(const InstResult &that) const
const VecElem & asVectorElem() const
#define panic_if(cond,...)
Conditional panic macro that checks the supplied condition and only panics if the condition is true a...
InstResult & operator=(const InstResult &that)
bool operator==(const InstResult &that) const
Result comparison Two invalid results always differ.
InstResult()
Default constructor creates an invalid result.
bool isVector() const
Is this a vector result?.
Vector Register Abstraction This generic class is the model in a particularization of MVC,...
#define panic(...)
This implements a cprintf based panic() function.
Generated on Wed Sep 30 2020 14:02:08 for gem5 by doxygen 1.8.17