diff options
author | Jose E. Marchesi <jose.marchesi@oracle.com> | 2016-06-17 02:15:43 -0700 |
---|---|---|
committer | Jose E. Marchesi <jose.marchesi@oracle.com> | 2016-06-17 02:15:43 -0700 |
commit | 96074adc6a780c7984645e3e42434be368974737 (patch) | |
tree | 92cdfac6666b5231fee8118f3cd85fac36ea4747 /gas | |
parent | 7a10c22feb4dfb7e56855033d579338a6258722d (diff) | |
download | gdb-96074adc6a780c7984645e3e42434be368974737.zip gdb-96074adc6a780c7984645e3e42434be368974737.tar.gz gdb-96074adc6a780c7984645e3e42434be368974737.tar.bz2 |
opcodes,gas: sparc: fix rdasr,wrasr,rdpr,wrpr,rdhpr,wrhpr insns.
This patch fixes and expands the definition of the read/write
instructions for ancillary-state, privileged and hyperprivileged
registers in opcodes.
It also adds support for three new v9m hyperprivileged registers:
%hmcdper, %hmcddfr and %hva_mask_nz.
Finally, the patch expands existing tests (and adds several new ones) in
order to cover all the read/write instructions in all its variants.
opcodes/ChangeLog:
2016-06-17 Jose E. Marchesi <jose.marchesi@oracle.com>
* sparc-opc.c (rdasr): New macro.
(wrasr): Likewise.
(rdpr): Likewise.
(wrpr): Likewise.
(rdhpr): Likewise.
(wrhpr): Likewise.
(sparc_opcodes): Use the macros above to fix and expand the
definition of read/write instructions from/to
asr/privileged/hyperprivileged instructions.
* sparc-dis.c (v9_hpriv_reg_names): Add %hmcdper, %hmcddfr and
%hva_mask_nz. Prefer softint_set and softint_clear over
set_softint and clear_softint.
(print_insn_sparc): Support %ver in Rd.
gas/ChangeLog:
2016-06-17 Jose E. Marchesi <jose.marchesi@oracle.com>
* config/tc-sparc.c (hpriv_reg_table): Add registers %hmcdper,
%hmcddfr and %hva_mask_nz.
(sparc_ip): New handling of asr/privileged/hyperprivileged
registers, adapted to the new form of the sparc opcodes table.
* testsuite/gas/sparc/rdasr.s: New file.
* testsuite/gas/sparc/rdasr.d: Likewise.
* testsuite/gas/sparc/wrasr.s: Likewise.
* testsuite/gas/sparc/wrasr.d: Likewise.
* testsuite/gas/sparc/sparc.exp (sparc_elf_setup): Add rdasr and
wrasr tests.
* testsuite/gas/sparc/rdpr.d: Use -Av9m, as some privileged
registers require it.
* testsuite/gas/sparc/wrpr.s: Complete to cover all privileged
registers and write instruction modalities.
* testsuite/gas/sparc/wrpr.d: Likewise.
* testsuite/gas/sparc/rdhpr.s: Likewise for hyperprivileged
registers.
* testsuite/gas/sparc/rdhpr.d: Likewise.
* testsuite/gas/sparc/wrhpr.s: Likewise.
* testsuite/gas/sparc/wrhpr.d: Likewise.
Diffstat (limited to 'gas')
-rw-r--r-- | gas/ChangeLog | 23 | ||||
-rw-r--r-- | gas/config/tc-sparc.c | 51 | ||||
-rw-r--r-- | gas/testsuite/gas/sparc/rdasr.d | 18 | ||||
-rw-r--r-- | gas/testsuite/gas/sparc/rdasr.s | 11 | ||||
-rw-r--r-- | gas/testsuite/gas/sparc/rdhpr.d | 5 | ||||
-rw-r--r-- | gas/testsuite/gas/sparc/rdhpr.s | 3 | ||||
-rw-r--r-- | gas/testsuite/gas/sparc/rdpr.d | 2 | ||||
-rw-r--r-- | gas/testsuite/gas/sparc/sparc.exp | 2 | ||||
-rw-r--r-- | gas/testsuite/gas/sparc/wrasr.d | 48 | ||||
-rw-r--r-- | gas/testsuite/gas/sparc/wrasr.s | 41 | ||||
-rw-r--r-- | gas/testsuite/gas/sparc/wrhpr.d | 59 | ||||
-rw-r--r-- | gas/testsuite/gas/sparc/wrhpr.s | 57 | ||||
-rw-r--r-- | gas/testsuite/gas/sparc/wrpr.d | 114 | ||||
-rw-r--r-- | gas/testsuite/gas/sparc/wrpr.s | 110 |
14 files changed, 467 insertions, 77 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog index 22017c4..5a44023 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,5 +1,28 @@ 2016-06-17 Jose E. Marchesi <jose.marchesi@oracle.com> + * config/tc-sparc.c (hpriv_reg_table): Add registers %hmcdper, + %hmcddfr and %hva_mask_nz. + (sparc_ip): New handling of asr/privileged/hyperprivileged + registers, adapted to the new form of the sparc opcodes table. + * testsuite/gas/sparc/rdasr.s: New file. + * testsuite/gas/sparc/rdasr.d: Likewise. + * testsuite/gas/sparc/wrasr.s: Likewise. + * testsuite/gas/sparc/wrasr.d: Likewise. + * testsuite/gas/sparc/sparc.exp (sparc_elf_setup): Add rdasr and + wrasr tests. + * testsuite/gas/sparc/rdpr.d: Use -Av9m, as some privileged + registers require it. + * testsuite/gas/sparc/wrpr.s: Complete to cover all privileged + registers and write instruction modalities. + * testsuite/gas/sparc/wrpr.d: Likewise. + * testsuite/gas/sparc/rdhpr.s: Likewise for hyperprivileged + registers. + * testsuite/gas/sparc/rdhpr.d: Likewise. + * testsuite/gas/sparc/wrhpr.s: Likewise. + * testsuite/gas/sparc/wrhpr.d: Likewise. + +2016-06-17 Jose E. Marchesi <jose.marchesi@oracle.com> + * config/tc-sparc.c (sparc_arch_table): adjust the GAS architectures to use the right opcode architecture. (sparc_md_end): Handle v9{c,d,e,v,m}. diff --git a/gas/config/tc-sparc.c b/gas/config/tc-sparc.c index 283e132..163a216 100644 --- a/gas/config/tc-sparc.c +++ b/gas/config/tc-sparc.c @@ -817,6 +817,9 @@ struct priv_reg_entry hpriv_reg_table[] = {"hintp", 3}, {"htba", 5}, {"hver", 6}, + {"hmcdper", 23}, + {"hmcddfr", 24}, + {"hva_mask_nz", 27}, {"hstick_offset", 28}, {"hstick_enable", 29}, {"hstick_cmpr", 31}, @@ -1907,10 +1910,13 @@ sparc_ip (char *str, const struct sparc_opcode **pinsn) error_message = _(": unrecognizable privileged register"); goto error; } - if (*args == '?') - opcode |= (p->regnum << 14); - else - opcode |= (p->regnum << 25); + + if (((opcode >> (*args == '?' ? 14 : 25)) & 0x1f) != (unsigned) p->regnum) + { + error_message = _(": unrecognizable privileged register"); + goto error; + } + s += len; continue; } @@ -1942,11 +1948,14 @@ sparc_ip (char *str, const struct sparc_opcode **pinsn) error_message = _(": unrecognizable hyperprivileged register"); goto error; } - if (*args == '$') - opcode |= (p->regnum << 14); - else - opcode |= (p->regnum << 25); - s += len; + + if (((opcode >> (*args == '$' ? 14 : 25)) & 0x1f) != (unsigned) p->regnum) + { + error_message = _(": unrecognizable hyperprivileged register"); + goto error; + } + + s += len; continue; } else @@ -1977,23 +1986,13 @@ sparc_ip (char *str, const struct sparc_opcode **pinsn) error_message = _(": unrecognizable ancillary state register"); goto error; } - if (*args == '/' && (p->regnum == 20 || p->regnum == 21)) - { - error_message = _(": rd on write only ancillary state register"); - goto error; - } - if (p->regnum >= 24 - && (insn->architecture - & SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_V9A))) - { - /* %sys_tick and %sys_tick_cmpr are v9bnotv9a */ - error_message = _(": unrecognizable v9a ancillary state register"); - goto error; - } - if (*args == '/') - opcode |= (p->regnum << 14); - else - opcode |= (p->regnum << 25); + + if (((opcode >> (*args == '/' ? 14 : 25)) & 0x1f) != (unsigned) p->regnum) + { + error_message = _(": unrecognizable ancillary state register"); + goto error; + } + s += len; continue; } diff --git a/gas/testsuite/gas/sparc/rdasr.d b/gas/testsuite/gas/sparc/rdasr.d new file mode 100644 index 0000000..6acd9c8 --- /dev/null +++ b/gas/testsuite/gas/sparc/rdasr.d @@ -0,0 +1,18 @@ +#as: -64 -Av9m +#objdump: -dr +#name: sparc64 rdasr + +.*: +file format .*sparc.* + +Disassembly of section .text: + +0+ <.text>: + 0: 81 44 00 00 rd %pcr, %g0 + 4: 83 44 40 00 rd %pic, %g1 + 8: 85 44 80 00 rd %dcr, %g2 + c: 87 44 c0 00 rd %gsr, %g3 + 10: 89 45 80 00 rd %softint, %g4 + 14: 8b 45 c0 00 rd %tick_cmpr, %g5 + 18: 8b 46 00 00 rd %stick, %g5 + 1c: 89 46 40 00 rd %stick_cmpr, %g4 + 20: 8d 46 80 00 rd %cfr, %g6 diff --git a/gas/testsuite/gas/sparc/rdasr.s b/gas/testsuite/gas/sparc/rdasr.s new file mode 100644 index 0000000..8499764 --- /dev/null +++ b/gas/testsuite/gas/sparc/rdasr.s @@ -0,0 +1,11 @@ +# Test rdasr + .text + rd %pcr,%g0 + rd %pic,%g1 + rd %dcr,%g2 + rd %gsr,%g3 + rd %softint,%g4 + rd %tick_cmpr,%g5 + rd %sys_tick,%g5 + rd %sys_tick_cmpr,%g4 + rd %cfr,%g6 diff --git a/gas/testsuite/gas/sparc/rdhpr.d b/gas/testsuite/gas/sparc/rdhpr.d index 7a12ad3..81995d5 100644 --- a/gas/testsuite/gas/sparc/rdhpr.d +++ b/gas/testsuite/gas/sparc/rdhpr.d @@ -1,4 +1,4 @@ -#as: -64 -Av9 +#as: -64 -Av9m #objdump: -dr #name: sparc64 rdhpr @@ -15,3 +15,6 @@ Disassembly of section .text: 14: 8d 4f 00 00 rdhpr %hstick_offset, %g6 18: 8b 4f 40 00 rdhpr %hstick_enable, %g5 1c: 89 4f c0 00 rdhpr %hstick_cmpr, %g4 + 20: 8d 4d c0 00 rdhpr %hmcdper, %g6 + 24: 8b 4e 00 00 rdhpr %hmcddfr, %g5 + 28: 89 4e c0 00 rdhpr %hva_mask_nz, %g4 diff --git a/gas/testsuite/gas/sparc/rdhpr.s b/gas/testsuite/gas/sparc/rdhpr.s index 8f669c7..c4cf2de 100644 --- a/gas/testsuite/gas/sparc/rdhpr.s +++ b/gas/testsuite/gas/sparc/rdhpr.s @@ -8,3 +8,6 @@ rdhpr %hstick_offset,%g6 rdhpr %hstick_enable,%g5 rdhpr %hstick_cmpr,%g4 + rdhpr %hmcdper,%g6 + rdhpr %hmcddfr,%g5 + rdhpr %hva_mask_nz,%g4 diff --git a/gas/testsuite/gas/sparc/rdpr.d b/gas/testsuite/gas/sparc/rdpr.d index 58ec2ef..d9e9972 100644 --- a/gas/testsuite/gas/sparc/rdpr.d +++ b/gas/testsuite/gas/sparc/rdpr.d @@ -1,4 +1,4 @@ -#as: -64 -Av9 +#as: -64 -Av9m #objdump: -dr #name: sparc64 rdpr diff --git a/gas/testsuite/gas/sparc/sparc.exp b/gas/testsuite/gas/sparc/sparc.exp index 3e7cc4c..0a6a494 100644 --- a/gas/testsuite/gas/sparc/sparc.exp +++ b/gas/testsuite/gas/sparc/sparc.exp @@ -56,8 +56,10 @@ if [istarget sparc*-*-*] { run_dump_test "prefetch" run_dump_test "set64" run_dump_test "synth64" + run_dump_test "rdasr" run_dump_test "rdpr" run_dump_test "rdhpr" + run_dump_test "wrasr" run_dump_test "wrpr" run_dump_test "wrhpr" run_dump_test "window" diff --git a/gas/testsuite/gas/sparc/wrasr.d b/gas/testsuite/gas/sparc/wrasr.d new file mode 100644 index 0000000..93729c7 --- /dev/null +++ b/gas/testsuite/gas/sparc/wrasr.d @@ -0,0 +1,48 @@ +#as: -64 -Av9m +#objdump: -dr +#name: sparc64 wrasr + +.*: +file format .*sparc.* + +Disassembly of section .text: + +0+ <.text>: + 0: a1 80 40 02 wr %g1, %g2, %pcr + 4: a1 80 62 9a wr %g1, 0x29a, %pcr + 8: a1 80 62 9a wr %g1, 0x29a, %pcr + c: a3 80 40 02 wr %g1, %g2, %pic + 10: a3 80 62 9a wr %g1, 0x29a, %pic + 14: a3 80 62 9a wr %g1, 0x29a, %pic + 18: a5 80 40 02 wr %g1, %g2, %dcr + 1c: a5 80 62 9a wr %g1, 0x29a, %dcr + 20: a5 80 62 9a wr %g1, 0x29a, %dcr + 24: a7 80 40 02 wr %g1, %g2, %gsr + 28: a7 80 62 9a wr %g1, 0x29a, %gsr + 2c: a7 80 62 9a wr %g1, 0x29a, %gsr + 30: a9 80 40 02 wr %g1, %g2, %softint_set + 34: a9 80 62 9a wr %g1, 0x29a, %softint_set + 38: a9 80 62 9a wr %g1, 0x29a, %softint_set + 3c: ab 80 40 02 wr %g1, %g2, %softint_clear + 40: ab 80 62 9a wr %g1, 0x29a, %softint_clear + 44: ab 80 62 9a wr %g1, 0x29a, %softint_clear + 48: ad 80 40 02 wr %g1, %g2, %softint + 4c: ad 80 62 9a wr %g1, 0x29a, %softint + 50: ad 80 62 9a wr %g1, 0x29a, %softint + 54: af 80 40 02 wr %g1, %g2, %tick_cmpr + 58: af 80 62 9a wr %g1, 0x29a, %tick_cmpr + 5c: af 80 62 9a wr %g1, 0x29a, %tick_cmpr + 60: b1 80 40 02 wr %g1, %g2, %stick + 64: b1 80 62 9a wr %g1, 0x29a, %stick + 68: b1 80 62 9a wr %g1, 0x29a, %stick + 6c: b3 80 40 02 wr %g1, %g2, %stick_cmpr + 70: b3 80 62 9a wr %g1, 0x29a, %stick_cmpr + 74: b3 80 62 9a wr %g1, 0x29a, %stick_cmpr + 78: b5 80 40 02 wr %g1, %g2, %cfr + 7c: b5 80 62 9a wr %g1, 0x29a, %cfr + 80: b5 80 62 9a wr %g1, 0x29a, %cfr + 84: b7 80 40 02 wr %g1, %g2, %pause + 88: b7 80 62 9a wr %g1, 0x29a, %pause + 8c: b7 80 62 9a wr %g1, 0x29a, %pause + 90: b9 80 40 02 wr %g1, %g2, %mwait + 94: b9 80 62 9a wr %g1, 0x29a, %mwait + 98: b9 80 62 9a wr %g1, 0x29a, %mwait diff --git a/gas/testsuite/gas/sparc/wrasr.s b/gas/testsuite/gas/sparc/wrasr.s new file mode 100644 index 0000000..07f858e --- /dev/null +++ b/gas/testsuite/gas/sparc/wrasr.s @@ -0,0 +1,41 @@ +# Test wrasr + .text + wr %g1, %g2, %pcr + wr %g1, 666, %pcr + wr 666, %g1, %pcr + wr %g1, %g2, %pic + wr %g1, 666, %pic + wr 666, %g1, %pic + wr %g1, %g2, %dcr + wr %g1, 666, %dcr + wr 666, %g1, %dcr + wr %g1, %g2, %gsr + wr %g1, 666, %gsr + wr 666, %g1, %gsr + wr %g1, %g2, %softint_set + wr %g1, 666, %softint_set + wr 666, %g1, %softint_set + wr %g1, %g2, %softint_clear + wr %g1, 666, %softint_clear + wr 666, %g1, %softint_clear + wr %g1, %g2, %softint + wr %g1, 666, %softint + wr 666, %g1, %softint + wr %g1, %g2, %tick_cmpr + wr %g1, 666, %tick_cmpr + wr 666, %g1, %tick_cmpr + wr %g1, %g2, %sys_tick + wr %g1, 666, %sys_tick + wr 666, %g1, %sys_tick + wr %g1, %g2, %sys_tick_cmpr + wr %g1, 666, %sys_tick_cmpr + wr 666, %g1, %sys_tick_cmpr + wr %g1, %g2, %cfr + wr %g1, 666, %cfr + wr 666, %g1, %cfr + wr %g1, %g2, %pause + wr %g1, 666, %pause + wr 666, %g1, %pause + wr %g1, %g2, %mwait + wr %g1, 666, %mwait + wr 666, %g1, %mwait diff --git a/gas/testsuite/gas/sparc/wrhpr.d b/gas/testsuite/gas/sparc/wrhpr.d index 67d7de3..5b31625 100644 --- a/gas/testsuite/gas/sparc/wrhpr.d +++ b/gas/testsuite/gas/sparc/wrhpr.d @@ -1,4 +1,4 @@ -#as: -64 -Av9 +#as: -64 -Av9m #objdump: -dr #name: sparc64 wrhpr @@ -7,10 +7,53 @@ Disassembly of section .text: 0+ <.text>: - 0: 81 98 40 00 wrhpr %g1, %hpstate - 4: 83 98 80 00 wrhpr %g2, %htstate - 8: 87 98 c0 00 wrhpr %g3, %hintp - c: 8b 99 00 00 wrhpr %g4, %htba - 10: b9 99 40 00 wrhpr %g5, %hstick_offset - 14: bb 99 80 00 wrhpr %g6, %hstick_enable - 18: bf 99 c0 00 wrhpr %g7, %hstick_cmpr + 0: 81 98 40 02 wrhpr %g1, %g2, %hpstate + 4: 81 98 40 00 wrhpr %g1, %hpstate + 8: 81 98 62 9a wrhpr %g1, 0x29a, %hpstate + c: 81 98 62 9a wrhpr %g1, 0x29a, %hpstate + 10: 81 98 22 9a wrhpr 0x29a, %hpstate + 14: 83 98 40 02 wrhpr %g1, %g2, %htstate + 18: 83 98 40 00 wrhpr %g1, %htstate + 1c: 83 98 62 9a wrhpr %g1, 0x29a, %htstate + 20: 83 98 62 9a wrhpr %g1, 0x29a, %htstate + 24: 83 98 22 9a wrhpr 0x29a, %htstate + 28: 87 98 40 02 wrhpr %g1, %g2, %hintp + 2c: 87 98 40 00 wrhpr %g1, %hintp + 30: 87 98 62 9a wrhpr %g1, 0x29a, %hintp + 34: 87 98 62 9a wrhpr %g1, 0x29a, %hintp + 38: 87 98 22 9a wrhpr 0x29a, %hintp + 3c: 8b 98 40 02 wrhpr %g1, %g2, %htba + 40: 8b 98 40 00 wrhpr %g1, %htba + 44: 8b 98 62 9a wrhpr %g1, 0x29a, %htba + 48: 8b 98 62 9a wrhpr %g1, 0x29a, %htba + 4c: 8b 98 22 9a wrhpr 0x29a, %htba + 50: af 98 40 02 wrhpr %g1, %g2, %hmcdper + 54: af 98 40 00 wrhpr %g1, %hmcdper + 58: af 98 62 9a wrhpr %g1, 0x29a, %hmcdper + 5c: af 98 62 9a wrhpr %g1, 0x29a, %hmcdper + 60: af 98 22 9a wrhpr 0x29a, %hmcdper + 64: b1 98 40 02 wrhpr %g1, %g2, %hmcddfr + 68: b1 98 40 00 wrhpr %g1, %hmcddfr + 6c: b1 98 62 9a wrhpr %g1, 0x29a, %hmcddfr + 70: b1 98 62 9a wrhpr %g1, 0x29a, %hmcddfr + 74: b1 98 22 9a wrhpr 0x29a, %hmcddfr + 78: b7 98 40 02 wrhpr %g1, %g2, %hva_mask_nz + 7c: b7 98 40 00 wrhpr %g1, %hva_mask_nz + 80: b7 98 62 9a wrhpr %g1, 0x29a, %hva_mask_nz + 84: b7 98 62 9a wrhpr %g1, 0x29a, %hva_mask_nz + 88: b7 98 22 9a wrhpr 0x29a, %hva_mask_nz + 8c: b9 98 40 02 wrhpr %g1, %g2, %hstick_offset + 90: b9 98 40 00 wrhpr %g1, %hstick_offset + 94: b9 98 62 9a wrhpr %g1, 0x29a, %hstick_offset + 98: b9 98 62 9a wrhpr %g1, 0x29a, %hstick_offset + 9c: b9 98 22 9a wrhpr 0x29a, %hstick_offset + a0: bb 98 40 02 wrhpr %g1, %g2, %hstick_enable + a4: bb 98 40 00 wrhpr %g1, %hstick_enable + a8: bb 98 62 9a wrhpr %g1, 0x29a, %hstick_enable + ac: bb 98 62 9a wrhpr %g1, 0x29a, %hstick_enable + b0: bb 98 22 9a wrhpr 0x29a, %hstick_enable + b4: bf 98 40 02 wrhpr %g1, %g2, %hstick_cmpr + b8: bf 98 40 00 wrhpr %g1, %hstick_cmpr + bc: bf 98 62 9a wrhpr %g1, 0x29a, %hstick_cmpr + c0: bf 98 62 9a wrhpr %g1, 0x29a, %hstick_cmpr + c4: bf 98 22 9a wrhpr 0x29a, %hstick_cmpr diff --git a/gas/testsuite/gas/sparc/wrhpr.s b/gas/testsuite/gas/sparc/wrhpr.s index b93733e..2588990 100644 --- a/gas/testsuite/gas/sparc/wrhpr.s +++ b/gas/testsuite/gas/sparc/wrhpr.s @@ -1,9 +1,52 @@ # Test wrpr .text - wrhpr %g1,%hpstate - wrhpr %g2,%htstate - wrhpr %g3,%hintp - wrhpr %g4,%htba - wrhpr %g5,%hstick_offset - wrhpr %g6,%hstick_enable - wrhpr %g7,%hstick_cmpr + wrhpr %g1, %g2, %hpstate + wrhpr %g1, %hpstate + wrhpr %g1,666, %hpstate + wrhpr 666, %g1, %hpstate + wrhpr 666, %hpstate + wrhpr %g1, %g2, %htstate + wrhpr %g1, %htstate + wrhpr %g1,666, %htstate + wrhpr 666, %g1, %htstate + wrhpr 666, %htstate + wrhpr %g1, %g2, %hintp + wrhpr %g1, %hintp + wrhpr %g1,666, %hintp + wrhpr 666, %g1, %hintp + wrhpr 666, %hintp + wrhpr %g1, %g2, %htba + wrhpr %g1, %htba + wrhpr %g1,666, %htba + wrhpr 666, %g1, %htba + wrhpr 666, %htba + wrhpr %g1, %g2, %hmcdper + wrhpr %g1, %hmcdper + wrhpr %g1,666, %hmcdper + wrhpr 666, %g1, %hmcdper + wrhpr 666, %hmcdper + wrhpr %g1, %g2, %hmcddfr + wrhpr %g1, %hmcddfr + wrhpr %g1,666, %hmcddfr + wrhpr 666, %g1, %hmcddfr + wrhpr 666, %hmcddfr + wrhpr %g1, %g2, %hva_mask_nz + wrhpr %g1, %hva_mask_nz + wrhpr %g1,666, %hva_mask_nz + wrhpr 666, %g1, %hva_mask_nz + wrhpr 666, %hva_mask_nz + wrhpr %g1, %g2, %hstick_offset + wrhpr %g1, %hstick_offset + wrhpr %g1,666, %hstick_offset + wrhpr 666, %g1, %hstick_offset + wrhpr 666, %hstick_offset + wrhpr %g1, %g2, %hstick_enable + wrhpr %g1, %hstick_enable + wrhpr %g1,666, %hstick_enable + wrhpr 666, %g1, %hstick_enable + wrhpr 666, %hstick_enable + wrhpr %g1, %g2, %hstick_cmpr + wrhpr %g1, %hstick_cmpr + wrhpr %g1,666, %hstick_cmpr + wrhpr 666, %g1, %hstick_cmpr + wrhpr 666, %hstick_cmpr diff --git a/gas/testsuite/gas/sparc/wrpr.d b/gas/testsuite/gas/sparc/wrpr.d index 5a9b6f9..7b724f3 100644 --- a/gas/testsuite/gas/sparc/wrpr.d +++ b/gas/testsuite/gas/sparc/wrpr.d @@ -1,4 +1,4 @@ -#as: -64 -Av9 +#as: -64 -Av9m #objdump: -dr #name: sparc64 wrpr @@ -7,20 +7,98 @@ Disassembly of section .text: 0+ <.text>: - 0: 81 90 40 00 wrpr %g1, %tpc - 4: 83 90 80 00 wrpr %g2, %tnpc - 8: 85 90 c0 00 wrpr %g3, %tstate - c: 87 91 00 00 wrpr %g4, %tt - 10: 89 91 40 00 wrpr %g5, %tick - 14: 8b 91 80 00 wrpr %g6, %tba - 18: 8d 91 c0 00 wrpr %g7, %pstate - 1c: 8f 92 00 00 wrpr %o0, %tl - 20: 91 92 40 00 wrpr %o1, %pil - 24: 93 92 80 00 wrpr %o2, %cwp - 28: 95 92 c0 00 wrpr %o3, %cansave - 2c: 97 93 00 00 wrpr %o4, %canrestore - 30: 99 93 40 00 wrpr %o5, %cleanwin - 34: 9b 93 80 00 wrpr %sp, %otherwin - 38: 9d 93 c0 00 wrpr %o7, %wstate - 3c: a1 94 00 00 wrpr %l0, %gl - 40: af 94 c0 00 wrpr %l3, %pmcdper + 0: 81 90 40 02 wrpr %g1, %g2, %tpc + 4: 81 90 40 00 wrpr %g1, %tpc + 8: 81 90 62 9a wrpr %g1, 0x29a, %tpc + c: 81 90 62 9a wrpr %g1, 0x29a, %tpc + 10: 81 90 22 9a wrpr 0x29a, %tpc + 14: 83 90 40 02 wrpr %g1, %g2, %tnpc + 18: 83 90 40 00 wrpr %g1, %tnpc + 1c: 83 90 62 9a wrpr %g1, 0x29a, %tnpc + 20: 83 90 62 9a wrpr %g1, 0x29a, %tnpc + 24: 83 90 22 9a wrpr 0x29a, %tnpc + 28: 85 90 40 02 wrpr %g1, %g2, %tstate + 2c: 85 90 40 00 wrpr %g1, %tstate + 30: 85 90 62 9a wrpr %g1, 0x29a, %tstate + 34: 85 90 62 9a wrpr %g1, 0x29a, %tstate + 38: 85 90 22 9a wrpr 0x29a, %tstate + 3c: 87 90 40 02 wrpr %g1, %g2, %tt + 40: 87 90 40 00 wrpr %g1, %tt + 44: 87 90 62 9a wrpr %g1, 0x29a, %tt + 48: 87 90 62 9a wrpr %g1, 0x29a, %tt + 4c: 87 90 22 9a wrpr 0x29a, %tt + 50: 89 90 40 02 wrpr %g1, %g2, %tick + 54: 89 90 40 00 wrpr %g1, %tick + 58: 89 90 62 9a wrpr %g1, 0x29a, %tick + 5c: 89 90 62 9a wrpr %g1, 0x29a, %tick + 60: 89 90 22 9a wrpr 0x29a, %tick + 64: 8b 90 40 02 wrpr %g1, %g2, %tba + 68: 8b 90 40 00 wrpr %g1, %tba + 6c: 8b 90 62 9a wrpr %g1, 0x29a, %tba + 70: 8b 90 62 9a wrpr %g1, 0x29a, %tba + 74: 8b 90 22 9a wrpr 0x29a, %tba + 78: 8d 90 40 02 wrpr %g1, %g2, %pstate + 7c: 8d 90 40 00 wrpr %g1, %pstate + 80: 8d 90 62 9a wrpr %g1, 0x29a, %pstate + 84: 8d 90 62 9a wrpr %g1, 0x29a, %pstate + 88: 8d 90 22 9a wrpr 0x29a, %pstate + 8c: 8f 90 40 02 wrpr %g1, %g2, %tl + 90: 8f 90 40 00 wrpr %g1, %tl + 94: 8f 90 62 9a wrpr %g1, 0x29a, %tl + 98: 8f 90 62 9a wrpr %g1, 0x29a, %tl + 9c: 8f 90 22 9a wrpr 0x29a, %tl + a0: 91 90 40 02 wrpr %g1, %g2, %pil + a4: 91 90 40 00 wrpr %g1, %pil + a8: 91 90 62 9a wrpr %g1, 0x29a, %pil + ac: 91 90 62 9a wrpr %g1, 0x29a, %pil + b0: 91 90 22 9a wrpr 0x29a, %pil + b4: 93 90 40 02 wrpr %g1, %g2, %cwp + b8: 93 90 40 00 wrpr %g1, %cwp + bc: 93 90 62 9a wrpr %g1, 0x29a, %cwp + c0: 93 90 62 9a wrpr %g1, 0x29a, %cwp + c4: 93 90 22 9a wrpr 0x29a, %cwp + c8: 95 90 40 02 wrpr %g1, %g2, %cansave + cc: 95 90 40 00 wrpr %g1, %cansave + d0: 95 90 62 9a wrpr %g1, 0x29a, %cansave + d4: 95 90 62 9a wrpr %g1, 0x29a, %cansave + d8: 95 90 22 9a wrpr 0x29a, %cansave + dc: 97 90 40 02 wrpr %g1, %g2, %canrestore + e0: 97 90 40 00 wrpr %g1, %canrestore + e4: 97 90 62 9a wrpr %g1, 0x29a, %canrestore + e8: 97 90 62 9a wrpr %g1, 0x29a, %canrestore + ec: 97 90 22 9a wrpr 0x29a, %canrestore + f0: 99 90 40 02 wrpr %g1, %g2, %cleanwin + f4: 99 90 40 00 wrpr %g1, %cleanwin + f8: 99 90 62 9a wrpr %g1, 0x29a, %cleanwin + fc: 99 90 62 9a wrpr %g1, 0x29a, %cleanwin + 100: 99 90 22 9a wrpr 0x29a, %cleanwin + 104: 9b 90 40 02 wrpr %g1, %g2, %otherwin + 108: 9b 90 40 00 wrpr %g1, %otherwin + 10c: 9b 90 62 9a wrpr %g1, 0x29a, %otherwin + 110: 9b 90 62 9a wrpr %g1, 0x29a, %otherwin + 114: 9b 90 22 9a wrpr 0x29a, %otherwin + 118: 9d 90 40 02 wrpr %g1, %g2, %wstate + 11c: 9d 90 40 00 wrpr %g1, %wstate + 120: 9d 90 62 9a wrpr %g1, 0x29a, %wstate + 124: 9d 90 62 9a wrpr %g1, 0x29a, %wstate + 128: 9d 90 22 9a wrpr 0x29a, %wstate + 12c: 9f 90 40 02 wrpr %g1, %g2, %fq + 130: 9f 90 40 00 wrpr %g1, %fq + 134: 9f 90 62 9a wrpr %g1, 0x29a, %fq + 138: 9f 90 62 9a wrpr %g1, 0x29a, %fq + 13c: 9f 90 22 9a wrpr 0x29a, %fq + 140: a1 90 40 02 wrpr %g1, %g2, %gl + 144: a1 90 40 00 wrpr %g1, %gl + 148: a1 90 62 9a wrpr %g1, 0x29a, %gl + 14c: a1 90 62 9a wrpr %g1, 0x29a, %gl + 150: a1 90 22 9a wrpr 0x29a, %gl + 154: af 90 40 02 wrpr %g1, %g2, %pmcdper + 158: af 90 40 00 wrpr %g1, %pmcdper + 15c: af 90 62 9a wrpr %g1, 0x29a, %pmcdper + 160: af 90 62 9a wrpr %g1, 0x29a, %pmcdper + 164: af 90 22 9a wrpr 0x29a, %pmcdper + 168: bf 90 40 02 wrpr %g1, %g2, %ver + 16c: bf 90 40 00 wrpr %g1, %ver + 170: bf 90 62 9a wrpr %g1, 0x29a, %ver + 174: bf 90 62 9a wrpr %g1, 0x29a, %ver + 178: bf 90 22 9a wrpr 0x29a, %ver diff --git a/gas/testsuite/gas/sparc/wrpr.s b/gas/testsuite/gas/sparc/wrpr.s index a17182e..2227fe0 100644 --- a/gas/testsuite/gas/sparc/wrpr.s +++ b/gas/testsuite/gas/sparc/wrpr.s @@ -1,19 +1,97 @@ # Test wrpr .text + wrpr %g1,%g2,%tpc wrpr %g1,%tpc - wrpr %g2,%tnpc - wrpr %g3,%tstate - wrpr %g4,%tt - wrpr %g5,%tick - wrpr %g6,%tba - wrpr %g7,%pstate - wrpr %o0,%tl - wrpr %o1,%pil - wrpr %o2,%cwp - wrpr %o3,%cansave - wrpr %o4,%canrestore - wrpr %o5,%cleanwin - wrpr %o6,%otherwin - wrpr %o7,%wstate - wrpr %l0,%gl - wrpr %l3,%pmcdper + wrpr %g1,666,%tpc + wrpr 666,%g1,%tpc + wrpr 666,%tpc + wrpr %g1,%g2,%tnpc + wrpr %g1,%tnpc + wrpr %g1,666,%tnpc + wrpr 666,%g1,%tnpc + wrpr 666,%tnpc + wrpr %g1,%g2,%tstate + wrpr %g1,%tstate + wrpr %g1,666,%tstate + wrpr 666,%g1,%tstate + wrpr 666,%tstate + wrpr %g1,%g2,%tt + wrpr %g1,%tt + wrpr %g1,666,%tt + wrpr 666,%g1,%tt + wrpr 666,%tt + wrpr %g1,%g2,%tick + wrpr %g1,%tick + wrpr %g1,666,%tick + wrpr 666,%g1,%tick + wrpr 666,%tick + wrpr %g1,%g2,%tba + wrpr %g1,%tba + wrpr %g1,666,%tba + wrpr 666,%g1,%tba + wrpr 666,%tba + wrpr %g1,%g2,%pstate + wrpr %g1,%pstate + wrpr %g1,666,%pstate + wrpr 666,%g1,%pstate + wrpr 666,%pstate + wrpr %g1,%g2,%tl + wrpr %g1,%tl + wrpr %g1,666,%tl + wrpr 666,%g1,%tl + wrpr 666,%tl + wrpr %g1,%g2,%pil + wrpr %g1,%pil + wrpr %g1,666,%pil + wrpr 666,%g1,%pil + wrpr 666,%pil + wrpr %g1,%g2,%cwp + wrpr %g1,%cwp + wrpr %g1,666,%cwp + wrpr 666,%g1,%cwp + wrpr 666,%cwp + wrpr %g1,%g2,%cansave + wrpr %g1,%cansave + wrpr %g1,666,%cansave + wrpr 666,%g1,%cansave + wrpr 666,%cansave + wrpr %g1,%g2,%canrestore + wrpr %g1,%canrestore + wrpr %g1,666,%canrestore + wrpr 666,%g1,%canrestore + wrpr 666,%canrestore + wrpr %g1,%g2,%cleanwin + wrpr %g1,%cleanwin + wrpr %g1,666,%cleanwin + wrpr 666,%g1,%cleanwin + wrpr 666,%cleanwin + wrpr %g1,%g2,%otherwin + wrpr %g1,%otherwin + wrpr %g1,666,%otherwin + wrpr 666,%g1,%otherwin + wrpr 666,%otherwin + wrpr %g1,%g2,%wstate + wrpr %g1,%wstate + wrpr %g1,666,%wstate + wrpr 666,%g1,%wstate + wrpr 666,%wstate + wrpr %g1,%g2,%fq + wrpr %g1,%fq + wrpr %g1,666,%fq + wrpr 666,%g1,%fq + wrpr 666,%fq + wrpr %g1,%g2,%gl + wrpr %g1,%gl + wrpr %g1,666,%gl + wrpr 666,%g1,%gl + wrpr 666,%gl + wrpr %g1,%g2,%pmcdper + wrpr %g1,%pmcdper + wrpr %g1,666,%pmcdper + wrpr 666,%g1,%pmcdper + wrpr 666,%pmcdper + wrpr %g1,%g2,%ver + wrpr %g1,%ver + wrpr %g1,666,%ver + wrpr 666,%g1,%ver + wrpr 666,%ver |