This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] handle unusual targets in -Wbuiltin-declaration-mismatch (PR 88098)
- From: Christophe Lyon <christophe dot lyon at linaro dot org>
- To: msebor at redhat dot com
- Cc: gcc Patches <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 20 Nov 2018 16:56:24 +0100
- Subject: Re: [PATCH] handle unusual targets in -Wbuiltin-declaration-mismatch (PR 88098)
- References: <c7f2f1ae-5b16-e648-9b83-6a29883fe09b@redhat.com>
On Mon, 19 Nov 2018 at 22:38, Martin Sebor <msebor@redhat.com> wrote:
>
> The gcc.dg/Wbuiltin-declaration-mismatch-4.c test added with
> the recent -Wbuiltin-declaration-mismatch enhancement to detect
> calls with incompatible arguments to built-ins declared without
> a prototype fails on a few targets due to incorrect assumptions
> hardcoded into the test. Besides removing those assumptions
> (or adding appropriate { target } attributes, the attached patch
> also adjusts the implementation of the warning to avoid triggering
> for enum promotion to int on short_enums targets.
>
> Since the fix is trivial I plan to commit it tomorrow if there
> are no concerns.
>
> Tested on x86_64-linux and with an arm-none-eabi cross-compiler.
> I also did a little bit of testing with sparc-solaris2.11 cross
> compiler but there the test harness fails due to the -m32 option
> so the Wbuiltin-declaration-mismatch-4.c still has unexpected
> FAILs. I've raised bug 88104 for the outstanding problem on
> sparc-solaris2.11.
>
Hello,
I tested your patch on arm* and aarch64*. It does the job on arm, but
on aarch64*elf,
I'm seeing new failures:
gcc.dg/Wbuiltin-declaration-mismatch-4.c large long double (test for
warnings, line 121)
gcc.dg/Wbuiltin-declaration-mismatch-4.c large long double (test for
warnings, line 123)
gcc.dg/Wbuiltin-declaration-mismatch-4.c large long double (test for
warnings, line 98)
> Martin