aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-object-size.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2018-12-14 20:37:38 +0100
committerJakub Jelinek <jakub@gcc.gnu.org>2018-12-14 20:37:38 +0100
commit0fca07e31dc85bea3b1d669d7cc1d51d22192335 (patch)
tree662864e452bc122b8f1cff2569205e4a587d86c0 /gcc/tree-object-size.c
parentfaa9232da39587b27b46341667d6d415d2af9280 (diff)
downloadgcc-0fca07e31dc85bea3b1d669d7cc1d51d22192335.zip
gcc-0fca07e31dc85bea3b1d669d7cc1d51d22192335.tar.gz
gcc-0fca07e31dc85bea3b1d669d7cc1d51d22192335.tar.bz2
re PR c++/82294 (Array of objects with constexpr constructors initialized from space-inefficient memory image)
PR c++/82294 PR c++/87436 * expr.h (categorize_ctor_elements): Add p_unique_nz_elts argument. * expr.c (categorize_ctor_elements_1): Likewise. Compute it like p_nz_elts, except don't multiply it by mult. Adjust recursive call. Fix up COMPLEX_CST handling. (categorize_ctor_elements): Add p_unique_nz_elts argument, initialize it and pass it through to categorize_ctor_elements_1. (mostly_zeros_p, all_zeros_p): Adjust categorize_ctor_elements callers. * gimplify.c (gimplify_init_constructor): Likewise. Don't force ctor into readonly data section if num_unique_nonzero_elements is smaller or equal to 1/8 of num_nonzero_elements and size is >= 64 bytes. * g++.dg/tree-ssa/pr82294.C: New test. * g++.dg/tree-ssa/pr87436.C: New test. From-SVN: r267143
Diffstat (limited to 'gcc/tree-object-size.c')
0 files changed, 0 insertions, 0 deletions