[PATCH] Find tailcall frames before inline frames

Luis Machado luis.machado@linaro.org
Thu Mar 26 02:47:20 GMT 2020


On Wed, Mar 25, 2020, 22:59 Tom Tromey <tom@tromey.com> wrote:

> >>>>> "Luis" == Luis Machado <luis.machado@linaro.org> writes:
>
> Luis> Having spent a few days trying to understand this problem, it seems
> Luis> all of these fi->level assertions (including
> Luis> https://sourceware.org/bugzilla/show_bug.cgi?id=22748) are related
> to
> Luis> attempting to unwind from places not safe to do so. That is, we're
> Luis> trying to unwind some content (registers for example) before a given
> Luis> frame is assigned a frame id.
>
> Yes, I agree.
>
> Luis> I think dwarf2_tailcall_sniffer_first would have to be called from
> Luis> somewhere else, or conditions put in place. But I'm afraid adding
> more
> Luis> conditions would complicate things further. And this code is already
> Luis> reasonably complicated.
>
> Luis> Since this is causing a number of inlining test failures for aarch64
> Luis> and, from what i saw, some other architectures like s390, should we
> Luis> consider reverting this while we discuss/review a reworked version of
> Luis> the patch?
>
> I think that would be fine.  I haven't found the time to really dig into
> it.
>
> I suspect that maybe the architectures doing this aren't playing by the
> rules.
> Even so, though, it doesn't change that this used to work and now doesn't.
>

It could be. I noticed aarch64 doesn't implement gdbarch_unwind_pc. But
s390 does.

It is hard to tell what is wrong given different unwinding implementations
may give correct results, even with wrong assumptions.


> Tom
>


More information about the Gdb-patches mailing list