From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id 2TwlG2hIRmroWSIAWB0awg (envelope-from ) for ; Thu, 02 Jul 2026 07:15:52 -0400 Received: by simark.ca (Postfix, from userid 112) id 5CC541E024; Thu, 02 Jul 2026 07:15:52 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-5.3 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,WEIRD_PORT autolearn=ham autolearn_force=no version=4.0.1 Received: from vm01.sourceware.org (vm01.sourceware.org [IPv6:2620:52:6:3111::32]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 960941E024 for ; Thu, 02 Jul 2026 07:15:51 -0400 (EDT) Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 205D74BA7994 for ; Thu, 2 Jul 2026 11:15:50 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 205D74BA7994 Received: from mail-wm1-f50.google.com (mail-wm1-f50.google.com [209.85.128.50]) by sourceware.org (Postfix) with ESMTPS id 4C7D84BA23EE for ; Thu, 2 Jul 2026 11:15:25 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 4C7D84BA23EE Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=palves.net Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 4C7D84BA23EE Authentication-Results: sourceware.org; arc=none smtp.remote-ip=209.85.128.50 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1782990925; cv=none; b=RG0pGqFr2djKokFcnyWm9eyPFFYhudBWbKnrW2tepnuMPUQQmhrPYuGfmuBhzlGBF9S5FBo3IRJcd/0OluGHAKEcfmtTxAKlmr7AjLoc5NOoXCO1WaCf1CagTiTomocQ6trZ0AATKJUET1W8uAvjA3x31gOUuG/nRNeZp7inbSA= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1782990925; c=relaxed/simple; bh=r5G14UaEwklT9BUKKNtgLnnuaW7UlJmKefKBFbpWgbI=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=PZGc/k/9RmLpV4NUZBK4UvFmn105Zic6x2MuJTn+/A4nXWAvxHKt4H0P71hj+PMnDrqQF3UxoeTosbVQiK3tz0DgK+osjIGHDdvt9Q2bfu1BpngCK35+hRNmLy459WodKzu/yJMOGBZxY0zlqRL11KJE3P9QXOcKXSZKHp/Shrk= ARC-Authentication-Results: i=1; sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4C7D84BA23EE Received: by mail-wm1-f50.google.com with SMTP id 5b1f17b1804b1-493c5220cb7so6994395e9.3 for ; Thu, 02 Jul 2026 04:15:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1782990924; x=1783595724; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=4waMCbNTX56XPlB6lUJefhxPYdf/zVUsoID3To32sJc=; b=n3NSXZI35mff5VcG1Hu872xYSk2Lad7x4BylfAtlvZOWLB4hthDhL6zX7xEFBWox5E KxNbduo0VDdj+lmZJL+4fvnrXd3dydcq+oyBR4ri0A0fE+eWGh/cmJglHQitRMuiv5BT 8w5DACM3dKDqZSgkSLnKeRsaKQGRgH6szuCAiHzBOzeqXlQ+putZZFkF1SxNicw/igZg AMW/AhOJmxWYHNy1xu6Wuf2i0BNNc587bxRBXp7oz37vfTWSIOqQdu0OWzGIV3/OVeg+ WpI32yJTApH8J6fnpZ19WHQ0DTocPeLOmwhx6un35hr3bdoHK1jy2YEPFStLuEStCjLv 9lgA== X-Gm-Message-State: AOJu0YyUdmZ4ENm1o2vEh1covpJGof3hpqiut0abaiJOiQXGZ9UXCksd UvsM82383mDI6XND4U9jKItfGJu/kZTCGhA+tBo1wkBO7/AgRBw8Ph0SQbG/1g== X-Gm-Gg: AfdE7cnc/9meLCgsbmhJvwmMofB8qW1XlWatkFvEjvz4rJqE2W2/zbmIIiZsScnZpCb T6FNzJnQNEFA43B0+7m3/WUHpm/MttaU8Pv8JS48SS6WzbAgObRuxfhYbFxIyUdqLjTu9WXzu60 OXmiiyoJnUbgbgsyiXo8IJ8JSYWFLyyBQCa6cQp4lbxXxhimIjRoNBpXiRZRdD6ZRRdbawMsRE3 Bp5fJ5QOA6ojYLkNf7zcpXrUzdcSzxaSTLxEezjaOGgi1IpIcHbzOXNPpsUa7GxDIwlyhnIxX+U 7/uJLvFLxnefDNOnknp1OXqShvC5HKaJCrLfBhoisq2IDFmZeo+mjiwmrMoQ0M6bmj9a4d9p5/g +V3gG03/veJk/8xAHBgjSPNQPS5Cf4AXEyF0TvCr6NHU4MXWzqOSyZ+GygQfIFRK1mnfB8HMz03 cSjhK2tGxRdolO/9FUlwAW X-Received: by 2002:a5d:634e:0:b0:475:f0f0:9ecc with SMTP id ffacd0b85a97d-477b5d37ae9mr4947110f8f.55.1782990923855; Thu, 02 Jul 2026 04:15:23 -0700 (PDT) Received: from localhost ([2001:8a0:fac2:7700:30ce:627:9424:b9bd]) by smtp.gmail.com with UTF8SMTPSA id ffacd0b85a97d-477dd94cec5sm7644958f8f.19.2026.07.02.04.15.23 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 02 Jul 2026 04:15:23 -0700 (PDT) From: Pedro Alves To: gdb-patches@sourceware.org Cc: Lancelot SIX Subject: [PATCH] Windows/rocm-solib: Don't hardcode namespaces support Date: Thu, 2 Jul 2026 12:15:21 +0100 Message-ID: <20260702111521.320404-1-pedro@palves.net> X-Mailer: git-send-email 2.54.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~public-inbox=simark.ca@sourceware.org rocm_solib_ops currently unconditionally returns true to solib_ops::supports_namespaces. That works OK on Linux where the underlying solib ops is svr4. But on Windows, the underlying solib ops is solib-target, which does not support namespaces. The result is: (gdb) info shared /home/pedro/rocm/gdb/build/gdb/solib.h:270: internal-error: num_active_namespaces: namespaces not supported A problem internal to GDB has been detected, further debugging may prove unreliable. ... Thread 1 hit Breakpoint 1, internal_verror (file=0x7ff71a27fc80 "/home/pedro/rocm/gdb/build/gdb/solib.h", line=270, fmt=0x7ff71a27fc5e "%s: namespaces not supported", ap=0xfff1a8 "\270\374'", ) at /home/pedro/rocm/gdb/build/gdb/utils.c:514 514 internal_vproblem (&internal_error_problem, file, line, fmt, ap); (gdb) bt #0 internal_verror (file=0x7ff71a27fc80 "/home/pedro/rocm/gdb/build/gdb/solib.h", line=270, fmt=0x7ff71a27fc5e "%s: namespaces not supported", ap=0xfff1a8 "\270\374'", ) at /home/pedro/rocm/gdb/build/gdb/utils.c:514 #1 0x00007ff719c75cf4 in internal_error_loc (file=0x7ff71a27fc80 "/home/pedro/rocm/gdb/build/gdb/solib.h", line=270, fmt=0x7ff71a27fc5e "%s: namespaces not supported") at /home/pedro/rocm/gdb/build/gdbsupport/errors.cc:57 #2 0x00007ff719f0aafe in solib_ops::num_active_namespaces (this=0xbb3a0b0) at /home/pedro/rocm/gdb/build/gdb/solib.h:270 #3 0x00007ff719eca99e in rocm_solib_ops::num_active_namespaces (this=0xc9388a0) at /home/pedro/rocm/gdb/build/gdb/solib-rocm.c:211 #4 0x00007ff719a14d33 in print_solib_list_table (solib_list=..., print_namespace=true) at /home/pedro/rocm/gdb/build/gdb/solib.c:1011 #5 0x00007ff719a15833 in info_sharedlibrary_command (pattern=0x0, from_tty=1) at /home/pedro/rocm/gdb/build/gdb/solib.c:1115 rocm_solib_ops will stop sitting on top of another solib implementation once the multi solib provider work lands, but meanwhile, it'd be helpful to not crash. Fix this by making rocm_solib_ops::supports_namespaces() delegate to the underlying host solib ops like other methods do. Change-Id: I1627c6e2f1b1c171c013c8457e9bfca92d5f4dc5 --- gdb/solib-rocm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gdb/solib-rocm.c b/gdb/solib-rocm.c index 3a58a46d886..73797801d6c 100644 --- a/gdb/solib-rocm.c +++ b/gdb/solib-rocm.c @@ -202,7 +202,7 @@ struct rocm_solib_ops : public solib_ops { return m_host_ops->find_solib_addr (so); } bool supports_namespaces () const override - { return true; } + { return m_host_ops->supports_namespaces (); } int find_solib_ns (const solib &so) const override { return m_host_ops->find_solib_ns (so); } base-commit: 18ca02157d9cc245f035452e397a07a3787034d0 -- 2.54.0