Mark Eggleston
2018-08-09 14:11:58 UTC
Steven,
I'm sending this patch to you as it was found when a change to
gfc_simplify_mod caused the test for PR 86045 to fail.
Immediately after gfc_simplify_mod is gfc_simplify_modulo and is
similar. Substituting mod with modulo in the test file caused an
internal compiler error just like PR 86045.
Here is the back trace:
f951: internal compiler error: Segmentation fault
0xb7dedf crash_signal
   ../../gcc/gcc/toplev.c:325
0x6546e8 reduce_binary_ac
   ../../gcc/gcc/fortran/arith.c:1308
0x654682 reduce_binary_ac
   ../../gcc/gcc/fortran/arith.c:1295
0x6548cc reduce_binary
   ../../gcc/gcc/fortran/arith.c:1421
0x654b1b eval_intrinsic
   ../../gcc/gcc/fortran/arith.c:1596
0x6552be eval_intrinsic_f3
   ../../gcc/gcc/fortran/arith.c:1733
0x68bb75 simplify_intrinsic_op
   ../../gcc/gcc/fortran/expr.c:1158
0x68bb75 gfc_simplify_expr(gfc_expr*, int)
   ../../gcc/gcc/fortran/expr.c:1984
0x68af17 gfc_reduce_init_expr(gfc_expr*)
   ../../gcc/gcc/fortran/expr.c:2775
0x68db31 gfc_match_init_expr(gfc_expr**)
   ../../gcc/gcc/fortran/expr.c:2821
0x67b5b1 variable_decl
   ../../gcc/gcc/fortran/decl.c:2678
0x67b5b1 gfc_match_data_decl()
   ../../gcc/gcc/fortran/decl.c:5888
0x6d6429 match_word_omp_simd
   ../../gcc/gcc/fortran/parse.c:93
0x6d9b1e match_word
   ../../gcc/gcc/fortran/parse.c:376
0x6d9b1e decode_statement
   ../../gcc/gcc/fortran/parse.c:376
0x6dba44 next_free
   ../../gcc/gcc/fortran/parse.c:1234
0x6dba44 next_statement
   ../../gcc/gcc/fortran/parse.c:1466
0x6dd83c parse_spec
   ../../gcc/gcc/fortran/parse.c:3674
0x6df803 parse_progunit
   ../../gcc/gcc/fortran/parse.c:5671
0x6e0de4 gfc_parse_file()
   ../../gcc/gcc/fortran/parse.c:6211
Please find attached the patch to fix the problem.
regards,
Mark Eggleston
I'm sending this patch to you as it was found when a change to
gfc_simplify_mod caused the test for PR 86045 to fail.
Immediately after gfc_simplify_mod is gfc_simplify_modulo and is
similar. Substituting mod with modulo in the test file caused an
internal compiler error just like PR 86045.
Here is the back trace:
f951: internal compiler error: Segmentation fault
0xb7dedf crash_signal
   ../../gcc/gcc/toplev.c:325
0x6546e8 reduce_binary_ac
   ../../gcc/gcc/fortran/arith.c:1308
0x654682 reduce_binary_ac
   ../../gcc/gcc/fortran/arith.c:1295
0x6548cc reduce_binary
   ../../gcc/gcc/fortran/arith.c:1421
0x654b1b eval_intrinsic
   ../../gcc/gcc/fortran/arith.c:1596
0x6552be eval_intrinsic_f3
   ../../gcc/gcc/fortran/arith.c:1733
0x68bb75 simplify_intrinsic_op
   ../../gcc/gcc/fortran/expr.c:1158
0x68bb75 gfc_simplify_expr(gfc_expr*, int)
   ../../gcc/gcc/fortran/expr.c:1984
0x68af17 gfc_reduce_init_expr(gfc_expr*)
   ../../gcc/gcc/fortran/expr.c:2775
0x68db31 gfc_match_init_expr(gfc_expr**)
   ../../gcc/gcc/fortran/expr.c:2821
0x67b5b1 variable_decl
   ../../gcc/gcc/fortran/decl.c:2678
0x67b5b1 gfc_match_data_decl()
   ../../gcc/gcc/fortran/decl.c:5888
0x6d6429 match_word_omp_simd
   ../../gcc/gcc/fortran/parse.c:93
0x6d9b1e match_word
   ../../gcc/gcc/fortran/parse.c:376
0x6d9b1e decode_statement
   ../../gcc/gcc/fortran/parse.c:376
0x6dba44 next_free
   ../../gcc/gcc/fortran/parse.c:1234
0x6dba44 next_statement
   ../../gcc/gcc/fortran/parse.c:1466
0x6dd83c parse_spec
   ../../gcc/gcc/fortran/parse.c:3674
0x6df803 parse_progunit
   ../../gcc/gcc/fortran/parse.c:5671
0x6e0de4 gfc_parse_file()
   ../../gcc/gcc/fortran/parse.c:6211
Please find attached the patch to fix the problem.
regards,
Mark Eggleston
--
https://www.codethink.co.uk/privacy.html
https://www.codethink.co.uk/privacy.html