diff options
author | Rainer Orth <ro@TechFak.Uni-Bielefeld.DE> | 2003-09-24 13:07:25 +0000 |
---|---|---|
committer | Rainer Orth <ro@gcc.gnu.org> | 2003-09-24 13:07:25 +0000 |
commit | eb9ec0d45db94e95fc5f0302100c7918c1e54f7b (patch) | |
tree | 1161d74636c9bd8bf6af80ab9859d26a28685a2e /gcc/java/class.c | |
parent | ff42324ea35dd2b82cc5f81e22f2765cda531d04 (diff) | |
download | gcc-eb9ec0d45db94e95fc5f0302100c7918c1e54f7b.zip gcc-eb9ec0d45db94e95fc5f0302100c7918c1e54f7b.tar.gz gcc-eb9ec0d45db94e95fc5f0302100c7918c1e54f7b.tar.bz2 |
* class.c (build_utf8_ref): Test for HAVE_GAS_SHF_MERGE value.
From-SVN: r71733
Diffstat (limited to 'gcc/java/class.c')
-rw-r--r-- | gcc/java/class.c | 35 |
1 files changed, 18 insertions, 17 deletions
diff --git a/gcc/java/class.c b/gcc/java/class.c index e3e6cc3..552a4f4 100644 --- a/gcc/java/class.c +++ b/gcc/java/class.c @@ -779,23 +779,24 @@ build_utf8_ref (tree name) TREE_READONLY (decl) = 1; TREE_THIS_VOLATILE (decl) = 0; DECL_INITIAL (decl) = cinit; -#ifdef HAVE_GAS_SHF_MERGE - { - int decl_size; - /* Ensure decl_size is a multiple of utf8const_type's alignment. */ - decl_size = (name_len + 5 + TYPE_ALIGN_UNIT (utf8const_type) - 1) - & ~(TYPE_ALIGN_UNIT (utf8const_type) - 1); - if (flag_merge_constants && decl_size < 256) - { - char buf[32]; - int flags = (SECTION_OVERRIDE - | SECTION_MERGE | (SECTION_ENTSIZE & decl_size)); - sprintf (buf, ".rodata.jutf8.%d", decl_size); - named_section_flags (buf, flags); - DECL_SECTION_NAME (decl) = build_string (strlen (buf), buf); - } - } -#endif + + if (HAVE_GAS_SHF_MERGE) + { + int decl_size; + /* Ensure decl_size is a multiple of utf8const_type's alignment. */ + decl_size = (name_len + 5 + TYPE_ALIGN_UNIT (utf8const_type) - 1) + & ~(TYPE_ALIGN_UNIT (utf8const_type) - 1); + if (flag_merge_constants && decl_size < 256) + { + char buf[32]; + int flags = (SECTION_OVERRIDE + | SECTION_MERGE | (SECTION_ENTSIZE & decl_size)); + sprintf (buf, ".rodata.jutf8.%d", decl_size); + named_section_flags (buf, flags); + DECL_SECTION_NAME (decl) = build_string (strlen (buf), buf); + } + } + TREE_CHAIN (decl) = utf8_decl_list; layout_decl (decl, 0); pushdecl (decl); |