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

--- Comment #10 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The trunk branch has been updated by Andrew Pinski <pins...@gcc.gnu.org>:

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

commit r16-1429-gdcb9af06212e8bb36e84a1b8498c625c29abeb6f
Author: Gwenole Beauchesne <gb.de...@gmail.com>
Date:   Mon Jun 2 14:44:55 2025 -0700

    c/c++: Handle '#pragma GCC target optimize' early [PR48026]

    Handle '#pragma GCC optimize' earlier as the __OPTIMIZE__ macro may need
    to be defined as well for certain usages. Add additional tests for the
    '#pragma GCC target' case with auto-vectorization enabled and multiple
    combinations of namespaces and/or class member functions.

    This is similar to what was done for `#pramga GCC target` in
r14-4967-g8697d3a1dcf327,
    to fix the similar issue there.

    Add more complete tests for PR c++/41201 after git commit
r14-4967-g8697d3a1dcf327.

            PR c++/41201
            PR c++/48026
    gcc/c-family/ChangeLog:

            * c-pragma.cc (init_pragma): Use
c_register_pragma_with_early_handler
            instead of c_register_pragma for `#pragma GCC optimize`.

    gcc/testsuite/ChangeLog:

            * c-c++-common/pragma-optimize-1.c: New test.
            * g++.target/i386/vect-pragma-target-1.C: New test.
            * g++.target/i386/vect-pragma-target-2.C: New test.
            * gcc.target/i386/vect-pragma-target-1.c: New test.
            * gcc.target/i386/vect-pragma-target-2.c: New test.

    Signed-off-by: Gwenole Beauchesne <gb.de...@gmail.com>
    Co-authored-by: Andrew Pinski <quic_apin...@quicinc.com>

Reply via email to