Package org.apache.bcel.generic

Examples of org.apache.bcel.generic.IF_ICMPNE


     * @param src object responsible for generating branch
     * @return wrapper for appended conditional branch
     */
    public BranchWrapper appendIF_ICMPNE(Object src) {
        verifyStack("int", "int");
        BranchHandle hand = m_instructionList.append(new IF_ICMPNE(null));
        setTarget(hand);
        m_stackState.pop(2);
        return new BranchWrapper(hand, m_stackState.toArray(), src);
    }
View Full Code Here


                                                      "(I)I");
      il.append(new SIPUSH((short)((Step)_left).getNodeType()));
      il.append(methodGen.loadDOM());
      il.append(methodGen.loadContextNode());
      il.append(new INVOKEINTERFACE(idx, 2));
      _falseList.add(il.append(new IF_ICMPNE(null)));
  }
  else {

      _left.translate(classGen, methodGen);
      if (_type != ltype) {
View Full Code Here

  il.append(new ILOAD(node.getIndex()));
  iter.setEnd(il.append(new IF_ICMPLT(next)));

  node2.setEnd(il.append(new ILOAD(node2.getIndex())));
  node.setEnd(il.append(new ILOAD(node.getIndex())));
  _falseList.add(il.append(new IF_ICMPNE(null)));

  skipNext.setTarget(begin);
    }
View Full Code Here

  if (tleft instanceof BooleanType) {
      _left.translate(classGen, methodGen);
      _right.translate(classGen, methodGen);
        _falseList.add(il.append(_op == Operators.EQ ?
             (BranchInstruction)new IF_ICMPNE(null) :
             (BranchInstruction)new IF_ICMPEQ(null)));
  }
  else if (tleft instanceof NumberType) {
      _left.translate(classGen, methodGen);
      _right.translate(classGen, methodGen);

      if (tleft instanceof RealType) {
    il.append(DCMPG);
        _falseList.add(il.append(_op == Operators.EQ ?
           (BranchInstruction)new IFNE(null) :
           (BranchInstruction)new IFEQ(null)));
      }
      else {
            _falseList.add(il.append(_op == Operators.EQ ?
           (BranchInstruction)new IF_ICMPNE(null) :
           (BranchInstruction)new IF_ICMPEQ(null)));
      }
  }
  else {
      translate(classGen, methodGen);
View Full Code Here

                  "getType", "(I)I");
      il.append(new SIPUSH((short)((Step)_left).getNodeType()));
      il.append(methodGen.loadDOM());
      il.append(methodGen.loadContextNode());
      il.append(new INVOKEINTERFACE(idx, 2));
      _falseList.add(il.append(new IF_ICMPNE(null)));
  }
  else {

      _left.translate(classGen, methodGen);
      if (_type != ltype) {
View Full Code Here

  il.append(new ILOAD(node.getIndex()));
  il.append(new IF_ICMPLT(next));

  il.append(new ILOAD(node2.getIndex()));
  il.append(new ILOAD(node.getIndex()));
  _falseList.add(il.append(new IF_ICMPNE(null)));

  skipNext.setTarget(begin);
    }
View Full Code Here

  if (tleft instanceof BooleanType) {
      _left.translate(classGen, methodGen);
      _right.translate(classGen, methodGen);
        _falseList.add(il.append(_op == Operators.EQ ?
             (BranchInstruction)new IF_ICMPNE(null) :
             (BranchInstruction)new IF_ICMPEQ(null)));
  }
  else if (tleft instanceof NumberType) {
      _left.translate(classGen, methodGen);
      _right.translate(classGen, methodGen);

      if (tleft instanceof RealType) {
    il.append(DCMPG);
        _falseList.add(il.append(_op == Operators.EQ ?
           (BranchInstruction)new IFNE(null) :
           (BranchInstruction)new IFEQ(null)));
      }
      else {
            _falseList.add(il.append(_op == Operators.EQ ?
           (BranchInstruction)new IF_ICMPNE(null) :
           (BranchInstruction)new IF_ICMPEQ(null)));
      }
  }
  else {
      translate(classGen, methodGen);
View Full Code Here

  il.append(new ILOAD(node.getIndex()));
  il.append(new IF_ICMPLT(next));

  il.append(new ILOAD(node2.getIndex()));
  il.append(new ILOAD(node.getIndex()));
  _falseList.add(il.append(new IF_ICMPNE(null)));

  skipNext.setTarget(begin);
    }
View Full Code Here

      case DIV:   il.append(InstructionConstants.IDIV); ASTFunDecl.pop()break;
      case AND:   il.append(InstructionConstants.IAND); ASTFunDecl.pop()break;
      case OR:    il.append(InstructionConstants.IOR);  ASTFunDecl.pop()break;

  /* Use negated operands */
      case EQ:    bh = il.append(new IF_ICMPNE(null)); ASTFunDecl.pop(2); break;
      case LEQ:   bh = il.append(new IF_ICMPGT(null)); ASTFunDecl.pop(2); break;
      case GEQ:   bh = il.append(new IF_ICMPLT(null)); ASTFunDecl.pop(2); break;
      case NEQ:   bh = il.append(new IF_ICMPEQ(null)); ASTFunDecl.pop(2); break;
      case LT:    bh = il.append(new IF_ICMPGE(null)); ASTFunDecl.pop(2); break;
      case GT:    bh = il.append(new IF_ICMPLE(null)); ASTFunDecl.pop(2); break;
View Full Code Here

                                                      "(I)I");
      il.append(new SIPUSH((short)((Step)_left).getNodeType()));
      il.append(methodGen.loadDOM());
      il.append(methodGen.loadContextNode());
      il.append(new INVOKEINTERFACE(idx, 2));
      _falseList.add(il.append(new IF_ICMPNE(null)));
  }
  else {

      _left.translate(classGen, methodGen);
      if (_type != ltype) {
View Full Code Here

TOP

Related Classes of org.apache.bcel.generic.IF_ICMPNE

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.