This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

ia64 eh, part 3


I needed the following in order to get libjava to build on ia64.
The configure special case for ia64 left INIT_SEGV undefined.

The new eh code does not define an __ia64_backtrace function.
Ideally this would be done inside the personality routine, which
would work for non-glibc systems that don't define backtrace either.
I've put comments in the personality routine to that effect as
a reminder.


r~


        * configure.in (ia64-*): Don't set SYSDEP_SOURCES.
        * java/lang/natThrowable.cc: Don't use __ia64_backtrace.

Index: configure.in
===================================================================
RCS file: /cvs/gcc/gcc/libjava/configure.in,v
retrieving revision 1.81
diff -c -p -d -r1.81 configure.in
*** configure.in	2001/05/01 17:45:09	1.81
--- configure.in	2001/05/12 06:23:14
*************** case "${host}" in
*** 730,739 ****
   sparc-sun-solaris*)
      SIGNAL_HANDLER=include/sparc-signal.h
      ;;
!  ia64-*)
!     SYSDEP_SOURCES=sysdep/ia64.c
!     test -d sysdep || mkdir sysdep
!     ;;
   *)
      SIGNAL_HANDLER=include/default-signal.h
      ;;
--- 730,739 ----
   sparc-sun-solaris*)
      SIGNAL_HANDLER=include/sparc-signal.h
      ;;
! # ia64-*)
! #    SYSDEP_SOURCES=sysdep/ia64.c
! #    test -d sysdep || mkdir sysdep
! #    ;;
   *)
      SIGNAL_HANDLER=include/default-signal.h
      ;;
Index: java/lang/natThrowable.cc
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/lang/natThrowable.cc,v
retrieving revision 1.9
diff -c -p -d -r1.9 natThrowable.cc
*** natThrowable.cc	2001/03/14 15:49:06	1.9
--- natThrowable.cc	2001/05/12 06:23:15
*************** details.  */
*** 39,48 ****
  
  #include <name-finder.h>
  
- #ifdef __ia64__
- extern "C" int __ia64_backtrace (void **array, int size);
- #endif
- 
  /* FIXME: size of the stack trace is limited to 128 elements.  It's
     undoubtedly sensible to limit the stack trace, but 128 is rather
     arbitrary.  It may be better to configure this.  */
--- 39,44 ----
*************** java::lang::Throwable::fillInStackTrace 
*** 52,67 ****
  {
    if (! trace_enabled)
      return this;
! #if defined (HAVE_BACKTRACE) || defined (__ia64__)
    void *p[128];
    
    // We subtract 1 from the number of elements because we don't want
    // to include the call to fillInStackTrace in the trace.
- #if defined (__ia64__)
-   int n = __ia64_backtrace (p, 128) - 1;  
- #else
    int n = backtrace (p, 128) - 1;  
- #endif
  
    if (n > 0)
      {
--- 48,59 ----
  {
    if (! trace_enabled)
      return this;
! #if defined (HAVE_BACKTRACE)
    void *p[128];
    
    // We subtract 1 from the number of elements because we don't want
    // to include the call to fillInStackTrace in the trace.
    int n = backtrace (p, 128) - 1;  
  
    if (n > 0)
      {


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]