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

            Bug ID: 94903
           Summary: internal compiler error: in assign_temp, at
                    function.c:982
           Product: gcc
           Version: 10.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: anbu1024.me at gmail dot com
  Target Milestone: ---

$ cat reduced.c 

extern struct S var ; 

void foo ( ) 
{ 
        asm volatile ( "" : "=r" ( var ) ) ; 
}

--------------------------------------------------------------------------------

$ gcc-9 --version
gcc (GCC) 9.3.1 20200425
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

--------------------------------------------------------------------------------

$ gcc-9 reduced.c 
during RTL pass: expand
reduced.c: In function ‘foo’:
reduced.c:6:2: internal compiler error: in assign_temp, at function.c:982
    6 |  asm volatile ( "" : "=r" ( var ) ) ;
      |  ^~~
0x5b5f1e assign_temp(tree_node*, int, int)
        ../../gcc-9-20200425/gcc/function.c:982
0x6e81e1 expand_asm_stmt
        ../../gcc-9-20200425/gcc/cfgexpand.c:3196
0x6ebc95 expand_gimple_stmt_1
        ../../gcc-9-20200425/gcc/cfgexpand.c:3688
0x6ebc95 expand_gimple_stmt
        ../../gcc-9-20200425/gcc/cfgexpand.c:3850
0x6f0b9f expand_gimple_basic_block
        ../../gcc-9-20200425/gcc/cfgexpand.c:5890
0x6f2f2e execute
        ../../gcc-9-20200425/gcc/cfgexpand.c:6513
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.

--------------------------------------------------------------------------------

$ gcc-8 --version
gcc (GCC) 8.4.1 20200424
Copyright (C) 2018 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

--------------------------------------------------------------------------------

$ gcc-8 reduced.c 
during RTL pass: expand
reduced.c: In function ‘foo’:
reduced.c:6:2: internal compiler error: in assign_temp, at function.c:977
  asm volatile ( "" : "=r" ( var ) ) ;
  ^~~
0x5b7eca assign_temp(tree_node*, int, int)
        ../../gcc-8-20200424/gcc/function.c:977
0x6d51e6 expand_asm_stmt
        ../../gcc-8-20200424/gcc/cfgexpand.c:3097
0x6d9077 expand_gimple_stmt_1
        ../../gcc-8-20200424/gcc/cfgexpand.c:3635
0x6d9077 expand_gimple_stmt
        ../../gcc-8-20200424/gcc/cfgexpand.c:3804
0x6db37f expand_gimple_basic_block
        ../../gcc-8-20200424/gcc/cfgexpand.c:5837
0x6e08a6 execute
        ../../gcc-8-20200424/gcc/cfgexpand.c:6443
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.

--------------------------------------------------------------------------------

$ gcc-7.4.0 --version
gcc (GCC) 7.4.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

--------------------------------------------------------------------------------

$ gcc-7.4.0 reduced.c 
reduced.c: In function ‘foo’:
reduced.c:6:2: internal compiler error: in assign_temp, at function.c:968
  asm volatile ( "" : "=r" ( var ) ) ;
  ^~~
0x7db8b1 assign_temp(tree_node*, int, int)
        ../../gcc-7.4.0/gcc/function.c:968
0x6aa146 expand_asm_stmt
        ../../gcc-7.4.0/gcc/cfgexpand.c:3036
0x6addc7 expand_gimple_stmt_1
        ../../gcc-7.4.0/gcc/cfgexpand.c:3568
0x6addc7 expand_gimple_stmt
        ../../gcc-7.4.0/gcc/cfgexpand.c:3737
0x6af37f expand_gimple_basic_block
        ../../gcc-7.4.0/gcc/cfgexpand.c:5744
0x6b44c6 execute
        ../../gcc-7.4.0/gcc/cfgexpand.c:6357
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.

Reply via email to