亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? items.java

?? java編譯器gjc源碼 java編譯環境
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
/**
 * @(#)Items.java	1.22 03/01/23
 *
 * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
 * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
 */
package com.sun.tools.javac.v8.comp;
import com.sun.tools.javac.v8.util.*;

import com.sun.tools.javac.v8.code.*;

import com.sun.tools.javac.v8.code.Symbol.*;

import com.sun.tools.javac.v8.code.Type.*;

import com.sun.tools.javac.v8.code.Code.*;

import com.sun.tools.javac.v8.tree.Tree;


/**
 * A helper class for code generation. Items are objects
 *  that stand for addressable entities in the bytecode. Each item
 *  supports a fixed protocol for loading the item on the stack, storing
 *  into it, converting it into a jump condition, and several others.
 *  There are many individual forms of items, such as local, static,
 *  indexed, or instance variables, values on the top of stack, the
 *  special values this or super, etc. Individual items are represented as
 *  inner classes in class Items.
 */
public class Items implements ByteCodes, TypeTags {

    /**
     * The current constant pool.
     */
    Pool pool;

    /**
     * The current code buffer.
     */
    Code code;

    /**
     * The current symbol table.
     */
    Symtab syms;

    /**
     * Items that exist only once (flyweight pattern).
     */
    private final Item voidItem;
    private final Item thisItem;
    private final Item superItem;
    private final Item[] stackItem = new Item[TypeCodeCount];

    public Items(Pool pool, Code code, Symtab syms) {
        super();
        this.code = code;
        this.pool = pool;
        voidItem = new Item(VOIDcode) {


                       public String toString() {
                           return "void";
                       }
                   };
        thisItem = new SelfItem(false);
        superItem = new SelfItem(true);
        for (int i = 0; i < VOIDcode; i++)
            stackItem[i] = new StackItem(i);
        stackItem[VOIDcode] = voidItem;
        this.syms = syms;
    }

    /**
      * Make a void item
      */
    Item makeVoidItem() {
        return voidItem;
    }

    /**
      * Make an item representing `this'.
      */
    Item makeThisItem() {
        return thisItem;
    }

    /**
      * Make an item representing `super'.
      */
    Item makeSuperItem() {
        return superItem;
    }

    /**
      * Make an item representing a value on stack.
      *  @param type    The value's type.
      */
    Item makeStackItem(Type type) {
        return stackItem[Code.typecode(type)];
    }

    /**
      * Make an item representing an indexed expression.
      *  @param type    The expression's type.
      */
    Item makeIndexedItem(Type type) {
        return new IndexedItem(type);
    }

    /**
      * Make an item representing a local variable.
      *  @param v    The represented variable.
      */
    Item makeLocalItem(VarSymbol v) {
        return new LocalItem(v.erasure(), v.adr);
    }

    /**
      * Make an item representing a local anonymous variable.
      *  @param type  The represented variable's type.
      *  @param reg   The represented variable's register.
      */
    Item makeLocalItem(Type type, int reg) {
        return new LocalItem(type, reg);
    }

    /**
      * Make an item representing a static variable or method.
      *  @param member   The represented symbol.
      */
    Item makeStaticItem(Symbol member) {
        return new StaticItem(member);
    }

    /**
      * Make an item representing an instance variable or method.
      *  @param member       The represented symbol.
      *  @param nonvirtual   Is the reference not virtual? (true for constructors
      *                      and private members).
      */
    Item makeMemberItem(Symbol member, boolean nonvirtual) {
        return new MemberItem(member, nonvirtual);
    }

    /**
      * Make an item representing a literal.
      *  @param t      The literal's type.
      *  @param value  The literal's value.
      */
    Item makeImmediateItem(Type type, Object value) {
        return new ImmediateItem(type, value);
    }

    /**
      * Make an item representing an assignment expression.
      *  @param lhs      The item representing the assignment's left hand side.
      */
    Item makeAssignItem(Item lhs) {
        return new AssignItem(lhs);
    }

