diff options
author | dannysmith <dannysmith@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-12-13 06:57:13 +0000 |
---|---|---|
committer | dannysmith <dannysmith@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-12-13 06:57:13 +0000 |
commit | 784d37827813d2d3d740e1e10104a149d6185c89 (patch) | |
tree | 8474907991a93da60a61bf807147a9c32fcc9b6d /gcc/java | |
parent | 5cf640ac37b675a1dfe3b9466f79ae26df98c5be (diff) | |
download | gcc-784d37827813d2d3d740e1e10104a149d6185c89.tar.gz |
gcc
PR/18549
* defaults.h (TARGET_USE_JCR_SECTION): New macro.
* doc/tm.texi (TARGET_USE_JCR_SECTION): Document it.
* config/i386/cygming.h (TARGET_USE_JCR_SECTION): Override
default.
gcc/java
PR/18549
* class.c (emit_register_classes): Use TARGET_USE_JCR_SECTION.
Update comment.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@92078 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/java')
-rw-r--r-- | gcc/java/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/java/class.c | 11 |
2 files changed, 13 insertions, 4 deletions
diff --git a/gcc/java/ChangeLog b/gcc/java/ChangeLog index 2c8c5910936..dfb5ccba932 100644 --- a/gcc/java/ChangeLog +++ b/gcc/java/ChangeLog @@ -1,3 +1,9 @@ +2004-12-13 Danny Smith <dannysmith@users.sourceforge.net> + + PR/18549 + * class.c (emit_register_classes): Use TARGET_USE_JCR_SECTION. + Update comment. + 2004-12-07 Andrew Haley <aph@redhat.com> PR java/18811: diff --git a/gcc/java/class.c b/gcc/java/class.c index c314950cf44..94138200d0b 100644 --- a/gcc/java/class.c +++ b/gcc/java/class.c @@ -2419,10 +2419,11 @@ emit_register_classes (tree *list_p) if (registered_class == NULL) return; - /* ??? This isn't quite the correct test. We also have to know - that the target is using gcc's crtbegin/crtend objects rather - than the ones that come with the operating system. */ - if (SUPPORTS_WEAK && targetm.have_named_sections) + /* TARGET_USE_JCR_SECTION defaults to 1 if SUPPORTS_WEAK and + TARGET_ASM_NAMED_SECTION, else 0. Some targets meet those conditions + but lack suitable crtbegin/end objects or linker support. These + targets can overide the default in tm.h to use the fallback mechanism. */ + if (TARGET_USE_JCR_SECTION) { #ifdef JCR_SECTION_NAME tree t; @@ -2432,6 +2433,8 @@ emit_register_classes (tree *list_p) assemble_integer (XEXP (DECL_RTL (t), 0), POINTER_SIZE / BITS_PER_UNIT, POINTER_SIZE, 1); #else + /* A target has defined TARGET_USE_JCR_SECTION, but doesn't have a + JCR_SECTION_NAME. */ abort (); #endif } |