This is the mail archive of the gdb-patches@sourceware.cygnus.com mailing list for the GDB project.


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

Re: (patch) hpjyg15: hppah-nat.c & related


Jimmy Guo wrote:
> 
> This patch updates hppah-nat.c and related files target.[ch] and
> infrun.c.  See ChangeLog below.

Jim,

Don't forget that the GDB's coding style is defined by the output of
indent.  Looking more closely I noticed that some of the changes are to
``fix'' the indentation. Please just grit your teath and ignore it.

It's a good idea to carefully review the diffs and revert/remove any
changes not specific to the problem at hand.

Doing this makes the reviewers life so much easier.

	enjoy,
		Andrew


> ***************
> *** 74,80 ****
>         len = REGISTER_RAW_SIZE (regno);
> 
>         /* Requests for register zero actually want the save_state's
> !        ss_flags member.  As RM says: "Oh, what a hack!"  */
>         if (regno == 0)
>         {
>           save_state_t ss;
> --- 74,80 ----
>         len = REGISTER_RAW_SIZE (regno);
> 
>         /* Requests for register zero actually want the save_state's
> !          ss_flags member.  As RM says: "Oh, what a hack!"  */
>         if (regno == 0)
>         {
>           save_state_t ss;
> ***************
> *** 90,109 ****
> 
>         /* Floating-point registers come from the ss_fpblock area.  */
>         else if (regno >= FP0_REGNUM)
> !       addr = (HPPAH_OFFSETOF (save_state_t, ss_fpblock)
>                 + (REGISTER_BYTE (regno) - REGISTER_BYTE (FP0_REGNUM)));
> 
>         /* Wide registers come from the ss_wide area.
> !        I think it's more PC to test (ss_flags & SS_WIDEREGS) to select
> !        between ss_wide and ss_narrow than to use the raw register size.
> !        But checking ss_flags would require an extra ptrace call for
> !        every register reference.  Bleah.  */
>         else if (len == 8)
> !       addr = (HPPAH_OFFSETOF (save_state_t, ss_wide)
>                 + REGISTER_BYTE (regno));
> 
>         /* Narrow registers come from the ss_narrow area.  Note that
> !        ss_narrow starts with gr1, not gr0.  */
>         else if (len == 4)
>         addr = (HPPAH_OFFSETOF (save_state_t, ss_narrow)
>                 + (REGISTER_BYTE (regno) - REGISTER_BYTE (1)));
> --- 90,109 ----
> 
>         /* Floating-point registers come from the ss_fpblock area.  */
>         else if (regno >= FP0_REGNUM)
> !       addr = (HPPAH_OFFSETOF (save_state_t, ss_fpblock)
>                 + (REGISTER_BYTE (regno) - REGISTER_BYTE (FP0_REGNUM)));
> 
>         /* Wide registers come from the ss_wide area.
> !          I think it's more PC to test (ss_flags & SS_WIDEREGS) to select
> !          between ss_wide and ss_narrow than to use the raw register size.
> !          But checking ss_flags would require an extra ptrace call for
> !          every register reference.  Bleah.  */
>         else if (len == 8)
> !       addr = (HPPAH_OFFSETOF (save_state_t, ss_wide)
>                 + REGISTER_BYTE (regno));
> 
>         /* Narrow registers come from the ss_narrow area.  Note that
> !          ss_narrow starts with gr1, not gr0.  */
>         else if (len == 4)
>         addr = (HPPAH_OFFSETOF (save_state_t, ss_narrow)
>                 + (REGISTER_BYTE (regno) - REGISTER_BYTE (1)));
> ***************
> *** 112,131 ****
> 
>   #ifdef GDB_TARGET_IS_HPPA_20W
>         /* Unbelieveable.  The PC head and tail must be written in 64bit hunks
> !        or we will get an error.  Worse yet, the oddball ptrace/ttrace
> !        layering will not allow us to perform a 64bit register store.
> 
> !        What a crock.  */
>         if (regno == PCOQ_HEAD_REGNUM || regno == PCOQ_TAIL_REGNUM && len == 8)
>         {
>           CORE_ADDR temp;
> 
> !         temp = *(CORE_ADDR *)&registers[REGISTER_BYTE (regno)];
> 
>           /* Set the priv level (stored in the low two bits of the PC.  */
>           temp |= 0x3;
> 
> !         ttrace_write_reg_64 (inferior_pid, (CORE_ADDR)addr, (CORE_ADDR)&temp);
> 
>           /* If we fail to write the PC, give a true error instead of
>              just a warning.  */
> --- 112,131 ----
> 
>   #ifdef GDB_TARGET_IS_HPPA_20W
>         /* Unbelieveable.  The PC head and tail must be written in 64bit hunks
> !          or we will get an error.  Worse yet, the oddball ptrace/ttrace
> !          layering will not allow us to perform a 64bit register store.
> 
> !          What a crock.  */
>         if (regno == PCOQ_HEAD_REGNUM || regno == PCOQ_TAIL_REGNUM && len == 8)
>         {
>           CORE_ADDR temp;
> 
> !         temp = *(CORE_ADDR *) &registers[REGISTER_BYTE (regno)];
> 
>           /* Set the priv level (stored in the low two bits of the PC.  */
>           temp |= 0x3;
> 
> !         ttrace_write_reg_64 (inferior_pid, (CORE_ADDR) addr, (CORE_ADDR) &temp);
> 
>           /* If we fail to write the PC, give a true error instead of
>              just a warning.  */
> ***************
> *** 134,150 ****
>               char *err = safe_strerror (errno);
>               char *msg = alloca (strlen (err) + 128);
>               sprintf (msg, "writing `%s' register: %s",
> !                       REGISTER_NAME (regno), err);
>               perror_with_name (msg);
>             }
>           return;
>         }
> 
>         /* Another crock.  HPUX complains if you write a nonzero value to
> !        the high part of IPSW.  What will it take for HP to catch a
> !        clue about building sensible interfaces?  */
> !      if (regno == IPSW_REGNUM && len == 8)
> !       *(int *)&registers[REGISTER_BYTE (regno)] = 0;
>   #endif
> 
>         for (i = 0; i < len; i += sizeof (int))
> --- 134,150 ----
>               char *err = safe_strerror (errno);
>               char *msg = alloca (strlen (err) + 128);
>               sprintf (msg, "writing `%s' register: %s",
> !                      REGISTER_NAME (regno), err);
>               perror_with_name (msg);
>             }
>           return;
>         }
> 
>         /* Another crock.  HPUX complains if you write a nonzero value to
> !          the high part of IPSW.  What will it take for HP to catch a
> !          clue about building sensible interfaces?  */
> !       if (regno == IPSW_REGNUM && len == 8)
> !       *(int *) &registers[REGISTER_BYTE (regno)] = 0;
>   #endif
> 
>         for (i = 0; i < len; i += sizeof (int))
> ***************
> *** 155,167 ****
>           if (errno != 0)
>             {
>               /* Warning, not error, in case we are attached; sometimes
> !                the kernel doesn't let us at the registers. */
>               char *err = safe_strerror (errno);
>               char *msg = alloca (strlen (err) + 128);
>               sprintf (msg, "writing `%s' register: %s",
> !                       REGISTER_NAME (regno), err);
>               /* If we fail to write the PC, give a true error instead of
> !                just a warning.  */
>               if (regno == PCOQ_HEAD_REGNUM || regno == PCOQ_TAIL_REGNUM)
>                 perror_with_name (msg);
>               else
> --- 155,167 ----
>           if (errno != 0)
>             {
>               /* Warning, not error, in case we are attached; sometimes
> !                the kernel doesn't let us at the registers. */
>               char *err = safe_strerror (errno);
>               char *msg = alloca (strlen (err) + 128);
>               sprintf (msg, "writing `%s' register: %s",
> !                      REGISTER_NAME (regno), err);
>               /* If we fail to write the PC, give a true error instead of
> !                just a warning.  */
>               if (regno == PCOQ_HEAD_REGNUM || regno == PCOQ_TAIL_REGNUM)
>                 perror_with_name (msg);
>               else
> ***************
> *** 197,212 ****
>         len = sizeof (ss.ss_flags);
> 
>         /* Note that ss_flags is always an int, no matter what
> !        REGISTER_RAW_SIZE(0) says.  Assuming all HP-UX PA machines
> !        are big-endian, put it at the least significant end of the
> !        value, and zap the rest of the buffer.  */
>         offset = REGISTER_RAW_SIZE (0) - len;
>         memset (buf, 0, sizeof (buf));
>       }
> 
>     /* Floating-point registers come from the ss_fpblock area.  */
>     else if (regno >= FP0_REGNUM)
> !     addr = (HPPAH_OFFSETOF (save_state_t, ss_fpblock)
>             + (REGISTER_BYTE (regno) - REGISTER_BYTE (FP0_REGNUM)));
> 
>     /* Wide registers come from the ss_wide area.
> --- 197,212 ----
>         len = sizeof (ss.ss_flags);
> 
>         /* Note that ss_flags is always an int, no matter what
> !          REGISTER_RAW_SIZE(0) says.  Assuming all HP-UX PA machines
> !          are big-endian, put it at the least significant end of the
> !          value, and zap the rest of the buffer.  */
>         offset = REGISTER_RAW_SIZE (0) - len;
>         memset (buf, 0, sizeof (buf));
>       }
> 
>     /* Floating-point registers come from the ss_fpblock area.  */
>     else if (regno >= FP0_REGNUM)
> !     addr = (HPPAH_OFFSETOF (save_state_t, ss_fpblock)
>             + (REGISTER_BYTE (regno) - REGISTER_BYTE (FP0_REGNUM)));
> 
>     /* Wide registers come from the ss_wide area.
> ***************
> *** 215,221 ****
>        But checking ss_flags would require an extra ptrace call for
>        every register reference.  Bleah.  */
>     else if (len == 8)
> !     addr = (HPPAH_OFFSETOF (save_state_t, ss_wide)
>             + REGISTER_BYTE (regno));
> 
>     /* Narrow registers come from the ss_narrow area.  Note that
> --- 215,221 ----
>        But checking ss_flags would require an extra ptrace call for
>        every register reference.  Bleah.  */
>     else if (len == 8)
> !     addr = (HPPAH_OFFSETOF (save_state_t, ss_wide)
>             + REGISTER_BYTE (regno));
> 
>     /* Narrow registers come from the ss_narrow area.  Note that
> ***************
> *** 232,240 ****
>         errno = 0;
>         /* Copy an int from the U area to buf.  Fill the least
>            significant end if len != raw_size.  */
> !       * (int *) &buf[offset + i] =
> !         call_ptrace (PT_RUREGS, inferior_pid,
> !                      (PTRACE_ARG3_TYPE) addr + i, 0);
>         if (errno != 0)
>         {
>           /* Warning, not error, in case we are attached; sometimes
> --- 232,240 ----
>         errno = 0;
>         /* Copy an int from the U area to buf.  Fill the least
>            significant end if len != raw_size.  */
> !       *(int *) &buf[offset + i] =
> !       call_ptrace (PT_RUREGS, inferior_pid,
> !                    (PTRACE_ARG3_TYPE) addr + i, 0);
>         if (errno != 0)
>         {
>           /* Warning, not error, in case we are attached; sometimes
> ***************
> *** 277,283 ****
>   {
>     register int i;
>     /* Round starting address down to longword boundary.  */
> !   register CORE_ADDR addr = memaddr & - (CORE_ADDR)(sizeof (int));
>     /* Round ending address up; get number of longwords that makes.  */
>     register int count
>     = (((memaddr + len) - addr) + sizeof (int) - 1) / sizeof (int);
> --- 277,283 ----
>   {
>     register int i;
>     /* Round starting address down to longword boundary.  */
> !   register CORE_ADDR addr = memaddr & -(CORE_ADDR) (sizeof (int));
>     /* Round ending address up; get number of longwords that makes.  */
>     register int count
>     = (((memaddr + len) - addr) + sizeof (int) - 1) / sizeof (int);
> ***************
> *** 363,370 ****
>                                    inferior_pid, (PTRACE_ARG3_TYPE) addr, 0);
>           if (errno)
>             {
> !             free (buffer);
> !             return 0;
>             }
>           QUIT;
>         }
> --- 363,379 ----
>                                    inferior_pid, (PTRACE_ARG3_TYPE) addr, 0);
>           if (errno)
>             {
> !             /* As above, we may have guessed wrong about code vs. data, so
> !                        try it the other way. */
> !             errno = 0;
> !             buffer[i] = call_ptrace (addr >= text_end ?
> !                                      PT_RIUSER : PT_RDUSER,
> !                                      inferior_pid,
> !                                      (PTRACE_ARG3_TYPE) addr, 0);
> !             if (errno) {
> !               free(buffer);
> !               return 0;
> !             }
>             }
>           QUIT;
>         }
> ***************
> *** 697,702 ****
> --- 706,713 ----
>   {
>   #if defined(PT_SET_EVENT_MASK)
>     int pt_status;
> +   int nsigs;
> +   int signum;
>     ptrace_event_t ptrace_events;
> 
>     /* Instruct the kernel as to the set of events we wish to be
> ***************
> *** 709,715 ****
>        the kernel to keep certain signals hidden from us, we do it
>        by calling sigdelset (ptrace_events.pe_signals, signal) for
>        each such signal here, before doing PT_SET_EVENT_MASK.  */
> !   sigemptyset (&ptrace_events.pe_signals);
> 
>     ptrace_events.pe_set_event = 0;
> 
> --- 720,749 ----
>        the kernel to keep certain signals hidden from us, we do it
>        by calling sigdelset (ptrace_events.pe_signals, signal) for
>        each such signal here, before doing PT_SET_EVENT_MASK.  */
> !   /* RM: The above comment is no longer true. We start with ignoring
> !    * all signals, and then add the ones we are interested in. We could
> !    * do it the other way: start by looking at all signals and then
> !    * deleting the ones that we aren't interested in, except that
> !    * multiple gdb signals may be mapped to the same host signal
> !    * (eg. TARGET_SIGNAL_IO and TARGET_SIGNAL_POLL both get mapped to
> !    * signal 22 on HPUX 10.20) We want to be notified if we are
> !    * interested in either signal.
> !    */
> !   sigfillset (&ptrace_events.pe_signals);
> !
> !   /* RM: Let's not bother with signals we don't care about */
> !   nsigs = (int) TARGET_SIGNAL_LAST;
> !   for (signum = nsigs; signum > 0; signum--)
> !     {
> !       if ((signal_stop_state (signum)) ||
> !         (signal_print_state (signum)) ||
> !         (!signal_pass_state (signum)))
> !       {
> !         if (target_signal_exists (signum))
> !           sigdelset (&ptrace_events.pe_signals,
> !                      target_signal_to_host (signum));
> !       }
> !     }
> 
>     ptrace_events.pe_set_event = 0;
> 
> ***************
> *** 724,730 ****
>     errno = 0;
>     pt_status = call_ptrace (PT_SET_EVENT_MASK,
>                            pid,
> !                          (PTRACE_ARG3_TYPE) & ptrace_events,
>                            sizeof (ptrace_events));
>     if (errno)
>       perror_with_name ("ptrace");
> --- 758,764 ----
>     errno = 0;
>     pt_status = call_ptrace (PT_SET_EVENT_MASK,
>                            pid,
> !                          (PTRACE_ARG3_TYPE) &ptrace_events,
>                            sizeof (ptrace_events));
>     if (errno)
>       perror_with_name ("ptrace");
> ***************
> *** 763,769 ****
>     errno = 0;
>     pt_status = call_ptrace (PT_SET_EVENT_MASK,
>                            pid,
> !                          (PTRACE_ARG3_TYPE) & ptrace_events,
>                            sizeof (ptrace_events));
>     if (errno)
>       perror_with_name ("ptrace");
> --- 797,803 ----
>     errno = 0;
>     pt_status = call_ptrace (PT_SET_EVENT_MASK,
>                            pid,
> !                          (PTRACE_ARG3_TYPE) &ptrace_events,
>                            sizeof (ptrace_events));
>     if (errno)
>       perror_with_name ("ptrace");
> ***************
> *** 913,919 ****
>     errno = 0;
>     pt_status = call_ptrace (PT_GET_PROCESS_STATE,
>                            pid,
> !                          (PTRACE_ARG3_TYPE) & ptrace_state,
>                            sizeof (ptrace_state));
>     if (errno)
>       perror_with_name ("ptrace");
> --- 947,953 ----
>     errno = 0;
>     pt_status = call_ptrace (PT_GET_PROCESS_STATE,
>                            pid,
> !                          (PTRACE_ARG3_TYPE) &ptrace_state,
>                            sizeof (ptrace_state));
>     if (errno)
>       perror_with_name ("ptrace");
> ***************
> *** 947,953 ****
>     errno = 0;
>     pt_status = call_ptrace (PT_GET_PROCESS_STATE,
>                            pid,
> !                          (PTRACE_ARG3_TYPE) & ptrace_state,
>                            sizeof (ptrace_state));
>     if (errno)
>       perror_with_name ("ptrace");
> --- 981,987 ----
>     errno = 0;
>     pt_status = call_ptrace (PT_GET_PROCESS_STATE,
>                            pid,
> !                          (PTRACE_ARG3_TYPE) &ptrace_state,
>                            sizeof (ptrace_state));
>     if (errno)
>       perror_with_name ("ptrace");
> ***************
> *** 1008,1013 ****
> --- 1042,1049 ----
>        int pid;
>        char **execd_pathname;
>   {
> +   static char saved_pathname[1024];
> +
>     /* This request is only available on HPUX 10.0 and later.  */
>   #if !defined(PT_GET_PROCESS_STATE)
>     *execd_pathname = NULL;
> ***************
> *** 1020,1026 ****
>     errno = 0;
>     pt_status = call_ptrace (PT_GET_PROCESS_STATE,
>                            pid,
> !                          (PTRACE_ARG3_TYPE) & ptrace_state,
>                            sizeof (ptrace_state));
>     if (errno)
>       perror_with_name ("ptrace");
> --- 1056,1062 ----
>     errno = 0;
>     pt_status = call_ptrace (PT_GET_PROCESS_STATE,
>                            pid,
> !                          (PTRACE_ARG3_TYPE) &ptrace_state,
>                            sizeof (ptrace_state));
>     if (errno)
>       perror_with_name ("ptrace");
> ***************
> *** 1029,1036 ****
> 
>     if (ptrace_state.pe_report_event & PTRACE_EXEC)
>       {
> !       char *exec_file = target_pid_to_exec_file (pid);
> !       *execd_pathname = savestring (exec_file, strlen (exec_file));
>         return 1;
>       }
> 
> --- 1065,1083 ----
> 
>     if (ptrace_state.pe_report_event & PTRACE_EXEC)
>       {
> !       char *exec_file;
> !
> !       if (ptrace_state.pe_path_len > 0)
> !       {
> !         /* RM: ptrace reports 2 exec events per exec. Only the first one
> !            allows us to get a valid pathname. For the second one simply
> !            return the previously cached pathname */
> !         exec_file = target_pid_to_exec_file (pid);
> !         *execd_pathname = savestring (exec_file, strlen (exec_file));
> !         strncpy (saved_pathname, exec_file, sizeof (saved_pathname) - 1);
> !       }
> !       else
> !       *execd_pathname = saved_pathname;
>         return 1;
>       }
> 
> ***************
> *** 1064,1069 ****
> --- 1111,1117 ----
>   {
>     static char exec_file_buffer[1024];
>     int pt_status;
> +   ptrace_state_t ptrace_state;
>     CORE_ADDR top_of_stack;
>     char four_chars[4];
>     int name_index;
> ***************
> *** 1073,1084 ****
> 
>   #ifdef PT_GET_PROCESS_PATHNAME
>     /* As of 10.x HP-UX, there's an explicit request to get the pathname. */
> !   pt_status = call_ptrace (PT_GET_PROCESS_PATHNAME,
>                            pid,
> !                          (PTRACE_ARG3_TYPE) exec_file_buffer,
> !                          sizeof (exec_file_buffer) - 1);
> !   if (pt_status == 0)
> !     return exec_file_buffer;
>   #endif
> 
>     /* It appears that this request is broken prior to 10.30.
> --- 1121,1146 ----
> 
>   #ifdef PT_GET_PROCESS_PATHNAME
>     /* As of 10.x HP-UX, there's an explicit request to get the pathname. */
> !   /* RM: According to the documentation, this request only works right
> !    * after an exec */
> !   errno = 0;
> !   pt_status = call_ptrace (PT_GET_PROCESS_STATE,
>                            pid,
> !                          (PTRACE_ARG3_TYPE) &ptrace_state,
> !                          sizeof (ptrace_state));
> !   if (errno)
> !     perror_with_name ("ptrace");
> !
> !   if (ptrace_state.pe_report_event & PTRACE_EXEC)
> !     {
> !       pt_status = call_ptrace (PT_GET_PROCESS_PATHNAME,
> !                              pid,
> !                              (PTRACE_ARG3_TYPE) exec_file_buffer,
> !                              sizeof (exec_file_buffer) - 1);
> !       /* RM: ??? pt_status < 0 indicates failure, I think */
> !       if (pt_status >= 0)
> !       return exec_file_buffer;
> !     }
>   #endif
> 
>     /* It appears that this request is broken prior to 10.30.
> Index: gdb/target.c
> /opt/gnu/bin/diff -r -c -N  /view/guo.wdb.c//CLO/Components/WDB/Src/gnu/gdb/target.c gdb/target.c
> *** /view/guo.wdb.c//CLO/Components/WDB/Src/gnu/gdb/target.c    Fri Nov  5 17:36:01 1999
> --- gdb/target.c        Fri Nov  5 17:37:12 1999
> ***************
> *** 1915,1920 ****
> --- 1915,2066 ----
>       }
>   }
> 
> + int
> + target_signal_exists (oursig)
> +      enum target_signal oursig;
> + {
> +   switch (oursig)
> +     {
> +     case TARGET_SIGNAL_0:
> + #if defined (SIGHUP)
> +     case TARGET_SIGNAL_HUP:
> + #endif
> + #if defined (SIGINT)
> +     case TARGET_SIGNAL_INT:
> + #endif
> + #if defined (SIGQUIT)
> +     case TARGET_SIGNAL_QUIT:
> + #endif
> + #if defined (SIGILL)
> +     case TARGET_SIGNAL_ILL:
> + #endif
> + #if defined (SIGTRAP)
> +     case TARGET_SIGNAL_TRAP:
> + #endif
> + #if defined (SIGABRT)
> +     case TARGET_SIGNAL_ABRT:
> + #endif
> + #if defined (SIGEMT)
> +     case TARGET_SIGNAL_EMT:
> + #endif
> + #if defined (SIGFPE)
> +     case TARGET_SIGNAL_FPE:
> + #endif
> + #if defined (SIGKILL)
> +     case TARGET_SIGNAL_KILL:
> + #endif
> + #if defined (SIGBUS)
> +     case TARGET_SIGNAL_BUS:
> + #endif
> + #if defined (SIGSEGV)
> +     case TARGET_SIGNAL_SEGV:
> + #endif
> + #if defined (SIGSYS)
> +     case TARGET_SIGNAL_SYS:
> + #endif
> + #if defined (SIGPIPE)
> +     case TARGET_SIGNAL_PIPE:
> + #endif
> + #if defined (SIGALRM)
> +     case TARGET_SIGNAL_ALRM:
> + #endif
> + #if defined (SIGTERM)
> +     case TARGET_SIGNAL_TERM:
> + #endif
> + #if defined (SIGUSR1)
> +     case TARGET_SIGNAL_USR1:
> + #endif
> + #if defined (SIGUSR2)
> +     case TARGET_SIGNAL_USR2:
> + #endif
> + #if defined (SIGCHLD) || defined (SIGCLD)
> +     case TARGET_SIGNAL_CHLD:
> + #endif /* SIGCLD or SIGCHLD */
> + #if defined (SIGPWR)
> +     case TARGET_SIGNAL_PWR:
> + #endif
> + #if defined (SIGWINCH)
> +     case TARGET_SIGNAL_WINCH:
> + #endif
> + #if defined (SIGURG)
> +     case TARGET_SIGNAL_URG:
> + #endif
> + #if defined (SIGIO)
> +     case TARGET_SIGNAL_IO:
> + #endif
> + #if defined (SIGPOLL)
> +     case TARGET_SIGNAL_POLL:
> + #endif
> + #if defined (SIGSTOP)
> +     case TARGET_SIGNAL_STOP:
> + #endif
> + #if defined (SIGTSTP)
> +     case TARGET_SIGNAL_TSTP:
> + #endif
> + #if defined (SIGCONT)
> +     case TARGET_SIGNAL_CONT:
> + #endif
> + #if defined (SIGTTIN)
> +     case TARGET_SIGNAL_TTIN:
> + #endif
> + #if defined (SIGTTOU)
> +     case TARGET_SIGNAL_TTOU:
> + #endif
> + #if defined (SIGVTALRM)
> +     case TARGET_SIGNAL_VTALRM:
> + #endif
> + #if defined (SIGPROF)
> +     case TARGET_SIGNAL_PROF:
> + #endif
> + #if defined (SIGXCPU)
> +     case TARGET_SIGNAL_XCPU:
> + #endif
> + #if defined (SIGXFSZ)
> +     case TARGET_SIGNAL_XFSZ:
> + #endif
> + #if defined (SIGWIND)
> +     case TARGET_SIGNAL_WIND:
> + #endif
> + #if defined (SIGPHONE)
> +     case TARGET_SIGNAL_PHONE:
> + #endif
> + #if defined (SIGLOST)
> +     case TARGET_SIGNAL_LOST:
> + #endif
> + #if defined (SIGWAITING)
> +     case TARGET_SIGNAL_WAITING:
> + #endif
> + #if defined (SIGLWP)
> +     case TARGET_SIGNAL_LWP:
> + #endif
> + #if defined (SIGDANGER)
> +     case TARGET_SIGNAL_DANGER:
> + #endif
> + #if defined (SIGGRANT)
> +     case TARGET_SIGNAL_GRANT:
> + #endif
> + #if defined (SIGRETRACT)
> +     case TARGET_SIGNAL_RETRACT:
> + #endif
> + #if defined (SIGMSG)
> +     case TARGET_SIGNAL_MSG:
> + #endif
> + #if defined (SIGSOUND)
> +     case TARGET_SIGNAL_SOUND:
> + #endif
> + #if defined (SIGSAK)
> +     case TARGET_SIGNAL_SAK:
> + #endif
> + #if defined (SIGPRIO)
> +     case TARGET_SIGNAL_PRIO:
> + #endif
> +       return 1;
> +
> +     default:
> +       return 0;
> +     }
> + }
> +
>   /* Helper function for child_wait and the Lynx derivatives of child_wait.
>      HOSTSTATUS is the waitstatus from wait() or the equivalent; store our
>      translation of that in OURSTATUS.  */
> Index: gdb/target.h
> /opt/gnu/bin/diff -r -c -N  /view/guo.wdb.c//CLO/Components/WDB/Src/gnu/gdb/target.h gdb/target.h
> *** /view/guo.wdb.c//CLO/Components/WDB/Src/gnu/gdb/target.h    Fri Nov  5 17:37:37 1999
> --- gdb/target.h        Fri Nov  5 17:38:12 1999
> ***************
> *** 1327,1332 ****
> --- 1327,1333 ----
>   /* Convert between host signal numbers and enum target_signal's.  */
>   extern enum target_signal target_signal_from_host PARAMS ((int));
>   extern int target_signal_to_host PARAMS ((enum target_signal));
> + extern int target_signal_exists PARAMS ((enum target_signal));
> 
>   /* Convert from a number used in a GDB command to an enum target_signal.  */
>   extern enum target_signal target_signal_from_command PARAMS ((int));
> Index: gdb/infrun.c
> /opt/gnu/bin/diff -r -c -N  /view/guo.wdb.c//CLO/Components/WDB/Src/gnu/gdb/infrun.c gdb/infrun.c
> *** /view/guo.wdb.c//CLO/Components/WDB/Src/gnu/gdb/infrun.c    Fri Nov  5 18:37:38 1999
> --- gdb/infrun.c        Fri Nov  5 18:38:41 1999
> ***************
> *** 3621,3626 ****
> --- 3621,3633 ----
>         }
>       }
> 
> +
> + #ifdef GDB_TARGET_IS_HPPA
> +   /* RM: Use OS interface to ignore signals we don't care about */
> +   if (target_has_execution)
> +     require_notification_of_events (inferior_pid);
> + #endif
> +
>     do_cleanups (old_chain);
>   }
>

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