From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from re-prd-fep-041.btinternet.com (mailomta32-re.btinternet.com [213.120.69.125]) by sourceware.org (Postfix) with ESMTPS id C33F3385829A for ; Sun, 12 Jun 2022 16:28:46 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org C33F3385829A Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=dronecode.org.uk Authentication-Results: sourceware.org; spf=none smtp.mailfrom=dronecode.org.uk Received: from re-prd-rgout-003.btmx-prd.synchronoss.net ([10.2.54.6]) by re-prd-fep-041.btinternet.com with ESMTP id <20220612162845.OKCI3283.re-prd-fep-041.btinternet.com@re-prd-rgout-003.btmx-prd.synchronoss.net>; Sun, 12 Jun 2022 17:28:45 +0100 Authentication-Results: btinternet.com; auth=pass (PLAIN) smtp.auth=jonturney@btinternet.com; bimi=skipped X-SNCR-Rigid: 61A69BAC1CC1E887 X-Originating-IP: [86.139.167.41] X-OWM-Source-IP: 86.139.167.41 (GB) X-OWM-Env-Sender: jonturney@btinternet.com X-VadeSecure-score: verdict=clean score=0/300, class=clean X-RazorGate-Vade: gggruggvucftvghtrhhoucdtuddrgedvfedrudduhedgleekucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuueftkffvkffujffvgffngfevqffopdfqfgfvnecuuegrihhlohhuthemuceftddunecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpefkffggfgfuvfhfhfgjtgfgsehtjeertddtfeejnecuhfhrohhmpeflohhnucfvuhhrnhgvhicuoehjohhnrdhtuhhrnhgvhiesughrohhnvggtohguvgdrohhrghdruhhkqeenucggtffrrghtthgvrhhnpeffkeeigfdujeehteduiefgjeeltdelgeelteekudetfedtffefhfeufefgueettdenucfkphepkeeirddufeelrdduieejrdegudenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhephhgvlhhopegludelvddrudeikedruddruddthegnpdhinhgvthepkeeirddufeelrdduieejrdeguddpmhgrihhlfhhrohhmpehjohhnrdhtuhhrnhgvhiesughrohhnvggtohguvgdrohhrghdruhhkpdhnsggprhgtphhtthhopedvpdhrtghpthhtohepghgusgdqphgrthgthhgvshesshhouhhrtggvfigrrhgvrdhorhhgpdhrtghpthhtohepthhrohhmvgihsegruggrtghorhgvrdgtohhm X-RazorGate-Vade-Verdict: clean 0 X-RazorGate-Vade-Classification: clean Received: from [192.168.1.105] (86.139.167.41) by re-prd-rgout-003.btmx-prd.synchronoss.net (5.8.716.04) (authenticated as jonturney@btinternet.com) id 61A69BAC1CC1E887; Sun, 12 Jun 2022 17:28:45 +0100 Message-ID: <491947bf-73ab-d9db-47cd-e66f5ecc2e3e@dronecode.org.uk> Date: Sun, 12 Jun 2022 17:28:43 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Subject: Re: [PATCH 2/2] Use subclasses of windows_process_info Content-Language: en-GB To: Tom Tromey , gdb-patches@sourceware.org References: <20220407195606.1847158-1-tromey@adacore.com> <20220407195606.1847158-3-tromey@adacore.com> From: Jon Turney In-Reply-To: <20220407195606.1847158-3-tromey@adacore.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1193.2 required=5.0 tests=BAYES_00, FORGED_SPF_HELO, KAM_DMARC_STATUS, KAM_LAZY_DOMAIN_SECURITY, NICE_REPLY_A, RCVD_IN_DNSWL_NONE, SPF_HELO_PASS, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Jun 2022 16:28:48 -0000 On 07/04/2022 20:56, Tom Tromey via Gdb-patches wrote: > This changes windows_process_info to use virtual methods for its > callbacks, and then changes the two clients of this code to subclass > this class to implement the methods. > > I considered using CRTP here, but that would require making the new > structures visible to the compilation of of nat/windows-nat.c. This > seemed like a bit of a pain, so I didn't do it. > > This change then lets us change all the per-inferior globals to be > members of the new subclass. Note that there can still only be a > single inferior -- currently there's a single global of the new type. > This is just another step toward possibly implementing multi-inferior > for Windows. > > It's possible this could be cleaned up further... ideally I'd like to > move more of the data into the base class. However, because gdb > supports Cygwin and gdbserver dose not, and because I don't have a way > to build or test Cygwin, larger refactorings are difficult. Understandably, without that capability, this change breaks building on Cygwin. I've sent a patch to fix that. If you explain what the difficulties are with building for and testing on Cygwin are, I may be able help you.