From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr1-x42a.google.com (mail-wr1-x42a.google.com [IPv6:2a00:1450:4864:20::42a]) by sourceware.org (Postfix) with ESMTPS id 9D0153857C6F for ; Wed, 31 Mar 2021 20:07:56 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 9D0153857C6F Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=embecosm.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=andrew.burgess@embecosm.com Received: by mail-wr1-x42a.google.com with SMTP id b9so20844543wrt.8 for ; Wed, 31 Mar 2021 13:07:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=embecosm.com; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=z5vWCT2Im+8UeOrrLHD8OtzhCFhg2/eYR89u1Uo88uQ=; b=SYYDXu6TZQXRicYgT/W4hiqSkuR8PGmzs3UvxbrJgs7kglf1Vnd9mDS3H21ABEgijZ HmlfArS9o5xQUgPYE+D4hPq3jYfLdnrClmzq8EFst8efJ99zkVViHKajB7SWELquCHCW h/86XkZKUDJOYJwWsA7UQoepxIjrCz+fGzgEyCXFmPP13Rf/Do9Vh9XxMOkp751HcKyz PE6Hyf58wWI4G5XwHIt0s3IxtFZ0UVXE7iZqyF6QeW7UsmyzGK6X9kop5LvfzUL7ClFl 3y7TXcOtKSiHkBmCAbSvOXBVnSuRmmI5TAQtEl7+RQ5g2Ke7MjJO0BA4Grs+kq96R2GG SOkg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=z5vWCT2Im+8UeOrrLHD8OtzhCFhg2/eYR89u1Uo88uQ=; b=fRCLzO1TNMq3b5RKeG3dYqbvLsY5xO85OzBI7jmE/MbIkhVbc7ftDM766jktNoZXbq GfdGeC3eBkaXFjtl1+056J3UhOLrVyFZrdSBcoVz4qT+/vI9SLxtLnwTU8lx3vPwtzYW xrbTod0MmN6wm63jrTiLsQvHTrkY3DgHiHUDe2PDohRaZz932do6/86z8FI7tE7dFO1I oQvjVDwyLJnumb4p33Lon+FWrSrFF3GB1XQq9NdeRLLex0xe/DcsUvDXAaxuvE13AxiM 6ocDHhncg/IEYonexTnsfRqgItVjUViyzJCQQB+XqcUAoqz2XCVlDfAJsUtmnFXgjRKk bRuw== X-Gm-Message-State: AOAM5312I7lTRQZ0KSsrY7RHZC5+B3weg1nYnJhCAE+DjJ2TGa2w6+SP TKFAuyQ/Lox2U35ang1vAFXGwychppMJHQ== X-Google-Smtp-Source: ABdhPJwEfQZviFB38u9OjjUNAyQ7UXfwh17gf5S/T2Yc/mZHl6YL3pjsh/lLOXUW/cZha8gEMbk2NA== X-Received: by 2002:a5d:4f0e:: with SMTP id c14mr5750917wru.286.1617221275781; Wed, 31 Mar 2021 13:07:55 -0700 (PDT) Received: from localhost (host109-151-46-70.range109-151.btcentralplus.com. [109.151.46.70]) by smtp.gmail.com with ESMTPSA id u9sm5009253wmc.38.2021.03.31.13.07.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 31 Mar 2021 13:07:55 -0700 (PDT) Date: Wed, 31 Mar 2021 21:07:54 +0100 From: Andrew Burgess To: Tom Tromey Cc: gdb-patches@sourceware.org Subject: Re: [PATCH] Add some error checking to DWARF assembler Message-ID: <20210331200754.GB5391@embecosm.com> References: <20210318155826.3703918-1-tromey@adacore.com> <20210318171555.GF5520@embecosm.com> <87r1kcxqx6.fsf@tromey.com> <87im5oxixi.fsf@tromey.com> <874kgrtkg0.fsf@tromey.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <874kgrtkg0.fsf@tromey.com> X-Operating-System: Linux/5.8.18-100.fc31.x86_64 (x86_64) X-Uptime: 21:07:32 up 1 day, 5:35, X-Editor: GNU Emacs [ http://www.gnu.org/software/emacs ] X-Spam-Status: No, score=-5.5 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) 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: Wed, 31 Mar 2021 20:07:58 -0000 * Tom Tromey [2021-03-31 09:24:47 -0600]: > Andrew> Maybe I'm over thinking this, but you could change this to: > Tom> Here's the definitive (IMNSHO) over-thinking approach. It works by > Tom> having the helper proc set the necessary variables for the caller. > > Tom> One problem I thought of with that approach is that if you typo the code > Tom> in one case, you could pick up a local variable set from some previous > Tom> case. > > Tom> Switching this to use an array that's cleared after every opcode avoids > Tom> this problem. > > I'm checking this in now. Sorry, I missed your updates. The new patch looks great. Thanks, Andrew