public inbox for elfutils@sourceware.org
 help / color / mirror / Atom feed
From: Mark Wielaard <mark@klomp.org>
To: Aaron Merey <amerey@redhat.com>
Cc: elfutils-devel@sourceware.org, david.abdurachmanov@gmail.com
Subject: Re: [PATCH] riscv: Partial implementation of flatten_aggregate
Date: Wed, 20 Mar 2024 20:35:57 +0100	[thread overview]
Message-ID: <20240320193557.GJ8319@gnu.wildebeest.org> (raw)
In-Reply-To: <CAJDtP-T3H2WDr8_DZxUaDtM8fOQff_xYs7Zxoj0XxCWsHZwVyw@mail.gmail.com>

Hi Aaron,

On Wed, Mar 20, 2024 at 02:14:18PM -0400, Aaron Merey wrote:
> On Wed, Mar 20, 2024 at 11:03 AM Mark Wielaard <mark@klomp.org> wrote:
> >
> > dwfl_module_return_value_location would fail on riscv for functions
> > which return a (small) struct. This patch implements the simplest
> > cases of flatten_aggregate in backends/riscv_retval.c. It just handles
> > structs containing one or two members of the same base type which fit
> > completely or in pieces in one or two general or floating point
> > registers.
> >
> > It also adds a specific test case run-funcretval-struct.sh containing
> > small structs of ints, longs, floats and doubles. All these testscases
> > now work for riscv. There is already a slightly more extensive
> > testcase for this in tests/run-funcretval.sh but that only has a
> > testcase for aarch64.
> 
> This patch LGTM.  I'm not able to test it myself on riscv

This is why there is the run-funcretval-struct.sh with riscv binary
testcase. So at least you can see it generates a DWARF expression for
the return values in a riscv ELF binary.

> but I see that
> for the first time a build has successfully passed on the elfutils riscv
> trybot [1].

Yes, nice.
David also tested it on the fedora riscv koji builder:
http://fedora.riscv.rocks/koji/taskinfo?taskID=1654120

============================================================================
Testsuite summary for elfutils 0.191
============================================================================
# TOTAL: 276
# PASS:  270
# SKIP:  6
# XFAIL: 0
# FAIL:  0
# XPASS: 0
# ERROR: 0
============================================================================

So I think it generally works.

Thanks,

Mark

> 
> [1] https://builder.sourceware.org/buildbot/#/builders/273
> 

  reply	other threads:[~2024-03-20 19:35 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-20 15:03 Mark Wielaard
2024-03-20 18:14 ` Aaron Merey
2024-03-20 19:35   ` Mark Wielaard [this message]
2024-03-20 20:17 ` Palmer Dabbelt
2024-03-20 23:15   ` Mark Wielaard
2024-03-20 23:30     ` Palmer Dabbelt

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=20240320193557.GJ8319@gnu.wildebeest.org \
    --to=mark@klomp.org \
    --cc=amerey@redhat.com \
    --cc=david.abdurachmanov@gmail.com \
    --cc=elfutils-devel@sourceware.org \
    /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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).