abstract methods in AbstractAssembler

Christian Thalinger christian.thalinger at oracle.com
Thu Feb 7 10:30:01 PST 2013

Currently I'm adding other architectures to Graal.  In order to ease that task I have a tool which generates the Assembler from an ISA description file.

Now I have problems with these methods in AbstractAssembler:

    public abstract void align(int modulus);
    public abstract void jmp(Label l);
    protected abstract void patchJumpTarget(int branch, int jumpTarget);
    public abstract void bangStack(int disp);

Two problems actually:

1)  I could generate these methods but they are not part of an ISA;  I'd like to keep it abstracted and not add anything that doesn't belong into an assembler.

2)  Not all architectures require what the methods above try to do.  This means that LabelOp, JumpOp, Label.patchInstruction and Backend.emitStackOverflowCheck need to be either moved somewhere else or need more abstraction.

Any ideas?

-- Chris

More information about the graal-dev mailing list