From: Andrew Pinski <pinskia@gmail.com>
To: Wilco Dijkstra <Wilco.Dijkstra@arm.com>,
GCC Patches <gcc-patches@gcc.gnu.org>,
richard.sandiford@arm.com
Subject: Re: [PATCH] testsuite: Improve check-function-bodies
Date: Wed, 5 Jun 2024 07:48:44 -0700 [thread overview]
Message-ID: <CA+=Sn1niBgoh+jQOJd+EauwkO7TaCco8RO7Mht0hKaNa3aoFHg@mail.gmail.com> (raw)
In-Reply-To: <mpt7cfa55h4.fsf@arm.com>
On Fri, May 31, 2024 at 9:09 AM Richard Sandiford
<richard.sandiford@arm.com> wrote:
>
> Wilco Dijkstra <Wilco.Dijkstra@arm.com> writes:
> > Improve check-function-bodies by allowing single-character function names.
> > Also skip '#' comments which may be emitted from inline assembler.
> >
> > Passes regress, OK for commit?
> >
> > gcc/testsuite:
> > * lib/scanasm.exp (configure_check-function-bodies): Allow single-char
> > function names. Skip '#' comments.
> >
> > ---
> >
> > diff --git a/gcc/testsuite/lib/scanasm.exp b/gcc/testsuite/lib/scanasm.exp
> > index 6cf9997240deec274a191103d21690d80e34ba95..0e461ef260b7a6fee5a9c60d0571e46468f752c0 100644
> > --- a/gcc/testsuite/lib/scanasm.exp
> > +++ b/gcc/testsuite/lib/scanasm.exp
> > @@ -869,15 +869,15 @@ proc configure_check-function-bodies { config } {
> > # Regexp for the start of a function definition (name in \1).
> > if { [istarget nvptx*-*-*] } {
> > set up_config(start) {
> > - {^// BEGIN(?: GLOBAL|) FUNCTION DEF: ([a-zA-Z_]\S+)$}
> > + {^// BEGIN(?: GLOBAL|) FUNCTION DEF: ([a-zA-Z_]\S*)$}
> > }
> > } elseif { [istarget *-*-darwin*] } {
> > set up_config(start) {
> > - {^_([a-zA-Z_]\S+):$}
> > + {^_([a-zA-Z_]\S*):$}
> > {^LFB[0-9]+:}
> > }
> > } else {
> > - set up_config(start) {{^([a-zA-Z_]\S+):$}}
> > + set up_config(start) {{^([a-zA-Z_]\S*):$}}
> > }
> >
> > # Regexp for the end of a function definition.
>
> This part is ok, thanks.
Note the issue with single function names was recorded as
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111658 (which I just
closed as fixed).
Thanks,
Andrew Pinski
>
> > @@ -899,9 +899,9 @@ proc configure_check-function-bodies { config } {
> > } else {
> > # Skip lines beginning with labels ('.L[...]:') or other directives
> > # ('.align', '.cfi_startproc', '.quad [...]', '.text', etc.), '//' or
> > - # '@' comments ('-fverbose-asm' or ARM-style, for example), or empty
> > - # lines.
> > - set up_config(fluff) {^\s*(?:\.|//|@|$)}
> > + # '@' or '#' comments ('-fverbose-asm' or ARM-style, for example), or
> > + # empty lines.
> > + set up_config(fluff) {^\s*(?:\.|//|@|#|$)}
> > }
> >
> > # Regexp for expected output lines prefix.
>
> I think this should be done separately. It looks like at least
> gcc.target/riscv/target-attr-06.c relies on the current behaviour.
>
> Richard
prev parent reply other threads:[~2024-06-05 14:48 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-31 15:37 Wilco Dijkstra
2024-05-31 16:08 ` Richard Sandiford
2024-06-05 14:48 ` Andrew Pinski [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='CA+=Sn1niBgoh+jQOJd+EauwkO7TaCco8RO7Mht0hKaNa3aoFHg@mail.gmail.com' \
--to=pinskia@gmail.com \
--cc=Wilco.Dijkstra@arm.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=richard.sandiford@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).