public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/103696] pragma optimization is not applying to Lambdas Date: Tue, 14 Dec 2021 01:14:30 +0000 [thread overview] Message-ID: <bug-103696-4-yC1faDun73@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-103696-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103696 Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Last reconfirmed| |2021-12-14 Summary|Lambda functions are not |pragma optimization is not |inlined under certain |applying to Lambdas |optimization pragmas | Keywords| |wrong-code Blocks| |54367 Component|target |c++ Ever confirmed|0 |1 Status|UNCONFIRMED |NEW --- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> --- If I manually apply the attributes rather than use the pragma, I get the correct results. that is the following works: int global_var; [[gnu::optimize("finite-math-only"),gnu::target("sse3")]] int solve() { auto nested = [] [[gnu::optimize("finite-math-only"),gnu::target("sse")]] () { return global_var; }; return nested(); } Referenced Bugs: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54367 [Bug 54367] [meta-bug] lambda expressions
next prev parent reply other threads:[~2021-12-14 1:14 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-12-13 20:30 [Bug target/103696] New: Lambda functions are not inlined under certain optimization pragmas imachug at gmail dot com 2021-12-13 20:33 ` [Bug target/103696] " imachug at gmail dot com 2021-12-14 1:14 ` pinskia at gcc dot gnu.org [this message] 2021-12-14 16:59 ` [Bug c++/103696] pragma optimization is not applying to Lambdas marxin at gcc dot gnu.org 2021-12-16 11:08 ` marxin at gcc dot gnu.org 2021-12-16 16:52 ` cvs-commit at gcc dot gnu.org 2021-12-16 16:53 ` marxin at gcc dot gnu.org 2024-04-17 7:12 ` pinskia at gcc dot gnu.org
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=bug-103696-4-yC1faDun73@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /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: linkBe 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).