    /**
      * Make an item representing a conditional or unconditional jump.
      *  @param opcode      The jump's opcode.
      *  @param trueJumps   A chain encomassing all jumps that can be taken
      *                     if the condition evaluates to true.
      *  @param falseJumps  A chain encomassing all jumps that can be taken
      *                     if the condition evaluates to false.
      */
    CondItem makeCondItem(int opcode, Chain truejumps, Chain falsejumps) {
        return new CondItem(opcode, truejumps, falsejumps);
    }

    /**
      * Make an item representing a conditional or unconditional jump.
      *  @param opcode      The jump's opcode.
      */
    CondItem makeCondItem(int opcode) {
        return makeCondItem(opcode, null, null);
    }

    /**
      * The base class of all items, which implements default behavior.
      */
    abstract class Item {

        /**
         * The type code of values represented by this item.
         */
        int typecode;

        Item(int typecode) {
            super();
            this.typecode = typecode;
        }

        /**
          * Generate code to load this item onto stack.
          */
        Item load() {
            throw new AssertionError();
        }

        /**
          * Generate code to store top of stack into this item.
          */
        Item store() {
            throw new AssertionError("store unsupported: " + this);
        }

        /**
          * Generate code to invoke method represented by this item.
          */
        Item invoke() {
            throw new AssertionError(this.toString());
        }

        /**
          * Generate code to use this item twice.
          */
        void duplicate() {
        }

        /**
          * Generate code to avoid having to use this item.
          */
        void drop() {
        }

        /**
          * Generate code to stash a copy of top of stack - of typecode toscode -
          *  under this item.
          */
        void stash(int toscode) {
            stackItem[toscode].duplicate();
        }

        /**
          * Generate code to turn item into a testable condition.
          */
        CondItem mkCond() {
            load();
            return makeCondItem(ifne);
        }

        /**
          * Generate code to coerce item to given type code.
          *  @param targetcode    The type code to coerce to.
          */
        Item coerce(int targetcode) {
            if (typecode == targetcode)
                return this;
            else {
                load();
                int typecode1 = Code.truncate(typecode);
                int targetcode1 = Code.truncate(targetcode);
                if (typecode1 != targetcode1) {
                    int offset =
                            targetcode1 > typecode1 ? targetcode1 - 1 : targetcode1;
                    code.emitop(i2l + typecode1 * 3 + offset);
                }
                if (targetcode != targetcode1) {
                    code.emitop(int2byte + targetcode - BYTEcode);
                }
                return stackItem[targetcode];
            }
        }

        /**
          * Generate code to coerce item to given type.
          *  @param targettype    The type to coerce to.
          */
        Item coerce(Type targettype) {
            return coerce(Code.typecode(targettype));
        }

        /**
          * Return the width of this item on stack as a number of words.
          */
        int width() {
            return 0;
        }

        public abstract String toString();
    }

    /**
      * An item representing a value on stack.
      */
    class StackItem extends Item {

        StackItem(int typecode) {
            super(typecode);
        }

        Item load() {
            return this;
        }

        void duplicate() {
            code.emitop(width() == 2 ? dup2 : dup);
        }

        void drop() {
            code.emitop(width() == 2 ? pop2 : pop);
        }

        void stash(int toscode) {
            code.emitop((width() == 2 ? dup_x2 : dup_x1) +
                    3 * (Code.width(toscode) - 1));
        }

        int width() {
            return Code.width(typecode);
        }

        public String toString() {
            return "stack(" + typecodeNames[typecode] + ")";
        }
    }

    /**
      * An item representing an indexed expression.
      */
    class IndexedItem extends Item {

        IndexedItem(Type type) {
            super(Code.typecode(type));
        }

        Item load() {
            code.emitop(iaload + typecode);
            return stackItem[typecode];
        }

        Item store() {
            code.emitop(iastore + typecode);
            return voidItem;
        }

        void duplicate() {
            code.emitop(dup2);
        }

        void drop() {
            code.emitop(pop2);
        }

        void stash(int toscode) {
            code.emitop(dup_x2 + 3 * (Code.width(toscode) - 1));
        }

        int width() {
            return 2;
        }

        public String toString() {
            return "indexed(" + ByteCodes.typecodeNames[typecode] + ")";
        }
    }

