From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id EA9723858D28; Mon, 19 Jun 2023 12:30:04 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org EA9723858D28 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1687177804; bh=S0BeIY9d54Ksh5zotd+gZ1hcdolj0G9gZUx/SS8I7FA=; h=From:To:Subject:Date:In-Reply-To:References:From; b=fK17dfmVVqX4CDU0reQi7M967Y19nNhiIAcVn1PamZBJWfnJpV35tnrgf4X0iZhcQ 7fDTUfyGz7g6+zsaUDGDZ0Uso88KH8d12SPFJ3qvQq/w/qKnUtXGZdrediL7olm8LD 57uJ6Eepv0MLweAqQn5UJT4VysZ2Px4FplSwz1fU= From: "xry111 at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/110303] With -O0, _mm_shuffle_epi32 with a constexpr function argument does not compile Date: Mon, 19 Jun 2023 12:30:04 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 13.2.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: xry111 at gcc dot gnu.org X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: DUPLICATE X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cc Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D110303 Xi Ruoyao changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |xry111 at gcc dot gnu.org --- Comment #5 from Xi Ruoyao --- (In reply to Denis Yaroshevskiy from comment #4) > > so _mm_shuffle_epi32 requires a constant but since it is an argument, t= he argument, it is not a constant expression requirement. >=20 > The function is marked constexpr. So it can be a constant if you ask it. The problem is -O0 means "don't ask it". Constant propagation is an optimization, but -O0 means don't do optimization.=