Package org.allspice.bytecode

Examples of org.allspice.bytecode.TypeCode


      ilc.add(createRem(type)) ;
    }
  }
  private static final class NegateConverter implements InstConverter<Negate> {
    public void convertInst(Negate t, InstructionListContext ilc) {
      TypeCode type = t.type ;
      ilc.add(createNeg(type)) ;
    }
View Full Code Here


      ilc.add(createNeg(type)) ;
    }
  }
  private static final class SubtractConverter implements InstConverter<Subtract> {
    public void convertInst(Subtract t, InstructionListContext ilc) {
      TypeCode type = t.type ;
      ilc.add(createSub(type)) ;
    }
View Full Code Here

      ilc.add(createSub(type)) ;
    }
  }
  private static final class DivideConverter implements InstConverter<Divide> {
    public void convertInst(Divide t, InstructionListContext ilc) {
      TypeCode type = t.type ;
      ilc.add(createDiv(type)) ;
    }
View Full Code Here

      ilc.add(createDiv(type)) ;
    }
  }
  private static final class MultiplyConverter implements InstConverter<Multiply> {
    public void convertInst(Multiply t, InstructionListContext ilc) {
      TypeCode type = t.type ;
      ilc.add(createMul(type)) ;
    }
View Full Code Here

      ilc.add(createMul(type)) ;
    }
  }
  private static final class AddConverter implements InstConverter<Add> {
    public void convertInst(Add t, InstructionListContext ilc) {
      TypeCode type = t.type ;
      ilc.add(createAdd(type)) ;
    }
View Full Code Here

      ilc.add(InstructionConstants.SWAP) ;
    }
  }
  private static final class PopConverter implements InstConverter<Pop> {
    public void convertInst(Pop t, InstructionListContext ilc) {
      TypeCode type = t.type ;
      int size = type.wordSize ;
      if (size > 0) {
        ilc.add(InstructionFactory.createPop(size)) ;
      }
    }
View Full Code Here

      }
    }
  }
  private static final class DupConverter implements InstConverter<Dup> {
    public void convertInst(Dup t, InstructionListContext ilc) {
      TypeCode type1 = t.type1 ;
      TypeCode type2 = t.type2 ;
      createDup(ilc, type1, type2);
    }
View Full Code Here

   * @param ilc The instruction list
   * @param count
   * @param var
   */
  public static void createIncrement(InstructionListContext ilc, Number count, LValue var) {
    TypeCode type = TypeCode.getType(var.getType()) ;
    if (var.getLValueType() == LValueType.local) {
      int varindex = ((Var)var).index;
      switch(type) {
      case BYTE:
      case BOOLEAN:
View Full Code Here

   * Adds the instruction(s) to the instruction list.
   * @param ilc The instruction list
   * @param lval
   */
  public static void createStore(InstructionListContext ilc, LValue lval) {
    TypeCode type = TypeCode.getType(lval.getType()) ;
    switch(lval.getLValueType()) {
    case local: {
      Var var = (Var)lval ;
      createStore(type, var.index,ilc) ;
      break ;
View Full Code Here

   * Adds the instruction(s) to the instruction list.
   * @param ilc The instruction list
   * @param lval
   */
  public static void createLoad(InstructionListContext ilc, LValue lval) {
    TypeCode type = TypeCode.getType(lval.getType()) ;
    switch(lval.getLValueType()) {
    case local: {
      Var var = (Var)lval;
      createLoad(type, var.index,ilc) ;
      break ;
View Full Code Here

TOP

Related Classes of org.allspice.bytecode.TypeCode

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.