[PATCH v2] [gdb] Support frames inlined into the outer frame
Simon Marchi
simark@simark.ca
Thu Jun 4 16:11:43 GMT 2020
On 2020-03-31 3:18 p.m., Scott Linder wrote:
> @@ -763,6 +760,24 @@ frame_id_eq (struct frame_id l, struct frame_id r)
> return eq;
> }
>
> +int
> +outer_frame_id_p (struct frame_id l)
> +{
> + int p;
> +
> + /* The artificial_depth can vary so we ignore it when checking if this is
> + an outer_frame_id. */
> + l.artificial_depth = 0;
> + p = memcmp (&l, &outer_frame_id, sizeof (outer_frame_id));
This should be `memcmp (...) == 0`. Currently, the function returns true when
the frame is not an outer frame id, which is the opposite of what it is supposed
to do.
With this, the test gdb.base/break.exp on AArch64 runs fine. I will launch a full
test run to see if there are any other problems.
You can make the new function return "bool" instead of "int", and use true/false instead
of zero/non-zero (both in the code and comments).
Simon
More information about the Gdb-patches
mailing list