From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id 2CD68385841C for ; Fri, 18 Nov 2022 16:57:39 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 2CD68385841C Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1668790658; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=3pEVNKla6BWh+e2/UVvfy0yecYPvILQbs3dqbmYHNwA=; b=ZZ91dsjXf4592z3k9xbVcaKg0oZD2IDBJq1m1HuEIrsdqVY7hnTPSUr6NIN0e0iQuS/7Fq 5O5b5QccroS0i1H8h7bbSzJf9ctwFhGRIMAEUzztYhRPonO6FfYnBbftJWlumWN4XPQcdW pmaCVNgzBRVMBD++zYpJgaNNVTRNTlc= Received: from mail-wr1-f72.google.com (mail-wr1-f72.google.com [209.85.221.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-632-gfai8lcGMKCppMKws0Pllg-1; Fri, 18 Nov 2022 11:57:37 -0500 X-MC-Unique: gfai8lcGMKCppMKws0Pllg-1 Received: by mail-wr1-f72.google.com with SMTP id w23-20020adf8bd7000000b002358f733307so1805770wra.17 for ; Fri, 18 Nov 2022 08:57:37 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=3pEVNKla6BWh+e2/UVvfy0yecYPvILQbs3dqbmYHNwA=; b=Lwp+mjjJ5NlI3RrHUKdxBmzAP0kRM7pgKAxlSoe1OPrMSmG0Dqkd3bqdPLJwQyYmCv kH+rnOifFQxwjSKQLhQAytBBNYvNwV/j7cWI8wefKVfBk4vHIN84TKOGrxcm1q0Y+3gv v88X8BqguKrxWe4CxqLWyzPSVPszwNuWa/4kRMHn6dR54E5X4x02HUaITSqLfRdRO7Ir 9a9V4NBzkiUFnAp7OcOEES7XKB3NjPaViEV4LBoBLuL8WtjCRKIfEhvyEc2TojPk6Ack qojYcr3avLIsfiCY5PV/y9bJJb6JP1veSCx6YR6hVtA/U73RVLafWpQkooADIhqKEvP3 BXeQ== X-Gm-Message-State: ANoB5pnvJiBTY7JmND4qN67GhAyCH7+9GGOIqhnn7eYhpVu8QV21pPeN 0kyQVa121kEoYcfIdzdD/KfyhbR7SnCovvpDLg8FRrsQe9tSdWIa+k5MHwaJZRMUmw8X70jGDdN nIdHqF6Gf5JnRG3JruLLZHz2a4k0BlFs7C9IQExdomRoekCwwYp1PSuYDz1W+HldBJ/XB7tlyJQ == X-Received: by 2002:a5d:52d0:0:b0:241:c340:d1ea with SMTP id r16-20020a5d52d0000000b00241c340d1eamr1956680wrv.434.1668790656263; Fri, 18 Nov 2022 08:57:36 -0800 (PST) X-Google-Smtp-Source: AA0mqf7I8N/A/mH8hHZMFSwjn+Olj565cf35evQTb95z1ZOU882semSm1ZjdkGsDBn8AGZx0gJZncQ== X-Received: by 2002:a5d:52d0:0:b0:241:c340:d1ea with SMTP id r16-20020a5d52d0000000b00241c340d1eamr1956662wrv.434.1668790655842; Fri, 18 Nov 2022 08:57:35 -0800 (PST) Received: from localhost ([31.111.84.238]) by smtp.gmail.com with ESMTPSA id q6-20020a5d61c6000000b0022cce7689d3sm4792807wrv.36.2022.11.18.08.57.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 18 Nov 2022 08:57:35 -0800 (PST) From: Andrew Burgess To: gdb-patches@sourceware.org Cc: Andrew Burgess Subject: [PATCHv3 0/3] gdb/python: avoid throwing an exception over libopcodes code Date: Fri, 18 Nov 2022 16:57:29 +0000 Message-Id: X-Mailer: git-send-email 2.25.4 In-Reply-To: References: MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-5.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Changes since v2: - Rebase onto current upstream/master, no merged conflicts. Changes since v1: - Patch #1 is largely unchanged. I'm still in discussion with Simon as to whether this is the correct solution or not. - Patch #2 has grown a little since the first version I posted, I found a few extra callbacks which can be marked as noexcept. - Patch #3 is new, this adds the noexcept keyword to the typedefs used to handle the libopcode callbacks, but only when we compile for C++17 or later. --- Andrew Burgess (3): gdb/python: avoid throwing an exception over libopcodes code gdb/disasm: mark functions passed to the disassembler noexcept gdb: mark disassembler function callback types as noexcept gdb/disasm-selftests.c | 5 ++- gdb/disasm.c | 25 ++++++------ gdb/disasm.h | 48 ++++++++++++++++------ gdb/guile/scm-disasm.c | 2 +- gdb/python/py-disasm.c | 91 ++++++++++++++++++++++++++++++++---------- 5 files changed, 121 insertions(+), 50 deletions(-) base-commit: f9f88aede3bb84efd088a59a5f6bccb3a6bb6516 -- 2.25.4