public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Simon Marchi <simon.marchi@polymtl.ca>
To: Alan Hayward <Alan.Hayward@arm.com>
Cc: gdb-patches@sourceware.org, nd <nd@arm.com>
Subject: Re: [PATCH 1/4] Aarch64: Func to detect args passed in float regs
Date: Tue, 28 Aug 2018 16:00:00 -0000	[thread overview]
Message-ID: <374e4a0b72b9c900319acc2071974f8b@polymtl.ca> (raw)
In-Reply-To: <D139F789-DC0E-4A77-AA3F-8DEF3E24862D@arm.com>

On 2018-08-28 11:49, Alan Hayward wrote:
>> On 28 Aug 2018, at 16:43, Simon Marchi <simon.marchi@polymtl.ca> 
>> wrote:
>> 
>> On 2018-08-20 05:29, Alan Hayward wrote:
>>> aapcs_is_vfp_call_or_return_candidate is as an eventual replacement
>>> for is_hfa_or_hva.
>>> This function is based on the GCC code
>>> gcc/config/aarch64/aarch64.c:aarch64_vfp_is_call_or_return_candidate 
>>> ()
>>> 2018-08-20  Alan Hayward  <alan.hayward@arm.com>
>>> 	* aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
>>> 	(aapcs_is_vfp_call_or_return_candidate_1): New function.
>>> 	(aapcs_is_vfp_call_or_return_candidate): Likewise.
>> 
>> I'm not an AArch64 expert, but I didn't spot anything suspicious.  The 
>> documentation
>> helps a lot to understand, thanks for that.
>> 
>> 
>>> +/* Return true if an argument, whose type is described by TYPE, can
>>> be passed or
>>> +   returned in simd/fp registers, providing enough parameter passing 
>>> registers
>>> +   are available.  This is as described in the AAPCS64.
>>> +
>>> +   Upon successful return, *COUNT returns the number of needed 
>>> registers,
>>> +   *FUNDAMENTAL_TYPE contains the type of those registers.
>>> +
>>> +   Candidate as per the AAPCS64 5.4.2.C is either a:
>>> +   - float.
>>> +   - short-vector.
>>> +   - HFA (Homogeneous Floating-point Aggregate, 4.3.5.1). A 
>>> Composite
>>> type where
>>> +     all the members are floats and has at most 4 members.
>>> +   - HVA (Homogeneous Short-vector Aggregate, 4.3.5.2). A Composite 
>>> type where
>>> +     all the members are short vectors and has at most 4 members.
>>> +   - Complex (7.1.1)
>>> +
>>> +   Note that HFAs and HVAs can include nested structures and arrays. 
>>>  */
>>> +
>>> +bool
>> 
>> static?
>> 
> 
> Yes, it should be static. But, in this patch nothing calls the 
> function, which
> causes a compile failure. I make it static in patch 2.
> A little awkward, but seemed the best way to do it.
> 
> 
> Alan.

Ah, I see.  Another option would be to put __attribute__((unused)) 
temporarily.  But I'm fine with what you've done too.

Simon

  reply	other threads:[~2018-08-28 16:00 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-20  9:29 [PATCH 0/4] Aarch64: Correctly support args passed in float registers Alan Hayward
2018-08-20  9:29 ` [PATCH 1/4] Aarch64: Func to detect args passed in float regs Alan Hayward
2018-08-28 15:43   ` Simon Marchi
2018-08-28 15:49     ` Alan Hayward
2018-08-28 16:00       ` Simon Marchi [this message]
2018-08-20  9:30 ` [PATCH 3/4] Aarch64: Float register detection for return values Alan Hayward
2018-08-28 16:03   ` Simon Marchi
2018-08-20  9:30 ` [PATCH 2/4] Aarch64: Float register detection for _push_dummy_call Alan Hayward
2018-08-28 15:58   ` Simon Marchi
2018-08-20  9:30 ` [PATCH 4/4] infcall-nested-structs: Test up to five fields Alan Hayward
2018-08-28 16:52   ` Simon Marchi
2018-08-28  9:39 ` [Ping][PATCH 0/4] Aarch64: Correctly support args passed in float registers Alan Hayward

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=374e4a0b72b9c900319acc2071974f8b@polymtl.ca \
    --to=simon.marchi@polymtl.ca \
    --cc=Alan.Hayward@arm.com \
    --cc=gdb-patches@sourceware.org \
    --cc=nd@arm.com \
    /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).