    /**
      * An item representing `this' or `super'.
      */
    class SelfItem extends Item {

        /**
         * Flag which determines whether this item represents `this' or `super'.
         */
        boolean isSuper;

        SelfItem(boolean isSuper) {
            super(OBJECTcode);
            this.isSuper = isSuper;
        }

        Item load() {
            code.emitop(aload_0);
            return stackItem[typecode];
        }

        public String toString() {
            return isSuper ? "super" : "this";
        }
    }

    /**
      * An item representing a local variable.
      */
    class LocalItem extends Item {

        /**
         * The variable's register.
         */
        int reg;

        /**
         * The variable's type.
         */
        Type type;

        LocalItem(Type type, int reg) {
            super(Code.typecode(type));
            assert reg >= 0;
            this.type = type;
            this.reg = reg;
        }

        Item load() {
            if (reg <= 3)
                code.emitop(iload_0 + Code.truncate(typecode) * 4 + reg);
            else
                code.emitop1w(iload + Code.truncate(typecode), reg);
            return stackItem[typecode];
        }

        Item store() {
            if (reg <= 3)
                code.emitop(istore_0 + Code.truncate(typecode) * 4 + reg);
            else
                code.emitop1w(istore + Code.truncate(typecode), reg);
            code.setDefined(reg);
            return voidItem;
        }

