From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-oi1-x22d.google.com (mail-oi1-x22d.google.com [IPv6:2607:f8b0:4864:20::22d]) by sourceware.org (Postfix) with ESMTPS id DE39538582BE for ; Tue, 29 Nov 2022 02:52:43 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org DE39538582BE Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-oi1-x22d.google.com with SMTP id n186so13786642oih.7 for ; Mon, 28 Nov 2022 18:52:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:message-id:date:in-reply-to:subject:cc:to:from :user-agent:references:from:to:cc:subject:date:message-id:reply-to; bh=SJEMgh7eyYdRZuLTe1fivzMU+ESluqBZKjRBRosjAwI=; b=aPEhYjqgaYM8AXnw/+3Cdl2CKmiRKjifZ3jYRcthvPnSnfcdBC9ij26HrFihEyvBxJ lvaJO9a1sWfWNOnKbZ50v0a7EWBU5zs4wxRCeZ/roO1bitQsz/GcQizRonxgrjNVU2ak 9CyludbEOAFuf1hxs8I+BFVBy2d1S7DdObE97x1s7oAOmqL7hex2aNPbXGNuFzU/JQ8K /lIJICbqrSiSLNWBo8tMg2JtxL/HwwkfBZ9A3j2YBCragzC/lxRfXOa0VJe/KIFo1ba2 Xgzy2K9O2vMcW9fmouZQ6du5weZ8FRH7C+e/P0SF5BfJqhXxVDWRI3rbFbOOVwDAmnVJ 1OPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:message-id:date:in-reply-to:subject:cc:to:from :user-agent:references:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=SJEMgh7eyYdRZuLTe1fivzMU+ESluqBZKjRBRosjAwI=; b=xtruSyE3cVkyGIWIcAcpMcrV8kLdCUaAw9lF6wEo3HCLFWUorViIGrqijQJWcZ2xkF J4jAIMqwrXCARawdYpLbgSS3f4uUIsUIqLJEVJ7kIpJAGqP6VdSPISUiXujvYRp3QuPi RyoyWvlOFqTKXLm3bPTc26IIIi/6JSdkUEZPHwhrt6CEqSiR5bULpvVZqmiGy25TuKDK 4eD645/oNWz23hH9XvygXsXNX8B0IW1FejlCXW/KMIjJxCJxMTbNyTnk9UrmFHwpC/dQ S5zo1ngA61GL9JJ6PAc4hePSLrRwEqIJOTgLDd4+hrPfBnaBvHtJJwD62CQ1ehJqX3KL C6Xg== X-Gm-Message-State: ANoB5pk4z9pIkWrCXmh/rvgcWjJs6aU+XVRtFwuXemB95lWmz0ao5rxx neb2g6vXAr7W+ytYhJ4JE31vHg== X-Google-Smtp-Source: AA0mqf5R8XSGnjxW0qMkLlKd7x5Daq+esjXvB+MJ0fGmgrJbK6cIgAom4CzJSy4rAdPGmKJ/yIa2EA== X-Received: by 2002:a05:6808:2286:b0:35b:b709:6049 with SMTP id bo6-20020a056808228600b0035bb7096049mr3155169oib.139.1669690363249; Mon, 28 Nov 2022 18:52:43 -0800 (PST) Received: from localhost ([2804:14d:7e39:8470:201c:ea26:41ce:5eb]) by smtp.gmail.com with ESMTPSA id r15-20020a4a964f000000b0049bd96ec131sm5041315ooi.8.2022.11.28.18.52.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 28 Nov 2022 18:52:42 -0800 (PST) References: <20221126020452.1686509-1-thiago.bauermann@linaro.org> <20221126020452.1686509-2-thiago.bauermann@linaro.org> <0250c717-43a4-304b-5926-5b85c225c352@simark.ca> User-agent: mu4e 1.8.11; emacs 28.2 From: Thiago Jung Bauermann To: Simon Marchi Cc: gdb-patches@sourceware.org, Luis Machado Subject: Re: [PATCH v2 1/6] gdbserver: Add asserts in register_size and register_data functions In-reply-to: <0250c717-43a4-304b-5926-5b85c225c352@simark.ca> Date: Tue, 29 Nov 2022 02:52:39 +0000 Message-ID: <87bkoqiia0.fsf@linaro.org> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-5.2 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.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Simon Marchi writes: > On 11/28/22 09:48, Simon Marchi wrote: >> >> Approved-By: Simon Marchi > > Actually, I would perhaps suggest moving the assertion checks to > find_register_by_number, the place that actually accesses reg_defs. Good idea. I'll do that in v3. > And we could perhaps remove the equivalent gdb_assert in > regcache_raw_read_unsigned, since it's checking the same a few frames > above. Good point. Will do. -- Thiago