From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ua1-x92e.google.com (mail-ua1-x92e.google.com [IPv6:2607:f8b0:4864:20::92e]) by sourceware.org (Postfix) with ESMTPS id 5E2FF3858D39 for ; Tue, 18 Jan 2022 09:58:26 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 5E2FF3858D39 Received: by mail-ua1-x92e.google.com with SMTP id i10so13483572uab.8 for ; Tue, 18 Jan 2022 01:58:26 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=0U0sFnQ3sZjqSxiN9YNiGP/46W9GbFxz3l8ir8Zf0T4=; b=2A1pkc+vCp23eDQ7Rbb/2WYZAAOgQRQQIky1Qbp4tyYuIYZoSywIRa2zgXFSdm0W9x KY2tDgoA9ph1ORsCcTT12JWKrIuZAPtbTMUg9tV+TF4ljlLNl/F0uFoRMHGRqWVNbOtA u8KouNTD/FO4uI98HGhSFfZIDuMFIUzcH0EtRfo6sJ4sG2kcUHjzPoDRGMIw2szDJIu0 AR93j37zCEeZw93/1YBuox4lKZQFHu4M1lGAZp+SgPLjzqM9KjqI7scA4b0mYi66k2KL T0uWRZohRlkRe8TQnBhPXD/ae5SwUbMqJoAOrwWHpQb97mqm2rtChDKFbHy2GtMpe+9z Omqg== X-Gm-Message-State: AOAM530KA88syhUp4YN66jBx+B/Pt9Tv9JZfDrqGsEj6Jp01kmZLAeLs nFNpc5ibIfWzetTeti+mtedRxmdW75jJJLaO0dSLPA== X-Google-Smtp-Source: ABdhPJwBTsbISIJyejDAgz0e3xHcn6kwtNUtuyMAIzR7UqKynlOpAsY0oYaIlHtk3oaQOsCuwyLd6d4OHeY841cgBCo= X-Received: by 2002:a67:df0c:: with SMTP id s12mr8658364vsk.10.1642499905762; Tue, 18 Jan 2022 01:58:25 -0800 (PST) MIME-Version: 1.0 References: <20220117145115.659444-1-gprocida@google.com> In-Reply-To: From: Giuliano Procida Date: Tue, 18 Jan 2022 09:57:49 +0000 Message-ID: Subject: Re: [PATCH] DWARF reader: use size_t for DWARF expression length To: Mark Wielaard Cc: libabigail@sourceware.org, dodji@seketeli.org, kernel-team@android.com, maennich@google.com Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-21.9 required=5.0 tests=BAYES_00, DKIMWL_WL_MED, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, ENV_AND_HDR_SPF_MATCH, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, USER_IN_DEF_DKIM_WL, USER_IN_DEF_SPF_WL autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: libabigail@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Mailing list of the Libabigail project List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Jan 2022 09:58:27 -0000 The latest merged commit doesn't have the extra fixes you mentioned. I'm happy to replicate your work, but I risk leaving something out again. Let me know, Giuliano. On Tue, 18 Jan 2022 at 09:52, Mark Wielaard wrote: > > Hi Giuliano, > > On Mon, Jan 17, 2022 at 02:51:15PM +0000, Giuliano Procida wrote: > > A recent change broke 32-bit builds due to an implicit assumption that > > size_t == uint64_t. This appears in the elfutils dwarf_getlocation* > > functions' types. > > > > This commit updates callers and other functions to use size_t > > consistently for such expression lengths and indexes. > > > > * src/abg-dwarf-reader.cc (die_location_expr): Change expr_len > > argument type to size_t*. > > (op_manipulates_stack): Change expr_len and index argument > > types to size_t; change next_index argument type to size_t&. > > (eval_last_constant_dwarf_sub_expr): Change expr_len argument > > and local variables index and next_index types to size_t. > > (die_member_offset): Change local variable expr_len type to > > size_t. > > (die_location_address): Likewise. > > (die_virtual_function_index): Likewise. > > I also needed to change the len and index arguments of > eval_last_constant_dwarf_sub_expr, op_pushes_constant_value, > op_pushes_non_constant_value, op_is_arith_logic and > op_is_control_flow. > > See attached. > > Cheers, > > Mark