public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug testsuite/105055] New: pr95483-1.c makes incorrect assumption of SSE2 being enabled.
@ 2022-03-25 13:52 poulhies at adacore dot com
  2022-03-25 14:48 ` [Bug testsuite/105055] " hjl.tools at gmail dot com
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: poulhies at adacore dot com @ 2022-03-25 13:52 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105055

            Bug ID: 105055
           Summary: pr95483-1.c makes incorrect assumption of SSE2 being
                    enabled.
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: testsuite
          Assignee: unassigned at gcc dot gnu.org
          Reporter: poulhies at adacore dot com
  Target Milestone: ---

Using a compiler without sse/sse2 enabled by default, the test emits the
following warning:

gcc/testsuite/gcc.target/i386/pr95483-1.c: In function 'foo':
...../11.2.1/include/emmintrin.h:762:1: error: inlining failed in call to
'always_inline' '_mm_storeu_si16': target specific option mismatch
.../gcc/testsuite/gcc.target/i386/pr95483-1.c:15:4: note: called from here
.../11.2.1/include/emmintrin.h:725:1: error: inlining failed in call to
'always_inline' '_mm_loadu_si16': target specific option mismatch
...gcc/testsuite/gcc.target/i386/pr95483-1.c:14:7: note: called from here

The reason is that the test is built using -msse only, but the emmintrin.h has:

 #ifndef __SSE2__
 #pragma GCC push_options
 #pragma GCC target("sse2")
 #define __DISABLE_SSE2__
 #endif /* __SSE2__ */

preventing the inlining.

Seeing how other tests pr95483-{1..7}.c are built using different options, I'm
not really sure how to fix this correctly (I would add -msse2 in this
particular test..).

Thanks,
Marc

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug testsuite/105055] pr95483-1.c makes incorrect assumption of SSE2 being enabled.
  2022-03-25 13:52 [Bug testsuite/105055] New: pr95483-1.c makes incorrect assumption of SSE2 being enabled poulhies at adacore dot com
@ 2022-03-25 14:48 ` hjl.tools at gmail dot com
  2022-03-25 21:03 ` cvs-commit at gcc dot gnu.org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: hjl.tools at gmail dot com @ 2022-03-25 14:48 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105055

H.J. Lu <hjl.tools at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|hjl at gcc dot gnu.org             |hjl.tools at gmail dot com,
                   |                            |skpgkp2 at gmail dot com
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2022-03-25
     Ever confirmed|0                           |1

--- Comment #1 from H.J. Lu <hjl.tools at gmail dot com> ---
(In reply to Marc Poulhiès from comment #0)
> Using a compiler without sse/sse2 enabled by default, the test emits the
> following warning:
> 
> gcc/testsuite/gcc.target/i386/pr95483-1.c: In function 'foo':
> ...../11.2.1/include/emmintrin.h:762:1: error: inlining failed in call to
> 'always_inline' '_mm_storeu_si16': target specific option mismatch
> .../gcc/testsuite/gcc.target/i386/pr95483-1.c:15:4: note: called from here
> .../11.2.1/include/emmintrin.h:725:1: error: inlining failed in call to
> 'always_inline' '_mm_loadu_si16': target specific option mismatch
> ...gcc/testsuite/gcc.target/i386/pr95483-1.c:14:7: note: called from here
> 
> The reason is that the test is built using -msse only, but the emmintrin.h
> has:

It is wrong not to pass -msse2 with emmintrin.h.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug testsuite/105055] pr95483-1.c makes incorrect assumption of SSE2 being enabled.
  2022-03-25 13:52 [Bug testsuite/105055] New: pr95483-1.c makes incorrect assumption of SSE2 being enabled poulhies at adacore dot com
  2022-03-25 14:48 ` [Bug testsuite/105055] " hjl.tools at gmail dot com
@ 2022-03-25 21:03 ` cvs-commit at gcc dot gnu.org
  2022-03-26 20:03 ` cvs-commit at gcc dot gnu.org
  2022-03-26 20:05 ` hjl.tools at gmail dot com
  3 siblings, 0 replies; 5+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-03-25 21:03 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105055

--- Comment #2 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by H.J. Lu <hjl@gcc.gnu.org>:

https://gcc.gnu.org/g:bdd7b679e8497c07e25726f6ab6429e4c4d429c7

commit r12-7820-gbdd7b679e8497c07e25726f6ab6429e4c4d429c7
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Mar 25 13:53:34 2022 -0700

    x86: Use -msse2 on gcc.target/i386/pr95483-1.c

    Replace -msse with -msse2 since <emmintrin.h> requires SSE2.

            PR testsuite/105055
            * gcc.target/i386/pr95483-1.c: Replace -msse with -msse2.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug testsuite/105055] pr95483-1.c makes incorrect assumption of SSE2 being enabled.
  2022-03-25 13:52 [Bug testsuite/105055] New: pr95483-1.c makes incorrect assumption of SSE2 being enabled poulhies at adacore dot com
  2022-03-25 14:48 ` [Bug testsuite/105055] " hjl.tools at gmail dot com
  2022-03-25 21:03 ` cvs-commit at gcc dot gnu.org
@ 2022-03-26 20:03 ` cvs-commit at gcc dot gnu.org
  2022-03-26 20:05 ` hjl.tools at gmail dot com
  3 siblings, 0 replies; 5+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-03-26 20:03 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105055

--- Comment #3 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by H.J. Lu <hjl@gcc.gnu.org>:

https://gcc.gnu.org/g:856efb41a873adf2b3e9332cc296c64f6adff240

commit r11-9696-g856efb41a873adf2b3e9332cc296c64f6adff240
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Mar 25 13:53:34 2022 -0700

    x86: Use -msse2 on gcc.target/i386/pr95483-1.c

    Replace -msse with -msse2 since <emmintrin.h> requires SSE2.

            PR testsuite/105055
            * gcc.target/i386/pr95483-1.c: Replace -msse with -msse2.

    (cherry picked from commit bdd7b679e8497c07e25726f6ab6429e4c4d429c7)

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug testsuite/105055] pr95483-1.c makes incorrect assumption of SSE2 being enabled.
  2022-03-25 13:52 [Bug testsuite/105055] New: pr95483-1.c makes incorrect assumption of SSE2 being enabled poulhies at adacore dot com
                   ` (2 preceding siblings ...)
  2022-03-26 20:03 ` cvs-commit at gcc dot gnu.org
@ 2022-03-26 20:05 ` hjl.tools at gmail dot com
  3 siblings, 0 replies; 5+ messages in thread
From: hjl.tools at gmail dot com @ 2022-03-26 20:05 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105055

H.J. Lu <hjl.tools at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|NEW                         |RESOLVED
   Target Milestone|---                         |11.3

--- Comment #4 from H.J. Lu <hjl.tools at gmail dot com> ---
Fixed for GCC 12 and GCC 11.3.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2022-03-26 20:05 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-25 13:52 [Bug testsuite/105055] New: pr95483-1.c makes incorrect assumption of SSE2 being enabled poulhies at adacore dot com
2022-03-25 14:48 ` [Bug testsuite/105055] " hjl.tools at gmail dot com
2022-03-25 21:03 ` cvs-commit at gcc dot gnu.org
2022-03-26 20:03 ` cvs-commit at gcc dot gnu.org
2022-03-26 20:05 ` hjl.tools at gmail dot com

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).