| 458 | } |
| 459 | |
| 460 | inline bool IsSignext(const IROp_Header* IROp, OrderedNodeWrapper Src, OpSize Size) { |
| 461 | if (IROp->Op == OP_SBFE) { |
| 462 | auto Sbfe = IROp->C<IR::IROp_Sbfe>(); |
| 463 | return Sbfe->Width == 1 && Sbfe->lsb == (IR::OpSizeAsBits(Size) - 1) && Sbfe->Src == Src; |
| 464 | } else { |
| 465 | return false; |
| 466 | } |
| 467 | } |
| 468 | |
| 469 | inline bool IsZero(const IROp_Header* IROp) { |
| 470 | return IROp->Op == OP_CONSTANT && IROp->C<IROp_Constant>()->Constant == 0; |
no test coverage detected