Package org.jnode.assembler.x86

Examples of org.jnode.assembler.x86.X86Assembler.writeMOV()


                if (os.isCode64()) {
                    final GPR64 newR = (GPR64) pool.getRegisterInSameGroup(r, JvmType.REFERENCE);
                    if (mcode == FROMINTZEROEXTEND) {
                        // Moving the register to itself in 32-bit mode, will
                        // zero extend the top 32-bits.
                        os.writeMOV(BITS32, r, r);
                    } else {
                        // Sign extend
                        os.writeMOVSXD(newR, (GPR32) r);
                    }
                    r = newR;
View Full Code Here


        switch (getKind()) {
            case Kind.GPR:
                res = L1AHelper.requestWordRegister(ec, getType(), false);
                final GPR r = res.getRegister();
                os.writeMOV(gpr.getSize(), r, gpr);
                break;

            case Kind.LOCAL:
                res = (WordItem) factory.createLocal(getType(), getOffsetToFP(ec));
                break;
View Full Code Here

        }

        switch (getKind()) {
            case Kind.GPR:
                if (this.gpr != reg) {
                    os.writeMOV(reg.getSize(), reg, this.gpr);
                    cleanup(ec);
                }
                break;

            case Kind.LOCAL:
View Full Code Here

                    cleanup(ec);
                }
                break;

            case Kind.LOCAL:
                os.writeMOV(reg.getSize(), reg, helper.BP, getOffsetToFP(ec));
                break;

            case Kind.CONSTANT:
                loadToConstant(ec, os, reg);
                break;
View Full Code Here

            case Kind.GPR:
                res = L1AHelper.requestDoubleWordRegisters(ec, getType());
                if (os.isCode32()) {
                    final GPR lsb = res.getLsbRegister(ec);
                    final GPR msb = res.getMsbRegister(ec);
                    os.writeMOV(INTSIZE, lsb, this.lsb);
                    os.writeMOV(INTSIZE, msb, this.msb);
                } else {
                    final GPR64 reg = res.getRegister(ec);
                    os.writeMOV(BITS64, reg, this.reg);
                }
View Full Code Here

                res = L1AHelper.requestDoubleWordRegisters(ec, getType());
                if (os.isCode32()) {
                    final GPR lsb = res.getLsbRegister(ec);
                    final GPR msb = res.getMsbRegister(ec);
                    os.writeMOV(INTSIZE, lsb, this.lsb);
                    os.writeMOV(INTSIZE, msb, this.msb);
                } else {
                    final GPR64 reg = res.getRegister(ec);
                    os.writeMOV(BITS64, reg, this.reg);
                }
                break;
View Full Code Here

                    final GPR msb = res.getMsbRegister(ec);
                    os.writeMOV(INTSIZE, lsb, this.lsb);
                    os.writeMOV(INTSIZE, msb, this.msb);
                } else {
                    final GPR64 reg = res.getRegister(ec);
                    os.writeMOV(BITS64, reg, this.reg);
                }
                break;

            case Kind.LOCAL:
                res = (DoubleWordItem) factory.createLocal(getType(), super
View Full Code Here

                    // invariant: (msb != this.lsb) && (msb != lsb) && (this.msb !=
                    // this.lsb)
                    // msb <- msb'
                    // lsb <- lsb'
                    if (msb != this.msb) {
                        os.writeMOV(INTSIZE, msb, this.msb);
                        if (lsb != this.msb) {
                            pool.release(this.msb);
                        }
                    }
                    if (lsb != this.lsb) {
View Full Code Here

                final RefItem addr = vstack.popRef();
                addr.load(ec);
                final GPR r = addr.getRegister();
                final WordItem result = L1AHelper.requestWordRegister(ec, methodToType(mcode), false);
                final GPR resultr = result.getRegister();
                os.writeMOV(resultr.getSize(), resultr, r, 0);
                addr.release(ec);
                vstack.push(result);
                break;
            }
            case LOADLONG:
View Full Code Here

                final X86Register.GPR r = addr.getRegister();
                if (os.isCode32()) {
                    final X86Register.GPR msb = (X86Register.GPR) L1AHelper.requestRegister(ec, JvmType.INT, false);
                    addr.release(ec);
                    L1AHelper.releaseRegister(ec, msb);
                    os.writeMOV(X86CompilerConstants.INTSIZE, msb, r, X86CompilerConstants.MSB);
                    os.writeMOV(X86CompilerConstants.INTSIZE, r, r, X86CompilerConstants.LSB);
                    vstack.push(L1AHelper.requestDoubleWordRegisters(ec, methodToType(mcode), r, msb));
                } else {
                    final DoubleWordItem result = L1AHelper.requestDoubleWordRegisters(ec, methodToType(mcode));
                    os.writeMOV(BITS64, result.getRegister(ec), r, 0);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.