Пример #1
0
  @Override
  public Operand simplifyAndGetResult(Map<Operand, Operand> valueMap) {
    simplifyOperands(valueMap, false);
    if (!value.isConstant()) return null;

    return value == Nil.NIL || value == BooleanLiteral.FALSE
        ? BooleanLiteral.FALSE
        : BooleanLiteral.TRUE;
  }
Пример #2
0
  public void setConstantValue(String constRef, Operand val) {
    if (val.isConstant()) _constMap.put(constRef, val);

    if (this instanceof IR_Module)
      ((IR_Module) this).getRootMethod().addInstr(new PUT_CONST_Instr(this, constRef, val));
  }