Message ID | 20211203114622.2944173-1-maennich@google.com |
---|---|
Headers |
Return-Path: <libabigail-bounces+patchwork=sourceware.org@sourceware.org> X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id CC01F3858017 for <patchwork@sourceware.org>; Fri, 3 Dec 2021 12:09:09 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org CC01F3858017 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1638533349; bh=PQFWWksIH30VwCaTbICTJHAJ/L9zwA9rI329m9ca9nc=; h=Date:Subject:To:List-Id:List-Unsubscribe:List-Archive:List-Help: List-Subscribe:From:Reply-To:Cc:From; b=Dld7SkZBU+z+QUB8o5uEZJ4mol9+XZaiKBK6Vof5Uk6AvGOLTwKaUfhWuh0LbXPG4 2hfDGGY6nu6+50ReBSVckMn1ZcXF8jTOWLzpVrrUOPDbZ64NDVE3/jkVPcA7qhL8m7 cz9CGFm1ouIFhLBXClYLE8VLMVUWZXRv1Ia6tSMg= X-Original-To: libabigail@sourceware.org Delivered-To: libabigail@sourceware.org Received: from mail-ed1-x54a.google.com (mail-ed1-x54a.google.com [IPv6:2a00:1450:4864:20::54a]) by sourceware.org (Postfix) with ESMTPS id 87ED13858D39 for <libabigail@sourceware.org>; Fri, 3 Dec 2021 12:09:05 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 87ED13858D39 Received: by mail-ed1-x54a.google.com with SMTP id s12-20020a50ab0c000000b003efdf5a226fso2376937edc.10 for <libabigail@sourceware.org>; Fri, 03 Dec 2021 04:09:05 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:message-id:mime-version:subject:from:to:cc; bh=PQFWWksIH30VwCaTbICTJHAJ/L9zwA9rI329m9ca9nc=; b=J3SZy3Knr7A/2vFslL98J9d4BsIMu5oOsNNQU/Jn5Ma6XxNUihieY3bMQb/ZnX27fB W4vHqr375eivaNPMnX31+KWmb7+Pr1+Jo3gcLnqF5zzft8C9meHQp9fybvOSFY5Qt+kn L4ES+OBk/Xd1WVtiS17Agb4RLVasaffOWkwpwFeiz0BI0KdYjSudJ3Z2Ox8GnmBZS+3M D88YgkAMeZpBFns86PRTp8M6nzUhGUqD4V+rVnaYNWrFI39ckvMhd22xfhtgffw/2Id6 bCDdkAu24tSJphIikbek9UJXb3gcHJe65fBVPM9HSSi3fzTFX+LK7BtGiknj3BqaK3RJ nLHQ== X-Gm-Message-State: AOAM532iePXLDHt6SwyEg9scuj8Zi9gHL/fJ76NhaqskOIzq2Y7hwJHg mVZQm9q/2tylsVweGGa1cVNXw0QrIVQ4KKLm3GU3iV4pHZLOVvGSHwJ6P25s9QWMjptenyzdxmA 5t1DttANP4ND9EKj7FMc8aC9Om8xRn3SZJz/uxOltG9263LwXKLEM3NAHYoPjIk9LHCJIDo4= X-Google-Smtp-Source: ABdhPJyw/4ZmnaJ+EQ86+HTKiA82v7afqZCddj5vOxWTF8Qa8VzybLBUiroog2zNPZqOOoK3pGHIwUHC2OsC+Q== X-Received: from lux.lon.corp.google.com ([2a00:79e0:d:210:47e9:78df:690b:201]) (user=maennich job=sendgmr) by 2002:a17:906:e115:: with SMTP id gj21mr23406795ejb.348.1638533344429; Fri, 03 Dec 2021 04:09:04 -0800 (PST) Date: Fri, 3 Dec 2021 11:46:18 +0000 Message-Id: <20211203114622.2944173-1-maennich@google.com> Mime-Version: 1.0 X-Mailer: git-send-email 2.34.1.400.ga245620fadb-goog Subject: [PATCH 0/5] Improvements for the XML Writer To: libabigail@sourceware.org Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-15.4 required=5.0 tests=BAYES_00, DKIMWL_WL_MED, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, USER_IN_DEF_DKIM_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 <libabigail.sourceware.org> List-Unsubscribe: <https://sourceware.org/mailman/options/libabigail>, <mailto:libabigail-request@sourceware.org?subject=unsubscribe> List-Archive: <https://sourceware.org/pipermail/libabigail/> List-Help: <mailto:libabigail-request@sourceware.org?subject=help> List-Subscribe: <https://sourceware.org/mailman/listinfo/libabigail>, <mailto:libabigail-request@sourceware.org?subject=subscribe> From: Matthias Maennich via Libabigail <libabigail@sourceware.org> Reply-To: Matthias Maennich <maennich@google.com> Cc: maennich@google.com, kernel-team@android.com Errors-To: libabigail-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libabigail" <libabigail-bounces+patchwork=sourceware.org@sourceware.org> |
Series |
Improvements for the XML Writer
|
|
Message
Matthias Männich
Dec. 3, 2021, 11:46 a.m. UTC
We gave the issues we currently see with some larger (Android) userspace libraries another try. Initially that was bug 28320 (infinite loops in the XML writer). More recently, another Google team expressed an interest in ABI monitoring and using libabigail for this purpose. A significant issue they encountered was that large ABIs took a very long time to be extracted by abidw. It turns out that a lot of abidw time is spent on writing out the XML. We have been unable to merge upstream libabigail due to this affecting userspace library monitoring. Both issues involved deep type equality tests done by the XML writer. This series switches the XML writer to use bare type pointers in all its containers. Fixes: Bug 28320 - abidw - (non-deterministic) infinite loop in XML writer Improves: Bug 26591 - detect pathologically redundant types in abixml Performance improvements, all measurements are in CPU user seconds: - abidw for both test suite and typical kernel inputs is about 2% faster with this change - An AOSP framework library test case is sped up by >3 times, from 120 to 37.5 - An internal Google library test case is sped up >20 times, from 3290 to 160 Impact on test cases: - tests/data/test-read-dwarf/PR22122-libftdc.so.abi is the only significantly-impacted test case. abidiff reports no change, but abidiff --harmless shows some things going on with empty, anonymous struct definitions. These empty structs are due to missing DW_AT_signature support / are correlated with DW_AT_signature attributes. The object file was compiled with Clang. Some more details have recently been discussed in bug 26591. - All the other test object files are reported as having the same ABI by abidiff --harmless. - Our own test suite of small changes also has no differences found by abidiff --harmless. - One test kernel tree has an issue with one anonymous enum type being resolved incorrectly (having previously had conflicting duplicate definitions). The enumerators all have the same values so there is no ABI risk here. This deserves further investigation but should probably not hold up the series. - Spot checks with userspace libraries show no differences found by abidiff --harmless either. Matthias Maennich (5): XML writer: use consistent type pointers for type ids and emission tracking XML writer: use exemplar types for tracking referenced types XML writer: track emitted types by bare pointer XML writer: map type ids by bare pointer XML writer: resolve declaration-only enum definitions src/abg-writer.cc | 80 +- .../data/test-annotate/test14-pr18893.so.abi | 2 - .../data/test-annotate/test15-pr18892.so.abi | 44 +- ...19-pr19023-libtcmalloc_and_profiler.so.abi | 4 - .../data/test-annotate/test21-pr19092.so.abi | 26 +- .../test-read-dwarf/PR22122-libftdc.so.abi | 6242 ++++++++--------- .../data/test-read-dwarf/PR25007-sdhci.ko.abi | 514 +- .../PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi | 2 +- .../test-read-dwarf/test14-pr18893.so.abi | 1 - .../test-read-dwarf/test15-pr18892.so.abi | 28 +- .../test-read-dwarf/test16-pr18904.so.abi | 2 - ...19-pr19023-libtcmalloc_and_profiler.so.abi | 2 - .../test-read-dwarf/test21-pr19092.so.abi | 16 +- .../test22-pr19097-libstdc++.so.6.0.17.so.abi | 1 - 14 files changed, 3472 insertions(+), 3492 deletions(-)