varasm.c (bss_initializer_p): Do not put constants into .bss
authorJoerg Sonnenberger <joerg@bec.de>
Fri, 1 Sep 2017 16:26:00 +0000 (10:26 -0600)
committerJeff Law <law@gcc.gnu.org>
Fri, 1 Sep 2017 16:26:00 +0000 (10:26 -0600)
commit2ec399d8a6c9c26d69b73faf77c694fa3915dcec
treebfc2df7ff0476e32664d7b7175de7f5c2f04cd02
parentdb6bb1ec036f180584d221cdc66dff7bb7180d7a
varasm.c (bss_initializer_p): Do not put constants into .bss

* varasm.c (bss_initializer_p): Do not put constants into .bss
(categorize_decl_for_section): Handle bss_initializer_p returning
false when DECL_INITIAL is NULL.

* gcc.target/i386/const-in-bss.c: New test.

From-SVN: r251602
gcc/ChangeLog
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/i386/const-in-bss.c [new file with mode: 0644]
gcc/varasm.c