This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] [ARM] Improve heuristic to guess the instruction state for the next PC when single-stepping


On Thu, Mar 04, 2010 at 11:48:47AM +0000, Matthew Gretton-Dann wrote:
> This patch attempts to fix this by seeing if arm_pc_is_thumb () is being
> asked about the address we will end up at if we execute the instruction
> at the current PC.  If so it 'executes' the current instruction to see
> if it will change state, and uses this information to determine the
> return value.

This is a cute approach.  I can't think of any potential problems with
it, so I'll commit your patch.

> 2010-03-04  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
> 
> 	* arm-tdep.c (arm_pc_is_thumb): Add heuristic that tries to get
> 	the state right when single stepping.
> 	(arm_get_next_pc_raw, thumb_get_next_pc_raw): New functions. 
> 	Get the next PC along with the instruction state.
> 	(thumb_get_next_pc): Remove.
> 	(arm_get_next_pc): Modified to use arm_get_next_pc_raw ().

At some point we were asked to not use " ()" to indicate functions, so
I've removed that bit.

-- 
Daniel Jacobowitz
CodeSourcery


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]