[patch 1/3, nios2] revert to using "trap 31" for breakpoints

Yao Qi qiyaoltc@gmail.com
Tue Apr 28 11:18:00 GMT 2015


Sandra Loosemore <sandra@codesourcery.com> writes:

> -/* Implement the breakpoint_from_pc gdbarch hook.  */
> +/* Implement the breakpoint_from_pc gdbarch hook.
> +   Note that the Nios II ABI for Linux requires "trap 31"
> +   as the breakpoint, and we use that consistently on all targets.  */

Please quote the original statement from NIOS 2 ABI,

"Userspace programs should not use the break instruction and userspace
debuggers should not insert one."

and

"Userspace breakpoints are accomplished using the trap instruction with
immediate operand 31 (all ones)."

OK with this change.

-- 
Yao (齐尧)



More information about the Gdb-patches mailing list