public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug middle-end/58809] New: [4.7/4.8/4.9 Regression] ICE with complex variable in OpenMP reduction clause
@ 2013-10-19 22:31 reichelt at gcc dot gnu.org
  2013-10-21  8:26 ` [Bug middle-end/58809] " rguenth at gcc dot gnu.org
                   ` (14 more replies)
  0 siblings, 15 replies; 16+ messages in thread
From: reichelt at gcc dot gnu.org @ 2013-10-19 22:31 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58809

            Bug ID: 58809
           Summary: [4.7/4.8/4.9 Regression] ICE with complex variable in
                    OpenMP reduction clause
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: middle-end
          Assignee: unassigned at gcc dot gnu.org
          Reporter: reichelt at gcc dot gnu.org

The following valid code snippet (compiled with "-fopenmp -O") triggers an ICE
since GCC 4.3.0:

======================================================
int i;
#pragma omp threadprivate (i)

void foo()
{
  _Complex int j;
#pragma omp parallel copyin (i) reduction (&&:j)
  ;
}
======================================================

bug.c: In function 'foo':
bug.c:7:9: internal compiler error: in build_int_cst_wide, at tree.c:1258
 #pragma omp parallel copyin (i) reduction (&&:j)
         ^
0xb6dcd3 build_int_cst_wide(tree_node*, unsigned long, long)
        ../../gcc/gcc/tree.c:1258
0xb6e010 double_int_to_tree(tree_node*, double_int)
        ../../gcc/gcc/tree.c:1112
0xb6e05a build_int_cst(tree_node*, long)
        ../../gcc/gcc/tree.c:1089
0x7804b3 make_range(tree_node*, int*, tree_node**, tree_node**, bool*)
        ../../gcc/gcc/fold-const.c:4231
0x785533 fold_range_test
        ../../gcc/gcc/fold-const.c:4987
0x785533 fold_truth_andor
        ../../gcc/gcc/fold-const.c:8629
0x74d86c fold_binary_loc(unsigned int, tree_code, tree_node*, tree_node*,
tree_node*)
        ../../gcc/gcc/fold-const.c:12711
0x76a86a fold_build2_stat_loc(unsigned int, tree_code, tree_node*, tree_node*,
tree_node*)
        ../../gcc/gcc/fold-const.c:15051
0x8a2e7a lower_reduction_clauses
        ../../gcc/gcc/omp-low.c:3799
0x8a4fbe lower_omp_taskreg
        ../../gcc/gcc/omp-low.c:9383
0x89e0ab lower_omp_1
        ../../gcc/gcc/omp-low.c:9907
0x89e0ab lower_omp
        ../../gcc/gcc/omp-low.c:10029
0x89e82e lower_omp_1
        ../../gcc/gcc/omp-low.c:9899
0x89e82e lower_omp
        ../../gcc/gcc/omp-low.c:10029
0x89fe5c execute_lower_omp
        ../../gcc/gcc/omp-low.c:10064
0x89fe5c execute
        ../../gcc/gcc/omp-low.c:10103
Please submit a full bug report, [etc.]


A similar code snippet triggers an ICE in a different position on trunk:

======================================================
int i;
#pragma omp threadprivate (i)

void foo()
{
  _Complex int j;
#pragma omp parallel copyin (i) reduction (&:j)
  ;
}
======================================================

bug.c: In function 'foo._omp_fn.0':
bug.c:17:9: internal compiler error: in expand_expr_real_2, at expr.c:9119
 #pragma omp parallel copyin (i) reduction (&:j)
         ^
0x723807 expand_expr_real_2(separate_ops*, rtx_def*, machine_mode,
expand_modifier)
        ../../gcc/gcc/expr.c:9119
0x710127 expand_expr_real_1(tree_node*, rtx_def*, machine_mode,
expand_modifier, rtx_def**)
        ../../gcc/gcc/expr.c:10487
0x710e86 expand_expr_real_1(tree_node*, rtx_def*, machine_mode,
expand_modifier, rtx_def**)
        ../../gcc/gcc/expr.c:9296
0x71b5b8 store_expr(tree_node*, rtx_def*, int, bool)
        ../../gcc/gcc/expr.c:5208
0x71d663 expand_assignment(tree_node*, tree_node*, bool)
        ../../gcc/gcc/expr.c:4994
0x64667d expand_gimple_stmt_1
        ../../gcc/gcc/cfgexpand.c:2277
0x64667d expand_gimple_stmt
        ../../gcc/gcc/cfgexpand.c:2373
0x6480e3 expand_gimple_basic_block
        ../../gcc/gcc/cfgexpand.c:4212
0x649a2c gimple_expand_cfg
        ../../gcc/gcc/cfgexpand.c:4731
0x649a2c execute
        ../../gcc/gcc/cfgexpand.c:4945
Please submit a full bug report, [etc.]


^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2014-05-07 16:23 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-19 22:31 [Bug middle-end/58809] New: [4.7/4.8/4.9 Regression] ICE with complex variable in OpenMP reduction clause reichelt at gcc dot gnu.org
2013-10-21  8:26 ` [Bug middle-end/58809] " rguenth at gcc dot gnu.org
2013-10-21 11:17 ` mpolacek at gcc dot gnu.org
2013-10-21 12:41 ` mpolacek at gcc dot gnu.org
2013-10-21 15:18 ` mpolacek at gcc dot gnu.org
2013-10-21 18:40 ` mpolacek at gcc dot gnu.org
2013-11-05 15:06 ` [Bug middle-end/58809] [4.7/4.8 " rguenth at gcc dot gnu.org
2013-11-05 21:17 ` [Bug middle-end/58809] [4.7/4.8/4.9 " reichelt at gcc dot gnu.org
2013-12-05  0:46 ` burnus at gcc dot gnu.org
2014-01-23 13:32 ` jakub at gcc dot gnu.org
2014-01-23 13:34 ` jakub at gcc dot gnu.org
2014-01-23 13:40 ` [Bug middle-end/58809] [4.7/4.8 " jakub at gcc dot gnu.org
2014-01-23 13:42 ` mpolacek at gcc dot gnu.org
2014-01-23 13:49 ` mpolacek at gcc dot gnu.org
2014-05-07 16:12 ` [Bug middle-end/58809] [4.7 " jakub at gcc dot gnu.org
2014-05-07 16:23 ` jakub at gcc dot gnu.org

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).