mirror of
https://github.com/golang/go
synced 2024-11-22 02:04:40 -07:00
5a, 5l: add LDREXD, STREXD
R=ken2 CC=golang-dev https://golang.org/cl/4239041
This commit is contained in:
parent
ad8b0d915b
commit
96c785de39
@ -364,7 +364,9 @@ struct
|
||||
"MOVWF", LTYPE3, AMOVWF,
|
||||
|
||||
"LDREX", LTYPE3, ALDREX,
|
||||
"LDREXD", LTYPE3, ALDREXD,
|
||||
"STREX", LTYPE9, ASTREX,
|
||||
"STREXD", LTYPE9, ASTREXD,
|
||||
|
||||
/*
|
||||
"ABSF", LTYPEI, AABSF,
|
||||
|
@ -179,6 +179,9 @@ enum as
|
||||
|
||||
ALDREX,
|
||||
ASTREX,
|
||||
|
||||
ALDREXD,
|
||||
ASTREXD,
|
||||
|
||||
ALAST,
|
||||
};
|
||||
|
@ -1463,7 +1463,7 @@ if(debug['G']) print("%ux: %s: arm %d %d %d\n", (uint32)(p->pc), p->from.sym->na
|
||||
aclass(&p->from);
|
||||
if(instoffset != 0)
|
||||
diag("offset must be zero in STREX");
|
||||
o1 = (0x3<<23) | (0xf9<<4);
|
||||
o1 = (0x18<<20) | (0xf90);
|
||||
o1 |= p->from.reg << 16;
|
||||
o1 |= p->reg << 0;
|
||||
o1 |= p->to.reg << 12;
|
||||
@ -1553,6 +1553,25 @@ if(debug['G']) print("%ux: %s: arm %d %d %d\n", (uint32)(p->pc), p->from.sym->na
|
||||
o1 = oprrr(ACMP+AEND, p->scond);
|
||||
o1 |= p->from.reg<<16;
|
||||
break;
|
||||
case 91: /* ldrexd oreg,reg */
|
||||
aclass(&p->from);
|
||||
if(instoffset != 0)
|
||||
diag("offset must be zero in LDREX");
|
||||
o1 = (0x1b<<20) | (0xf9f);
|
||||
o1 |= p->from.reg << 16;
|
||||
o1 |= p->to.reg << 12;
|
||||
o1 |= (p->scond & C_SCOND) << 28;
|
||||
break;
|
||||
case 92: /* strexd reg,oreg,reg */
|
||||
aclass(&p->from);
|
||||
if(instoffset != 0)
|
||||
diag("offset must be zero in STREX");
|
||||
o1 = (0x1a<<20) | (0xf90);
|
||||
o1 |= p->from.reg << 16;
|
||||
o1 |= p->reg << 0;
|
||||
o1 |= p->to.reg << 12;
|
||||
o1 |= (p->scond & C_SCOND) << 28;
|
||||
break;
|
||||
}
|
||||
|
||||
out[0] = o1;
|
||||
|
@ -253,5 +253,8 @@ Optab optab[] =
|
||||
|
||||
{ ATST, C_REG, C_NONE, C_NONE, 90, 4, 0 },
|
||||
|
||||
{ ALDREXD, C_SOREG,C_NONE, C_REG, 91, 4, 0 },
|
||||
{ ASTREXD, C_SOREG,C_REG, C_REG, 92, 4, 0 },
|
||||
|
||||
{ AXXX, C_NONE, C_NONE, C_NONE, 0, 4, 0 },
|
||||
};
|
||||
|
@ -1054,6 +1054,8 @@ buildop(void)
|
||||
|
||||
case ALDREX:
|
||||
case ASTREX:
|
||||
case ALDREXD:
|
||||
case ASTREXD:
|
||||
case ATST:
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user