[Bug tree-optimization/126194] [15 Regression] LTO/DSE removes temporary initialization observed by placement delete cleanup

"cvs-commit at gcc dot gnu.org via Gcc-bugs" <[email protected]>
Newsgroups gmane.comp.gcc.bugs
Message-ID <[email protected]/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=126194

--- Comment #17 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Alexandre Oliva <[email protected]>:

https://gcc.gnu.org/g:7c38c56214bf2809399a2198441bb48ee1b00512

commit r17-2805-g7c38c56214bf2809399a2198441bb48ee1b00512
Author: Alexandre Oliva <[email protected]>
Date:   Thu Jul 30 01:13:43 2026 -0300

    testsuite: tolerate argc==0 [PR126194]

    Some embedded targets set argc to zero when calling main, but then
    pr126194 testcase fails because it uses argc > 0 to enable the code
    that allows the test to pass.  Derive the argc passed to the primary
    LTOed entry point from argc >= 0, so that it isn't a link-time
    constant, but the guarding condition always passes at runtime.


    for  gcc/testsuite/ChangeLog

            PR tree-optimization/126194
            * g++.dg/lto/pr126194_2.C (main): Tolerate argc == 0.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.