SUMMARY2: can't install multiple breakpoints

From: Kevin Dea <kdea_at_alpine-la.com>
Date: Fri, 11 May 2001 17:36:44 -0700

Hello Managers,

I've already posted a summary, but it would be a shame to exclude Dr.
Blinn's wisdom so here is a second answer to my question:


There is code in the kernel that installs breakpoints in user space
processes, for instance, if a debugger is single stepping through a
user program and the program does a syscall, you can't single step
the kernel code, but as you leave the kernel, you put a breakpoint
at the next instruction in user space so that execution will trap
into the debugger. There is special case code for dealing with the
case of signals, as well. I suspect that if a signal is delivered
to a process while it's in a syscall, it MIGHT trigger that message.

Here is the kernel code, and you can see the test that triggers the
message; I *think* it's a kernel debugging message, but there are no
comments in the vicinity of the code to make it clear what anyone
is supposed to do if the message appears:

install_bp()
{
        unsigned int inst;
        unsigned long target_pc;

#ifdef SHOW
        printf("install_bp\n");
#endif
        if (current_pcb()->pcb_ssi.ssi_cnt)
                printf("install_bp: can't install multiple
breakpoints!!\n");
        /*
         * If user can't access where his pc points, we give up.
         * He'll be getting a SIGSEGV shortly anyway!
         */
        if (!useracc(USER_REG(EF_PC), sizeof(int), B_READ))
                return;
        inst = fuiword(USER_REG(EF_PC));
        if (isa_branch(inst)) {
                target_pc = branch_target(inst, USER_REG(EF_PC));
                if (target_pc != USER_REG(EF_PC))
                        set_bp(target_pc);
        }
        set_bp(USER_REG(EF_PC)+4);
        /*
         * only install breakpoints once!
         */
        current_pcb()->pcb_sstep = 0;
}

If you have a support contract, you could report this, if you can
figure out what's triggering it. I *suspect* it's a side effect of
using single stepping while debugging a program that gets signals
while it's in a syscall (that's based on looking at the places in
the kernel where this routine gets called, there might be a race
or some logic error involved).

Otherwise, I suspect you can safely ignore it.



---original question---

> I found the following messages on my console and on /var/adm/messages:
>
> May 10 08:25:26 abel vmunix: install_bp: can't install multiple
> breakpoints!!
> May 10 08:27:06 abel vmunix: install_bp: can't install multiple
> breakpoints!!
>
> I can't find anything on the archives that has an answer. Can someone
> tell me what this means?
>
> The machine is an DS20 running Tru64 4.0F, with no patches (only gigabit
> card driver upgrade).

-- 
Kevin Dea
UNIX System Administrator
Alpine Electronics Research of America
Received on Sat May 12 2001 - 00:38:39 NZST

This archive was generated by hypermail 2.4.0 : Wed Nov 08 2023 - 11:53:42 NZDT