public abstract class SPARCAssembler extends Assembler
Modifier and Type | Class and Description |
---|---|
static class |
SPARCAssembler.Annul |
static class |
SPARCAssembler.Asi
Represents the Address Space Identifier defined in the SPARC architecture.
|
static class |
SPARCAssembler.BitKey |
static class |
SPARCAssembler.BitKeyIndex
Represents a prefix tree of
SPARCAssembler.BitSpec objects to find the most accurate SPARCOp. |
static class |
SPARCAssembler.BitSpec
Specifies various bit fields used in SPARC instructions.
|
static class |
SPARCAssembler.Bpcc |
static class |
SPARCAssembler.Bpr |
static class |
SPARCAssembler.Br |
static class |
SPARCAssembler.BranchPredict |
static class |
SPARCAssembler.CBCond |
static class |
SPARCAssembler.CC
Condition Codes to use for instruction.
|
static class |
SPARCAssembler.CompositeBitSpec |
static class |
SPARCAssembler.ConditionFlag |
static class |
SPARCAssembler.ContinousBitSpec |
static class |
SPARCAssembler.ControlTransferOp
Base class for control transfer operations; provides access to the disp field.
|
static class |
SPARCAssembler.Fcn |
static class |
SPARCAssembler.MembarMask |
static class |
SPARCAssembler.Op2Op |
static class |
SPARCAssembler.Op2s |
static class |
SPARCAssembler.Op3Op |
static class |
SPARCAssembler.Op3s |
static class |
SPARCAssembler.Opfs |
static class |
SPARCAssembler.Ops |
static class |
SPARCAssembler.RCondition |
static class |
SPARCAssembler.Sethi |
static class |
SPARCAssembler.SPARCOp
Represents a class of SPARC instruction and gives methods to modify its fields.
|
Assembler.InstructionCounter, Assembler.LabelHint
Constructor and Description |
---|
SPARCAssembler(TargetDescription target,
RegisterConfig registerConfig)
Constructs an assembler for the SPARC architecture.
|
Modifier and Type | Method and Description |
---|---|
void |
add(Register rs1,
int simm13,
Register rd) |
void |
add(Register rs1,
Register rs2,
Register rd) |
void |
addc(Register rs1,
int simm13,
Register rd) |
void |
addc(Register rs1,
Register rs2,
Register rd) |
void |
addcc(Register rs1,
int simm13,
Register rd) |
void |
addcc(Register rs1,
Register rs2,
Register rd) |
void |
and(Register rs1,
int simm13,
Register rd) |
void |
and(Register rs1,
Register rs2,
Register rd) |
void |
andcc(Register rs1,
int simm13,
Register rd) |
void |
andcc(Register rs1,
Register rs2,
Register rd) |
void |
andn(Register rs1,
int simm13,
Register rd) |
void |
andn(Register rs1,
Register rs2,
Register rd) |
void |
andncc(Register rs1,
int simm13,
Register rd) |
void |
andncc(Register rs1,
Register rs2,
Register rd) |
private void |
bcc(SPARCAssembler.Op2s op2,
SPARCAssembler.ConditionFlag cond,
SPARCAssembler.Annul annul,
Label l)
Branch on (Integer|Floatingpoint) Condition Codes.
|
void |
bicc(SPARCAssembler.ConditionFlag cond,
SPARCAssembler.Annul annul,
Label l)
Branch on Integer Condition Codes.
|
void |
bpcc(SPARCAssembler.ConditionFlag cond,
SPARCAssembler.Annul annul,
Label l,
SPARCAssembler.CC cc,
SPARCAssembler.BranchPredict predictTaken)
Branch on Integer Condition Codes with Prediction.
|
private void |
bpcc(SPARCAssembler.Op2s op2,
SPARCAssembler.ConditionFlag cond,
SPARCAssembler.Annul annul,
Label l,
SPARCAssembler.CC cc,
SPARCAssembler.BranchPredict predictTaken)
Used for fbpcc (Float) and bpcc (Integer).
|
void |
bpr(SPARCAssembler.RCondition cond,
SPARCAssembler.Annul annul,
Label l,
SPARCAssembler.BranchPredict predictTaken,
Register rs1)
Branch on Integer Register with Prediction.
|
int |
call(int disp30)
Instruction format for calls.
|
void |
casa(Register rs1,
Register rs2,
Register rd,
SPARCAssembler.Asi asi) |
void |
casxa(Register rs1,
Register rs2,
Register rd,
SPARCAssembler.Asi asi) |
private void |
cbcond(int cc2,
int i,
SPARCAssembler.ConditionFlag cf,
Register rs1,
int rs2,
Label l) |
void |
cbcondw(SPARCAssembler.ConditionFlag cf,
Register rs1,
int rs2,
Label lab) |
void |
cbcondw(SPARCAssembler.ConditionFlag cf,
Register rs1,
Register rs2,
Label lab) |
void |
cbcondx(SPARCAssembler.ConditionFlag cf,
Register rs1,
int rs2,
Label lab) |
void |
cbcondx(SPARCAssembler.ConditionFlag cf,
Register rs1,
Register rs2,
Label lab) |
void |
fabsd(Register rs2,
Register rd) |
void |
fabss(Register rs2,
Register rd) |
void |
faddd(Register rs1,
Register rs2,
Register rd) |
void |
faddq(Register rs1,
Register rs2,
Register rd) |
void |
fadds(Register rs1,
Register rs2,
Register rd) |
void |
fandd(Register rs1,
Register rs2,
Register rd) |
void |
fbcc(SPARCAssembler.ConditionFlag cond,
SPARCAssembler.Annul annul,
Label l)
Branch on Floating-Point Condition Codes.
|
void |
fbpcc(SPARCAssembler.ConditionFlag cond,
SPARCAssembler.Annul annul,
Label l,
SPARCAssembler.CC cc,
SPARCAssembler.BranchPredict predictTaken)
Branch on Integer Condition Codes with Prediction.
|
void |
fcmp(SPARCAssembler.CC cc,
SPARCAssembler.Opfs opf,
Register rs1,
Register rs2)
Instruction format for fcmp.
|
void |
fdivd(Register rs1,
Register rs2,
Register rd) |
void |
fdivs(Register rs1,
Register rs2,
Register rd) |
void |
fdtoi(Register rs2,
Register rd) |
void |
fdtos(Register rs2,
Register rd) |
void |
fdtox(Register rs2,
Register rd) |
void |
fitod(Register rs2,
Register rd) |
void |
fitos(Register rs2,
Register rd) |
void |
flushw() |
private void |
fmovcc(SPARCAssembler.ConditionFlag cond,
SPARCAssembler.CC cc,
Register rs2,
Register rd,
int opfLow) |
void |
fmovd(Register rs2,
Register rd) |
void |
fmovdcc(SPARCAssembler.ConditionFlag cond,
SPARCAssembler.CC cc,
Register rs2,
Register rd) |
void |
fmovs(Register rs2,
Register rd) |
void |
fmovscc(SPARCAssembler.ConditionFlag cond,
SPARCAssembler.CC cc,
Register rs2,
Register rd) |
protected void |
fmt(int op,
int rd,
int op3,
int rs1,
int b)
Instruction format for most arithmetic stuff.
|
protected void |
fmt00(int a,
int op2,
int b)
Instruction format for Fmt00 instructions.
|
protected void |
fmt10(int rd,
int op3,
int rs1,
int b)
Instruction format for most arithmetic stuff.
|
void |
fmuld(Register rs1,
Register rs2,
Register rd) |
void |
fmuls(Register rs1,
Register rs2,
Register rd) |
void |
fnegd(Register rs2,
Register rd) |
void |
fnegs(Register rs2,
Register rd) |
void |
fpadd32(Register rs1,
Register rs2,
Register rd) |
void |
fsmuld(Register rs1,
Register rs2,
Register rd) |
void |
fsqrtd(Register rs2,
Register rd) |
void |
fsqrts(Register rs2,
Register rd) |
void |
fsrc2d(Register rs2,
Register rd) |
void |
fsrc2s(Register rs2,
Register rd) |
void |
fstod(Register rs2,
Register rd) |
void |
fstoi(Register rs2,
Register rd) |
void |
fstox(Register rs2,
Register rd) |
void |
fsubd(Register rs1,
Register rs2,
Register rd) |
void |
fsubs(Register rs1,
Register rs2,
Register rd) |
void |
fxtod(Register rs2,
Register rd) |
void |
fxtos(Register rs2,
Register rd) |
void |
fzerod(Register rd) |
void |
fzeros(Register rd) |
static int |
getBits(int inst,
int hiBit,
int lowBit) |
Assembler.InstructionCounter |
getInstructionCounter() |
private static SPARCAssembler.Ops |
getOp(int inst) |
private static SPARCAssembler.Op2s |
getOp2(int inst) |
static SPARCAssembler.SPARCOp |
getSPARCOp(int inst) |
private static int |
getXBit(SPARCAssembler.Op3s op3)
Helper method to determine if the instruction needs the X bit set.
|
boolean |
hasFeature(SPARC.CPUFeature feature) |
static int |
hi22(int x) |
void |
illtrap(int const22) |
void |
insertNopAfterCBCond() |
protected static boolean |
isCBCond(int inst) |
static boolean |
isImm(int x,
int nbits) |
private static boolean |
isOp2(SPARCAssembler.Ops ops,
SPARCAssembler.Op2s op2s,
int inst) |
static boolean |
isSimm(long imm,
int nbits)
Test if imm is within signed immediate range for nbits.
|
static boolean |
isSimm10(long imm) |
static boolean |
isSimm11(JavaConstant constant) |
static boolean |
isSimm11(long imm) |
static boolean |
isSimm13(int imm) |
static boolean |
isSimm13(JavaConstant constant) |
static boolean |
isSimm13(long imm) |
static boolean |
isSimm5(JavaConstant constant) |
static boolean |
isWordDisp30(long imm) |
int |
jmpl(Register rs1,
int simm13,
Register rd) |
void |
jmpl(Register rs1,
Register rs2,
Register rd) |
void |
ld(SPARCAddress src,
Register dst,
int bytes,
boolean signed) |
protected void |
ld(SPARCAssembler.Op3s op3,
SPARCAddress addr,
Register rd) |
protected void |
ld(SPARCAssembler.Op3s op3,
SPARCAddress addr,
Register rd,
SPARCAssembler.Asi asi) |
void |
lddf(SPARCAddress src,
Register dst) |
void |
ldf(SPARCAddress src,
Register dst) |
void |
ldsb(SPARCAddress src,
Register dst) |
void |
ldsh(SPARCAddress src,
Register dst) |
void |
ldsw(SPARCAddress src,
Register dst) |
void |
ldub(SPARCAddress src,
Register dst) |
void |
lduh(SPARCAddress src,
Register dst) |
void |
lduw(SPARCAddress src,
Register dst) |
void |
lduwa(Register rs1,
Register rs2,
Register rd,
SPARCAssembler.Asi asi) |
void |
ldx(SPARCAddress src,
Register dst) |
void |
ldxa(Register rs1,
Register rs2,
Register rd,
SPARCAssembler.Asi asi) |
static int |
lo10(int x) |
static long |
maxSimm(long nbits)
Maximum value for signed immediate ranges.
|
void |
membar(int barriers) |
static long |
minSimm(long nbits)
Minimum value for signed immediate ranges.
|
private void |
movcc(SPARCAssembler.ConditionFlag conditionFlag,
SPARCAssembler.CC cc,
int i,
int imm,
Register rd) |
void |
movcc(SPARCAssembler.ConditionFlag conditionFlag,
SPARCAssembler.CC cc,
int simm11,
Register rd) |
void |
movcc(SPARCAssembler.ConditionFlag conditionFlag,
SPARCAssembler.CC cc,
Register rs2,
Register rd) |
void |
movdtox(Register rs2,
Register rd) |
void |
movstosw(Register rs2,
Register rd) |
void |
movstouw(Register rs2,
Register rd) |
void |
movwtos(Register rs2,
Register rd) |
void |
movxtod(Register rs2,
Register rd) |
void |
mulx(Register rs1,
int simm13,
Register rd) |
void |
mulx(Register rs1,
Register rs2,
Register rd) |
void |
nop()
NOP.
|
protected void |
op3(SPARCAssembler.Op3s op3,
Register rs1,
int simm13,
Register rd) |
protected void |
op3(SPARCAssembler.Op3s op3,
Register rs1,
Register rs2,
Register rd) |
private void |
op3(SPARCAssembler.Op3s op3,
SPARCAssembler.Opfs opf,
Register rs1,
Register rs2,
Register rd) |
private void |
optimizeDelaySlot(int i)
Optimizes branch instruction b which has a nop in the delay slot.
|
void |
or(Register rs1,
int simm13,
Register rd) |
void |
or(Register rs1,
Register rs2,
Register rd) |
void |
patchAddImmediate(int position,
int simm13) |
protected int |
patchUnbound(Label label) |
void |
peephole()
Does peephole optimization on code generated by this assembler.
|
void |
popc(int simm13,
Register rd) |
void |
popc(Register rs2,
Register rd) |
void |
prefetch(SPARCAddress addr,
SPARCAssembler.Fcn fcn) |
void |
rdpc(Register rd) |
void |
restore(Register rs1,
Register rs2,
Register rd) |
void |
save(Register rs1,
int simm13,
Register rd) |
void |
save(Register rs1,
Register rs2,
Register rd) |
void |
sdivx(Register rs1,
int simm13,
Register rd) |
void |
sdivx(Register rs1,
Register rs2,
Register rd) |
void |
sethi(int imm22,
Register dst) |
static int |
simm(int x,
int nbits) |
void |
sll(Register rs1,
int shcnt32,
Register rd) |
void |
sll(Register rs1,
Register rs2,
Register rd) |
void |
sllx(Register rs1,
int shcnt64,
Register rd) |
void |
sllx(Register rs1,
Register rs2,
Register rd) |
void |
sra(Register rs1,
int simm13,
Register rd) |
void |
sra(Register rs1,
Register rs2,
Register rd) |
void |
srax(Register rs1,
int shcnt64,
Register rd) |
void |
srax(Register rs1,
Register rs2,
Register rd) |
void |
srl(Register rs1,
int simm13,
Register rd) |
void |
srl(Register rs1,
Register rs2,
Register rd) |
void |
srlx(Register rs1,
int shcnt64,
Register rd) |
void |
srlx(Register rs1,
Register rs2,
Register rd) |
protected void |
st(SPARCAssembler.Op3s op3,
Register rs1,
SPARCAddress dest) |
void |
stb(Register rd,
SPARCAddress addr) |
void |
stdf(Register rd,
SPARCAddress addr) |
void |
stf(Register rd,
SPARCAddress addr) |
void |
sth(Register rd,
SPARCAddress addr) |
void |
stw(Register rd,
SPARCAddress addr) |
void |
stx(Register rd,
SPARCAddress addr) |
void |
sub(Register rs1,
int simm13,
Register rd) |
void |
sub(Register rs1,
Register rs2,
Register rd) |
void |
subcc(Register rs1,
int simm13,
Register rd) |
void |
subcc(Register rs1,
Register rs2,
Register rd) |
void |
ta(int trap) |
void |
tcc(SPARCAssembler.CC cc,
SPARCAssembler.ConditionFlag flag,
int trap) |
void |
udivx(Register rs1,
int simm13,
Register rd) |
void |
udivx(Register rs1,
Register rs2,
Register rd) |
void |
umulxhi(Register rs1,
Register rs2,
Register rd) |
void |
wrccr(Register rs1,
int simm13) |
void |
wrccr(Register rs1,
Register rs2) |
void |
xnor(Register rs1,
int simm13,
Register rd) |
void |
xnor(Register rs1,
Register rs2,
Register rd) |
void |
xor(Register rs1,
int simm13,
Register rd) |
void |
xor(Register rs1,
Register rs2,
Register rd) |
void |
xorcc(Register rs1,
int simm13,
Register rd) |
void |
xorcc(Register rs1,
Register rs2,
Register rd) |
align, bind, close, createLabelName, emitByte, emitByte, emitInt, emitInt, emitLong, emitLong, emitShort, emitShort, emitString, emitString, emitString0, ensureUniquePC, getByte, getInt, getPlaceholder, getShort, jmp, makeAddress, nameOf, patchJumpTarget, position, requestLabelHint, reset
public static final int CCR_ICC_SHIFT
public static final int CCR_XCC_SHIFT
public static final int CCR_V_SHIFT
protected static final int OP2_SHIFT
protected static final int OP2_MASK
protected static final int DISP22_SHIFT
protected static final int DISP22_MASK
protected static final int DISP19_SHIFT
protected static final int DISP19_MASK
protected static final int D16HI_SHIFT
protected static final int D16HI_MASK
protected static final int D16LO_SHIFT
protected static final int D16LO_MASK
protected static final int D10LO_MASK
protected static final int D10HI_MASK
protected static final int D10LO_SHIFT
protected static final int D10HI_SHIFT
private static final SPARCAssembler.Ops[] OPS
private static final SPARCAssembler.Op2s[] OP2S
private static final SPARCAssembler.Op3s[][] OP3S
private ArrayList<Integer> delaySlotOptimizationPoints
public static final SPARCAssembler.Bpcc BPCC
public static final SPARCAssembler.Bpcc FBPCC
public static final SPARCAssembler.CBCond CBCOND
public static final SPARCAssembler.Bpr BPR
public static final SPARCAssembler.Br BR
public static final SPARCAssembler.Sethi SETHI
public static final SPARCAssembler.Op3Op OP3
public static final SPARCAssembler.SPARCOp LDST
public static final SPARCAssembler.SPARCOp BRANCH
public static final SPARCAssembler.SPARCOp CALL
private static final SPARCAssembler.BitKeyIndex INDEX
public static final int PC_RETURN_OFFSET
public SPARCAssembler(TargetDescription target, RegisterConfig registerConfig)
registerConfig
- the register configuration used to bind Register.Frame
and
Register.CallerFrame
to physical registers. This value can be null if this
assembler instance will not be used to assemble instructions using these logical
registers.public static SPARCAssembler.SPARCOp getSPARCOp(int inst)
public boolean hasFeature(SPARC.CPUFeature feature)
public static final int simm(int x, int nbits)
public static final boolean isImm(int x, int nbits)
public static long minSimm(long nbits)
public static long maxSimm(long nbits)
public static boolean isSimm(long imm, int nbits)
public static boolean isSimm10(long imm)
public static boolean isSimm11(long imm)
public static boolean isSimm11(JavaConstant constant)
public static boolean isSimm5(JavaConstant constant)
public static boolean isSimm13(int imm)
public static boolean isSimm13(JavaConstant constant)
public static boolean isSimm13(long imm)
public static boolean isWordDisp30(long imm)
public static final int hi22(int x)
public static final int lo10(int x)
protected void fmt00(int a, int op2, int b)
| 00 | a | op2 | b | |31 30|29 25|24 22|21 0|
private void op3(SPARCAssembler.Op3s op3, SPARCAssembler.Opfs opf, Register rs1, Register rs2, Register rd)
protected void op3(SPARCAssembler.Op3s op3, Register rs1, Register rs2, Register rd)
protected void op3(SPARCAssembler.Op3s op3, Register rs1, int simm13, Register rd)
public void bicc(SPARCAssembler.ConditionFlag cond, SPARCAssembler.Annul annul, Label l)
| 00 |annul| cond| 010 | disp22 | |31 30|29 |28 25|24 22|21 0|
public void fbcc(SPARCAssembler.ConditionFlag cond, SPARCAssembler.Annul annul, Label l)
| 00 |annul| cond| 110 | disp22 | |31 30|29 |28 25|24 22|21 0|
private void bcc(SPARCAssembler.Op2s op2, SPARCAssembler.ConditionFlag cond, SPARCAssembler.Annul annul, Label l)
| 00 |annul| cond| op2 | disp22 | |31 30|29 |28 25|24 22|21 0|
public void insertNopAfterCBCond()
protected static boolean isCBCond(int inst)
private static boolean isOp2(SPARCAssembler.Ops ops, SPARCAssembler.Op2s op2s, int inst)
private static SPARCAssembler.Ops getOp(int inst)
private static SPARCAssembler.Op2s getOp2(int inst)
public static int getBits(int inst, int hiBit, int lowBit)
public void bpcc(SPARCAssembler.ConditionFlag cond, SPARCAssembler.Annul annul, Label l, SPARCAssembler.CC cc, SPARCAssembler.BranchPredict predictTaken)
| 00 |an|cond | 001 |cc1 2|p | disp19 | |31 30|29|28 25|24 22|21 20|19| 0|
public void fbpcc(SPARCAssembler.ConditionFlag cond, SPARCAssembler.Annul annul, Label l, SPARCAssembler.CC cc, SPARCAssembler.BranchPredict predictTaken)
| 00 |an|cond | 101 |cc1 2|p | disp19 | |31 30|29|28 25|24 22|21 20|19| 0|
private void bpcc(SPARCAssembler.Op2s op2, SPARCAssembler.ConditionFlag cond, SPARCAssembler.Annul annul, Label l, SPARCAssembler.CC cc, SPARCAssembler.BranchPredict predictTaken)
| 00 |an|cond | op2 |cc1 2|p | disp19 | |31 30|29|28 25|24 22|21 20|19| 0|
public void bpr(SPARCAssembler.RCondition cond, SPARCAssembler.Annul annul, Label l, SPARCAssembler.BranchPredict predictTaken, Register rs1)
| 00 |an| 0|rcond | 011 |d16hi|p | rs1 | d16lo | |31 30|29|28|27 25 |24 22|21 20|19|18 14| 0|
protected int patchUnbound(Label label)
public void cbcondw(SPARCAssembler.ConditionFlag cf, Register rs1, Register rs2, Label lab)
public void cbcondw(SPARCAssembler.ConditionFlag cf, Register rs1, int rs2, Label lab)
public void cbcondx(SPARCAssembler.ConditionFlag cf, Register rs1, Register rs2, Label lab)
public void cbcondx(SPARCAssembler.ConditionFlag cf, Register rs1, int rs2, Label lab)
private void cbcond(int cc2, int i, SPARCAssembler.ConditionFlag cf, Register rs1, int rs2, Label l)
public void nop()
| 00 |00000| 100 | 0 | |31 30|29 25|24 22|21 0|
public int call(int disp30)
| 01 | disp30 | |31 30|29 0|
private static int getXBit(SPARCAssembler.Op3s op3)
public void flushw()
public void fcmp(SPARCAssembler.CC cc, SPARCAssembler.Opfs opf, Register rs1, Register rs2)
| 10 | --- |cc1|cc0|desc | rs1 | opf | rs2 | |31 30|29 27|26 |25 |24 19|18 14|13 5|4 0|
protected void fmt10(int rd, int op3, int rs1, int b)
| 10 | rd | op3 | rs1 | b | |31 30|29 25|24 19|18 14|13 0|
protected void fmt(int op, int rd, int op3, int rs1, int b)
| op | rd | op3 | rs1 | b | |31 30|29 25|24 19|18 14|13 0|
public void illtrap(int const22)
public int jmpl(Register rs1, int simm13, Register rd)
public void fmovdcc(SPARCAssembler.ConditionFlag cond, SPARCAssembler.CC cc, Register rs2, Register rd)
public void fmovscc(SPARCAssembler.ConditionFlag cond, SPARCAssembler.CC cc, Register rs2, Register rd)
private void fmovcc(SPARCAssembler.ConditionFlag cond, SPARCAssembler.CC cc, Register rs2, Register rd, int opfLow)
public void movcc(SPARCAssembler.ConditionFlag conditionFlag, SPARCAssembler.CC cc, Register rs2, Register rd)
public void movcc(SPARCAssembler.ConditionFlag conditionFlag, SPARCAssembler.CC cc, int simm11, Register rd)
private void movcc(SPARCAssembler.ConditionFlag conditionFlag, SPARCAssembler.CC cc, int i, int imm, Register rd)
public void prefetch(SPARCAddress addr, SPARCAssembler.Fcn fcn)
public void ta(int trap)
public void tcc(SPARCAssembler.CC cc, SPARCAssembler.ConditionFlag flag, int trap)
protected void ld(SPARCAssembler.Op3s op3, SPARCAddress addr, Register rd, SPARCAssembler.Asi asi)
protected void ld(SPARCAssembler.Op3s op3, SPARCAddress addr, Register rd)
public void lddf(SPARCAddress src, Register dst)
public void ldf(SPARCAddress src, Register dst)
public void lduh(SPARCAddress src, Register dst)
public void ldsh(SPARCAddress src, Register dst)
public void ld(SPARCAddress src, Register dst, int bytes, boolean signed)
public void ldub(SPARCAddress src, Register dst)
public void ldsb(SPARCAddress src, Register dst)
public void lduw(SPARCAddress src, Register dst)
public void ldsw(SPARCAddress src, Register dst)
public void ldx(SPARCAddress src, Register dst)
public void ldxa(Register rs1, Register rs2, Register rd, SPARCAssembler.Asi asi)
public void lduwa(Register rs1, Register rs2, Register rd, SPARCAssembler.Asi asi)
protected void st(SPARCAssembler.Op3s op3, Register rs1, SPARCAddress dest)
public void stdf(Register rd, SPARCAddress addr)
public void stf(Register rd, SPARCAddress addr)
public void stb(Register rd, SPARCAddress addr)
public void sth(Register rd, SPARCAddress addr)
public void stw(Register rd, SPARCAddress addr)
public void stx(Register rd, SPARCAddress addr)
public void membar(int barriers)
public void casa(Register rs1, Register rs2, Register rd, SPARCAssembler.Asi asi)
public void casxa(Register rs1, Register rs2, Register rd, SPARCAssembler.Asi asi)
public Assembler.InstructionCounter getInstructionCounter()
getInstructionCounter
in class Assembler
public void patchAddImmediate(int position, int simm13)
public void peephole()
It searches for conditional branch instructions which has nop in the delay slot then looks at the instruction at branch target; if it is an arithmetic instruction, which does not throw an exception (e.g. division), it pulls this instruction into the delay slot and increments the displacement by 1.
private void optimizeDelaySlot(int i)
If bs branch target instruction is an unconditional branch t, then it tries to put ts delayed instruction into the delay slot of b and add the ts disp field to bs disp field.