From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 52291 invoked by alias); 25 Jul 2016 05:31:04 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 52274 invoked by uid 89); 25 Jul 2016 05:31:03 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.1 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mail-vk0-f47.google.com Received: from mail-vk0-f47.google.com (HELO mail-vk0-f47.google.com) (209.85.213.47) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Mon, 25 Jul 2016 05:31:02 +0000 Received: by mail-vk0-f47.google.com with SMTP id s189so229240347vkh.1 for ; Sun, 24 Jul 2016 22:31:02 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=5tB7/ggG9OGETVUIK9GqBP78q5yoFHmbh5pc6Cr1Rdo=; b=RraQCPegeJiwNKnqiGRRvNQO7LhO4+F1hesQtz/16hlRJpG389L/MREWZgr2Nkl02w Phkn1TxVesnqFT5U4TyrhsJM/0AxjR6uihbhiFhKSfyDa+uxruQwGPBbsgYbcMVRg88P YYVV189cMzeRede/ciaUKmp8ntvVxvGmcf5P9OSJXToqappU7f0/Dl+fbZk3PWtnArVy DEXn6s4dRJQDtYnYcQxznspYnZ7A3G/FAcGWQ63UgruoF1d7FCvvVjI15c7kU2KqmAD+ sNKj5kgn6FArfC+xoz7Y2A8KmFLljReCRA72QRuWkGw0MPuHvpi7o/7UiJq9mnEek84+ HB4Q== X-Gm-Message-State: AEkoouulE9pc9eC6+fOCVt3yta5yoDeCzhfG5bnAWljciWINsL99DYvDmYoVJAEnNY+cungD1VvCm9589sDBnw== X-Received: by 10.176.6.40 with SMTP id f37mr6549173uaf.8.1469424660143; Sun, 24 Jul 2016 22:31:00 -0700 (PDT) MIME-Version: 1.0 Received: by 10.103.153.4 with HTTP; Sun, 24 Jul 2016 22:30:59 -0700 (PDT) From: Paramjot Oberoi Date: Mon, 25 Jul 2016 05:31:00 -0000 Message-ID: Subject: How to Read Program Architecture from GDB/MI? To: gdb@sourceware.org Content-Type: text/plain; charset=UTF-8 X-SW-Source: 2016-07/txt/msg00024.txt.bz2 Hi all, I am attempting to get the CPU architecture of the currently debugged program via a GDB/MI command. I'm not sure what's I'm doing wrong: Console interpreter looks good: (gdb) show architecture The target architecture is set automatically (currently i386) MI interpreter succeeds without any data: (gdb) interpreter-exec mi "-gdb-show architecture" ^done If I set the arch to auto, then query with MI I get "auto" back...: (gdb) set arch auto The target architecture is set automatically (currently i386) (gdb) interpreter-exec mi "-gdb-show architecture" ^done,value="auto" Any advice on how I can query the architecture in GDB/MI mode? Thanks in advance, I appreciate it.