This is the mail archive of the
gdb-prs@sources.redhat.com
mailing list for the GDB project.
Re: gdb/671: Changing GDB/MI spec say the should be a termination"(gdb)\n" string
- From: Andrew Cagney <ac131313 at ges dot redhat dot com>
- To: nobody at sources dot redhat dot com
- Cc: gdb-prs at sources dot redhat dot com,
- Date: 26 Aug 2002 19:18:00 -0000
- Subject: Re: gdb/671: Changing GDB/MI spec say the should be a termination"(gdb)\n" string
- Reply-to: Andrew Cagney <ac131313 at ges dot redhat dot com>
The following reply was made to PR gdb/671; it has been noted by GNATS.
From: Andrew Cagney <ac131313@ges.redhat.com>
To: alain@qnx.com
Cc: gdb-gnats@sources.redhat.com
Subject: Re: gdb/671: Changing GDB/MI spec say the should be a termination
"(gdb)\n" string
Date: Mon, 26 Aug 2002 15:13:45 -0400
> 1:int main() {
> 2: int x;
> 3: pthread_create(NULL, NULL, routine, NULL);
> 4: printf("Hello world\n");
> 5: sleep(200000); // Or a very time consuming function called.
> 6: printf("After the long wait\n");
> 7: return 0;
> 8:}
>
> gdb/mi will issue things like:
> (gdb)
> -break-insert file.c:6
> ^done,bkpt={...}
Is there a ``run/continue'' missing in here somewhere?
> ~"[New Thread 1024 (LWP 30497)]\n"
> ~"[Switching to Thread 1024 (LWP 30497)]\n"
> .... wait for the sleep ....
> *stopped,reason=...
> (gdb)
>
> You do not have the "(gdb)" comming right away.
>
> OUTPUT ==> (OUT-OF-BAND-RECORD)* [RESULT-RECORD] "(gdb)"nl
>
> I read the definition like you can accumulate outputs and deal with them only
> when encounter "(gdb)" which is true unless you want to wait for the sleep() to
> finish. In practice we can consider Out-of-band completely async and should be
> process right away. It was not clear at first sight, IMHO.
Is this an async target (target remote-async)? No current native target
is async. This makes correctly implemeting out-of-band messages very
difficult.
Andrew