        void incr(int x) {
            if (typecode == INTcode) {
                code.emitop1w(iinc, reg);
                if (reg > 255)
                    code.emit2(x);
                else
                    code.emit1(x);

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
3atv一区二区三区| 美女一区二区久久| 久久精品久久99精品久久| 欧美一区二区私人影院日本| www.亚洲人| 蜜桃传媒麻豆第一区在线观看| 亚洲国产cao| 欧美久久久久免费| 欧美一级欧美三级在线观看| 宅男噜噜噜66一区二区66| 欧美日韩精品久久久| 精品成人一区二区三区四区| 久久精品人人做| 亚洲国产一区二区a毛片| 日韩av一级片| 97久久超碰国产精品| 色天天综合久久久久综合片| 欧美日韩你懂得| 欧美激情一区二区三区蜜桃视频 | 欧美精品一区二| 国产精品久久久久一区二区三区共| 亚洲欧美在线视频观看| 日本视频免费一区| 91浏览器打开| 国产视频一区在线播放| 免费精品99久久国产综合精品| www.亚洲色图| 久久精品网站免费观看| 午夜电影网亚洲视频| 91国偷自产一区二区三区观看 | 欧美色爱综合网| 欧美国产日韩亚洲一区| 激情综合网激情| 欧美在线高清视频| 一区二区三区欧美日| 成人免费黄色大片| 国产亚洲婷婷免费| 国产传媒久久文化传媒| 亚洲精品在线电影| 国产一区二区主播在线| 日韩欧美高清一区| 国产乱码精品一品二品| 久久美女艺术照精彩视频福利播放| 午夜欧美电影在线观看| 色狠狠一区二区三区香蕉| 亚洲一区影音先锋| 7777精品伊人久久久大香线蕉最新版 | 精品乱人伦小说| 成人免费看黄yyy456| 日韩免费视频一区| 国产一区二区三区黄视频 | 久久奇米777| www.久久精品| 亚洲美女淫视频| 91精品视频网| 国产v综合v亚洲欧| 精品国产一区二区三区av性色| 秋霞国产午夜精品免费视频| 久久久久久久久久美女| 成人av资源在线观看| 国产午夜精品一区二区三区视频| 成人av在线一区二区| 亚洲专区一二三| 久久久久久久国产精品影院| 色综合久久久久网| 国产剧情一区二区| 亚洲电影欧美电影有声小说| 欧美高清在线一区二区| 日韩西西人体444www| 91黄色免费版| 成人精品gif动图一区| 日本在线不卡视频| 亚洲一二三四在线| 亚洲欧洲美洲综合色网| 亚洲精品一区二区三区香蕉| 欧美日韩不卡一区| 91久久精品国产91性色tv| 国产盗摄精品一区二区三区在线| 日韩综合在线视频| 亚洲综合色区另类av| 国产精品久久午夜夜伦鲁鲁| 久久这里只有精品6| 久久综合av免费| 欧美激情一区二区三区四区| 精品欧美一区二区三区精品久久 | 国产精品不卡在线| 国产精品久久久久aaaa| 国产精品传媒在线| 亚洲丝袜制服诱惑| 亚洲一区二区在线免费观看视频| 亚洲免费观看在线观看| 一区二区三区欧美激情| 热久久久久久久| 国产一区二区视频在线播放| 91国在线观看| 国产精品一卡二卡在线观看| 国产精品一区二区果冻传媒| 波多野结衣在线aⅴ中文字幕不卡| 成人午夜免费视频| 欧美日韩极品在线观看一区| 精品少妇一区二区| 日韩美女视频一区二区| 日韩中文字幕亚洲一区二区va在线 | 国产精品的网站| 日韩电影在线免费观看| 成人av电影免费在线播放| 在线亚洲一区观看| 国产校园另类小说区| 亚洲欧美另类久久久精品2019| 午夜电影网亚洲视频| 成人激情动漫在线观看| 这里只有精品99re| 一区二区三区欧美久久| 成人综合在线观看| 欧美一级二级在线观看| 亚洲一区二区欧美激情| www.综合网.com| 中文字幕乱码亚洲精品一区| 日产欧产美韩系列久久99| 欧美影院一区二区| 亚洲男同1069视频| av中文字幕一区| 国产精品久久一卡二卡| 国产综合色视频| 精品电影一区二区| 狠狠色伊人亚洲综合成人| 欧美一二三区精品| 日本欧美在线看| 欧美一区二区三区四区视频| 亚洲sss视频在线视频| 欧美狂野另类xxxxoooo| 亚洲第一会所有码转帖| 欧美日韩不卡一区| 青青草97国产精品免费观看无弹窗版 | 欧美日韩高清影院| 成人涩涩免费视频| 97国产精品videossex| 精品国产乱码久久久久久影片| 欧美极品aⅴ影院| 97精品超碰一区二区三区| 亚洲欧美日韩在线| 91精品久久久久久蜜臀| 天天爽夜夜爽夜夜爽精品视频| 欧美日韩国产在线观看| 国产最新精品免费| 综合在线观看色| 欧美日韩国产美| 日本不卡123| 国产欧美1区2区3区| 在线视频一区二区三| 久久99久久99小草精品免视看| 久久久久久久久久看片| 欧美三级日韩三级| 成人小视频免费观看| 丝瓜av网站精品一区二区| 久久久三级国产网站| 欧美丝袜自拍制服另类| 国产高清在线精品| 日韩高清中文字幕一区| 亚洲乱码国产乱码精品精98午夜 | 亚洲精品第一国产综合野| 日韩精品在线一区| 欧美精品成人一区二区三区四区| 成人免费的视频| 国产乱子伦视频一区二区三区 | 日韩一级成人av| 色综合亚洲欧洲| 99久久综合狠狠综合久久| 激情成人午夜视频| 极品少妇一区二区| 国产电影一区在线| 成人综合婷婷国产精品久久蜜臀 | 亚洲成人av福利| 亚洲国产综合91精品麻豆| 亚洲一卡二卡三卡四卡无卡久久| 国产精品女主播av| 亚洲欧美一区二区在线观看| 亚洲国产高清在线观看视频| 欧美国产一区视频在线观看| 中文字幕精品在线不卡| 中文字幕欧美日本乱码一线二线| xnxx国产精品| 国产精品无码永久免费888| 亚洲四区在线观看| 亚洲一区二区三区美女| 久久精品国产亚洲5555| 国产成人av电影免费在线观看| 岛国精品一区二区| 91国产免费观看| 久久久久久久一区| 亚洲老司机在线| 久久国产精品第一页| av午夜精品一区二区三区| 欧美日韩在线播放三区四区| 欧美精品一区二区三区在线播放| 国产精品国产精品国产专区不片| 亚洲午夜久久久久久久久久久| 国产在线一区二区综合免费视频| 粉嫩av一区二区三区粉嫩| 7777精品伊人久久久大香线蕉 |