bool IpfVerifier::mov()

in vm/jitrino/src/codegenerator/ipf/IpfVerifier.cpp [1008:1034]


bool IpfVerifier::mov(string * res, Inst * inst, InstCode icode, OpndVector & opnds, CompVector & cmpls) {
   if (icode!=INST_MOV_RET && IS_O(1) && IS_O(2) && !IS_O(3) 
            && ((IS_AR(1) && IS_GR(2)) || (IS_GR(1) && IS_AR(2)) || (IS_AR(1) && IS_IMM8(2))))
        return true;
    if (icode==INST_MOV && !IS_O(3) && ((IS_GR(1) && IS_BR(2)) || (IS_BR(1) && IS_GR(2))))
        return true;
    if ((icode==INST_MOV || icode==INST_MOV_RET) && IS_O(3) && IS_BR(1) && IS_GR(2) && IS_IMM13(3)) {
        for (U_32 i=0 ; IS_C(i) ; i++){
            switch (C(i)) {
            case CMPLT_IH_NOT_IMP:
            case CMPLT_IH_IMP:
            case CMPLT_WH_DPTK:
            case CMPLT_WH_SPTK:
            case CMPLT_WH_IGNORE:
                break;
            default: 
                return false;
            }
        }
        return true;
    }
    if (icode==INST_MOV && !IS_O(3) && !IS_C(0) && IS_FR(1) && IS_FR(2)) return true;
    if (icode==INST_MOV && !IS_O(3) && !IS_C(0) && IS_GR(1) && IS_GR(2)) return true;
    if (icode==INST_MOV && !IS_O(3) && !IS_C(0) && IS_GR(1) && (IS_IMM22(2) || IS_REF(2))) return true;

    return false;
}