[Bug inline-asm/85172] internal compiler error: unexpected expression '<statement>' of kind asm_expr

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Wed Apr 4 11:02:00 GMT 2018


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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org

--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Created attachment 43839
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=43839&action=edit
gcc8-pr85172.patch

Untested fix.  The issue is that for certain builtins we say calls to them are
potential constant expressions no matter what arguments they have.  But we try
to evaluate those arguments as constant expressions anyway, which creates a
loophole, anything that is normally rejected as potential constant expression
can through this appear in the constexpr.c evaluation.


More information about the Gcc-bugs mailing list