Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Sahil <icegambit91@gmail.com>
To: gdb-patches@sourceware.org
Cc: Sahil Siddiq <sahilcdq@proton.me>
Subject: Re: [PATCH] gdb: fix "frame function" issue when call is last instruction
Date: Tue, 02 Jul 2024 01:20:22 +0530	[thread overview]
Message-ID: <6070620.lOV4Wx5bFT@valdaarhun> (raw)
In-Reply-To: <20240630140808.919614-1-sahilcdq@proton.me>

Hi,

On Sunday, June 30, 2024 7:38:08 PM GMT+5:30 Sahil Siddiq wrote:
> Currently, the "frame function" fails when the last
> instruction is a call. In such a case, the $rip
> register points to an address that lies outside the
> frame.
> 
> Using "get_frame_address_in_block" instead of
> "get_frame_pc" resolves this issue.
> 
> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=30929
> ---
> Hi,
> 
> This is my first time contributing to gdb. I have
> tried to adhere to the styling convention. Please
> let me know if I have missed something.
> 
> Instead of extending the existing frame-selection.exp
> test, I thought I would create a new test since the C
> file is new and it seemed like the implementation of
> the test isn't similar enough to be kept in the existing
> exp file. Please let me know if this is undesirable.
> 
> Thanks,
> Sahil
> 
>  gdb/stack.c                                   |   4 +-
>  .../frame-selection-last-instr-call.c         |  28 ++++
>  .../frame-selection-last-instr-call.exp       | 139 ++++++++++++++++++
>  3 files changed, 169 insertions(+), 2 deletions(-)
>  create mode 100644 gdb/testsuite/gdb.base/frame-selection-last-instr-call.c
> create mode 100644
> gdb/testsuite/gdb.base/frame-selection-last-instr-call.exp
> [...]

I noticed that the test introduced in this patch fails in some environments. See
for example:
1. regressions on arm [1]
2. regressions on aarch64 [2]

I have submitted a new patch where the test should run successfully regardless
of the build environment.

Thanks,
Sahil

[1] https://ci.linaro.org/job/tcwg_gdb_check--master-arm-precommit/2800/
[2] https://ci.linaro.org/job/tcwg_gdb_check--master-aarch64-precommit/2814/
 



      reply	other threads:[~2024-07-01 19:50 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-30 14:08 Sahil Siddiq
2024-07-01 19:50 ` Sahil [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6070620.lOV4Wx5bFT@valdaarhun \
    --to=icegambit91@gmail.com \
    --cc=gdb-patches@sourceware.org \
    --cc=sahilcdq@proton.me \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox