[ppc64] Add POWER8/ISA 2.07 atomic sequences single-stepping support
authorEdjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
Tue, 21 Feb 2017 14:14:56 +0000 (11:14 -0300)
committerEdjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
Tue, 21 Feb 2017 14:14:56 +0000 (11:14 -0300)
commit2039d74e780db6659c87cd3c426d526615cfe703
tree69d7e0124feb4b58a3b52ab027e9ca61706ebf38
parenta51d7ecf3ddd64e0aec68e3c30913faba680b2cb
[ppc64] Add POWER8/ISA 2.07 atomic sequences single-stepping support

gdb/
2017-02-21  Edjunior Barbosa Machado  <emachado@linux.vnet.ibm.com>

* rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
(STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
(LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
(IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
(ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
(ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
IS_STORE_CONDITIONAL_INSN.

gdb/testsuite/
2017-02-21  Edjunior Barbosa Machado  <emachado@linux.vnet.ibm.com>

* gdb.arch/ppc64-isa207-atomic-inst.exp: New testcase based on
gdb.arch/ppc64-atomic-inst.exp.  Add tests for lbarx/stbcx, lharx/sthcx
and lqarx/stqcx.
* gdb.arch/ppc64-isa207-atomic-inst.S: New file.
* gdb.arch/ppc64-isa207-atomic-inst.c: Likewise.
gdb/ChangeLog
gdb/rs6000-tdep.c
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.arch/ppc64-isa207-atomic-inst.S [new file with mode: 0644]
gdb/testsuite/gdb.arch/ppc64-isa207-atomic-inst.c [new file with mode: 0644]
gdb/testsuite/gdb.arch/ppc64-isa207-atomic-inst.exp [new file with mode: 0644]