diff options
author | Jim Wilson <wilson@tuliptree.org> | 1992-08-31 17:14:50 +0000 |
---|---|---|
committer | Jim Wilson <wilson@tuliptree.org> | 1992-08-31 17:14:50 +0000 |
commit | 71703b073583b450d68ec42c4eef085a4f39f2e3 (patch) | |
tree | b02aa3f758ca1d5b40ce6e2623203476cf8240f2 /gas/config/tc-sparc.c | |
parent | 93fd00fbbf104fc022215ecff7cef252bd4babb8 (diff) | |
download | gdb-71703b073583b450d68ec42c4eef085a4f39f2e3.zip gdb-71703b073583b450d68ec42c4eef085a4f39f2e3.tar.gz gdb-71703b073583b450d68ec42c4eef085a4f39f2e3.tar.bz2 |
Update to SPARC Version 9 Draft 1.0.4.
Diffstat (limited to 'gas/config/tc-sparc.c')
-rw-r--r-- | gas/config/tc-sparc.c | 66 |
1 files changed, 27 insertions, 39 deletions
diff --git a/gas/config/tc-sparc.c b/gas/config/tc-sparc.c index afde168..1f6a67e 100644 --- a/gas/config/tc-sparc.c +++ b/gas/config/tc-sparc.c @@ -709,6 +709,10 @@ char *str; the_insn.reloc = RELOC_11; goto immediate; + case 'j': + the_insn.reloc = RELOC_10; + goto immediate; + case 'k': the_insn.reloc = RELOC_WDISP2_14; the_insn.pcrel = 1; @@ -733,13 +737,6 @@ char *str; } break; - case 'Y': - if (strncmp(s, "%amr", 4) == 0) { - s += 4; - continue; - } - break; - case 'z': if (*s == ' ') { ++s; @@ -807,13 +804,6 @@ char *str; } break; - case 'E': - if (strncmp(s, "%modes", 6) == 0) { - s += 6; - continue; - } - break; - case 'W': if (strncmp(s, "%tick", 5) == 0) { s += 5; @@ -987,13 +977,6 @@ char *str; } break; - /* start-sanitize-v9 */ -#ifndef NO_V9 - case 'j': - case 'u': - case 'U': -#endif /* NO_V9 */ - /* end-sanitize-v9 */ case 'e': /* next operand is a floating point register */ case 'v': case 'V': @@ -1029,16 +1012,14 @@ char *str; mask = 10 * mask + (*s - '0'); } /* read the number */ - if ((*args == 'u' - || *args == 'v' + if ((*args == 'v' || *args == 'B' || *args == 'H') && (mask & 1)) { break; } /* register must be even numbered */ - if ((*args == 'U' - || *args == 'V' + if ((*args == 'V' || *args == 'R' || *args == 'J') && (mask & 3)) { @@ -1085,15 +1066,6 @@ char *str; } /* on error */ switch (*args) { - /* start-sanitize-v9 */ -#ifndef NO_V9 - case 'j': - case 'u': - case 'U': - opcode |= (mask & 0x1f) << 9; - continue; -#endif /* NO_V9 */ - /* end-sanitize-v9 */ case 'v': case 'V': @@ -1271,16 +1243,22 @@ char *str; /* start-sanitize-v9 */ #ifndef NO_V9 - case 's': - if (strncmp (s, "%usr", 4) != 0) + case 'o': + if (strncmp (s, "%asi", 4) != 0) break; s += 4; continue; - case 'o': - if (strncmp (s, "%asi", 4) != 0) + case 's': + if (strncmp (s, "%fprs", 5) != 0) break; - s += 4; + s+= 5; + continue; + + case 'E': + if (strncmp (s, "%ccr", 4) != 0) + break; + s+= 4; continue; #endif /* NO_V9 */ /* end-sanitize-v9 */ @@ -1540,6 +1518,16 @@ long val; buf[3] = val & 0xff; break; + case RELOC_10: + if (((val > 0) && (val & ~0x3ff)) + || ((val < 0) && (~(val - 1) & ~0x3ff))) { + as_bad("relocation overflow."); + } /* on overflow */ + + buf[2] = (val >> 8) & 0x3; + buf[3] = val & 0xff; + break; + case RELOC_WDISP2_14: if (((val > 0) && (val & ~0x3fffc)) || ((val < 0) && (~(val - 1) & ~0x3fffc))) { |