From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13057 invoked by alias); 7 Dec 2004 18:42:26 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 12916 invoked from network); 7 Dec 2004 18:42:16 -0000 Received: from unknown (HELO pluton.ispras.ru) (83.149.199.253) by sourceware.org with SMTP; 7 Dec 2004 18:42:16 -0000 Received: (qmail 13548 invoked from network); 7 Dec 2004 18:41:29 -0000 Received: from unknown (HELO truba.ispras.ru) (83.149.198.41) by pluton.ispras.ru with SMTP; 7 Dec 2004 18:41:29 -0000 Received: from truba.ispras.ru (root@localhost) by truba.ispras.ru (8.13.1/8.13.1) with SMTP id iB7IcJtj030897 for ; Tue, 7 Dec 2004 21:38:19 +0300 Received: from ispserv.ispras.ru (ispserv [83.149.198.72]) by truba.ispras.ru (8.13.1/8.13.1) with ESMTP id iB7IcJHp030887; Tue, 7 Dec 2004 21:38:19 +0300 Received: from kite.ispras.ru (kite.ispras.ru [83.149.198.52]) by ispserv.ispras.ru (8.12.8/8.12.8) with ESMTP id iB7IfrDA005812; Tue, 7 Dec 2004 21:41:53 +0300 Date: Tue, 07 Dec 2004 18:42:00 -0000 From: Konstantin Karganov Reply-To: Konstantin Karganov Organization: ISP RAS Message-ID: <429477215.20041207214436@ispras.ru> To: Eli Zaretskii CC: gdb@sources.redhat.com Subject: Re[2]: complete GDB MI specification In-reply-To: <01c4dbd6$Blat.v2.2.2$0b225460@zahav.net.il> References: <3616850089.20041129165854@ispras.ru> <41AB43C8.7050500@gnu.org> <13730878711.20041129205245@ispras.ru> <18220744048.20041206192130@ispras.ru> <01c4dbd6$Blat.v2.2.2$0b225460@zahav.net.il> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-SpamTest-Version: SMTP-Filter Version 2.0.0 [0125], KAS/Release SMTP-Filter Version 2.0.0 [0125], KAS/Release X-Spamtest-Info: Pass through X-SW-Source: 2004-12/txt/msg00042.txt.bz2 Hello Eli, >> I'm going to implement a GUI debugger over GDB and need a complete >> description of MI commands and their result formats. Where can I find >> it? > In general, in the manual. "Note that the current ``grammar'' in the MI documentation, at least as far as I'm concerned, is meant to be an informal introduction of the MI syntax, not a rigurous grammar description." (ñ) Eli Zaretskii :) And this is the problem! MI is supposed to be a program-to-program interface and thus needs a complete formal description (at least, to be sure that all possible output is handled correctly). > There was a long series of discussions about a month ago, either here > or on gdb-patches. Search for "MI" in the archives, and you will find > a patch with a formal parser grammar for the MI interface. Looked through several (a lot, actually!) discussions and didn't found what I need. There were several syntax patches and grammar transformations (mostly by Bob Rossi and Michael Chastain), but all of them concern general syntax of MI output but don't go into details and the output semantics. > Please report all such unclear cases, and I will try to fix them. Look at the structure of MI description: there are the command syntax with explanation and the example of the output. Just an example instead of complete output specification. Yes, it fits the general case of " var=value (,var=value)* " syntax but the actual semantics and possible value pairs are not specified. That is for all commands. Another practical example: displaying the value of the array variable. It turns out, that the value of the array fits the "c-string" grammar terminal symbol. But the inner structure of this string is not specified. I expected that there should be a list of values of the array length, but it turned out that there is at least one optimization in the form of "X ". What other tricks are possible in value string? :) Anyway, it looks weird if no rigorous specification of MI output exist. IMHO it means (if it is) that no one uses MI in real systems (except the tests and demo purposes)... -- Best regards, Konstantin