The version blocks ending with _PLATFORM and _PRIVATE are unstable ABIs.
To exclude them, header-abi-linker --exclude-symbol-version should
accept patterns like *_PLATFORM and *_PRIVATE.
Test: ANDROID_BUILD_TOP=`realpath .` \
PATH=$PATH:`realpath out/soong/dist/bin` \
development/vndk/tools/header-checker/tests/test.py
Test: LD_LIBRARY_PATH=out/soong/dist/lib64 \
out/soong/host/linux-x86/nativetest64/header-checker-unittests/header-checker-unittests
Bug: 298626434
Change-Id: Id82bc013b8de62b5ba8e5bd29f399b1b72ab5d39
build-prebuilts.sh compiles header-checker-unittests by default. The
continuous builds ensure that the tests are compilable. The developers
can use the script to build the tests locally.
Test: OUT_DIR=out BUILD_BROKEN_DISABLE_BAZEL=1 \
development/vndk/tools/header-checker/android/build-prebuilts.sh \
header-checker-unittests
Test: OUT_DIR=out BUILD_BROKEN_DISABLE_BAZEL=1 DIST_DIR=/tmp/distdir \
development/vndk/tools/header-checker/android/build-prebuilts.sh
Bug: 280008249
Change-Id: I32d6ade3c527785d68802c1737c94f963ead5b3c
"target" refers to a target arch, a build target, or a make target.
This commit renames the class and the variables to avoid ambiguity.
Test: development/vndk/tools/header-checker/utils/create_reference_dumps.py \
-products aosp_x86_64 -release trunk_staging
Bug: 297542516
Change-Id: Icfb06e18333d56af802c74494c1d158f367026c9
This commit adds -release as a parameter to create_reference_dumps.py.
It is currently optional. Developers can use it to try different
release configurations.
Test: development/vndk/tools/header-checker/utils/create_reference_dumps.py \
-products aosp_x86_64 -release trunk_staging
Bug: 297542516
Change-Id: Ifb7001ed42dbb9f8d0dd8e6c9738be6d5ea2feca
We turned this off for a bit because not all deps were mapped in to the
clang-tools build. Re-enabling now to produce a fresh prebuilt.
Bug: 251506715
Test: ABTD aosp-clang-tools
Change-Id: Ia843be55894946ff0803c43057e58899f99b580f
An arch variant directory may contain a soong host config subdirectory.
The ABI dump script extracts the last two directory names from an
intermediate lsdump path. It builds the lsdump if any of the directory
names matches the variant.
Test: ./create_reference_dumps.py -libs libmemtrack \
-products aosp_arm64
Bug: 291850413
Change-Id: I3dafc68b0dc7bb7faf708e3adfd24082a12a691b
Bindgen has been updated in platform, but additional repos need to be
mapped into this build to work properly. Since changing manifests
requires special permissions, this unbreaks the build until we can get
the manifest fixed to re-add bindgen.
Test: TH
Change-Id: Idd7bf289212a2570e267eaab0e94d332ed8a44b2
This commit fixes the bug that causes the ABI tools to produce invalid
output but return success.
Bug: 288168134
Test: development/vndk/tools/header-checker/tests/test.py
Change-Id: Ifa94667e9d38eff65e943a1d277dd2c7b5493fe5
- Add the commands to write Android.bp, create reference dumps, and
find the generated dumps.
- Remove "persistent-" from the repo command as it's internal only.
Test: None
Bug: 227282691
Change-Id: I07dc947c0436e2a0e7e5b3a4f812800bd7df2720
EnumFieldIR has member functions that determine whether the enum value
is signed. The JSON dumper uses the functions to distinguish between
negative values and values >= (1 << 63).
Bug: 277299761
Test: ./test.py
Change-Id: If5f3a33aaf5f53f39019fdd10dde366d48a50340
This commit restores lib/libc++.so.1 and lib/libclang-cpp.so.16 which
are indirect dependencies of clang tools.
Bug: 218706358
Test: out/soong/dist/bin/versioner -h
Change-Id: I3b9414645dc5b56d322d21e082feca260519d053
The status of the filtered out fields is either kNoDiff or
kIndirectDiff. It does not affect the diff report, but makes
ModuleMerger determine redefined types more accurately.
Test: ./test.py ; update the prebuilt clang tools and build
Bug: 255702405
Change-Id: Ia94225d25e00597affa8b1e01a7c9de592bf5b05
Before this commit, the function returns
(kDirectDiff, RecordFieldDiffIR *) or (kIndirectDiff/kNoDiff, nullptr).
The commit changes the return value to a DiffStatus. The caller decides
whether to create a RecordFieldDiffIR by the DiffStatus.
Test: ./test.py
Bug: 255702405
Change-Id: If2bfd5bca78e9d924be34ad5c522db9b91382cde
- Rewrite the diff algorithm to handle multiple fields located at the
same offset in a class, struct or union.
- Allow renaming a field if its (offset, type) pair is unique.
Bug: 255702405
Test: ./test.py
Change-Id: I79ebe9a827822b0f89d95952fa7d8c30499ca680
This commit implements the function that compares array size, alignment,
and element type.
Test: ./test.py ; update prebuilts/clang-tools and build
Bug: 255702405
Change-Id: I4f25d22f060cfda04bbd88b9c2521461b95e6829
Also remove -std=c++14 flag. Because clang 16 uses c++17
by default. And some headers don't compile with c++14.
Bug: 253033919
Test: run build-prebuilts.sh
Change-Id: Ia76c227831ed62a9de190fb1d816f23d7c92fad2
The ABI tools do not diff the array length. They cannot distinguish
between arrays of unknown bound (e.g., int foo[]) and arrays of zero
length (e.g., int bar[0]). To implement array diff, this commit adds
"is_of_unknown_bound" field to the ABI dumps. It defaults to false so
that it can be omitted for common cases.
Test: ./test.py ; update prebuilts/clang-tools and build
Bug: 255702405
Change-Id: I5db163eb62e95fa01377ef7202e70cc2a0e89524
If a type ID is persent in local_to_global_type_id_map,
ModuleMerger functions should report that was_newly_added_ = false.
Test: ./test.py ; update prebuilts/clang-tools and build
Bug: 255702405
Change-Id: I0fbe68ebbc6b8df3ea4ae36a017d0bb61bc7d553
This commit moves the functions that determine struct extensions from
ir_diff_representation.cpp to abi_diff_helpers.cpp. The functions
are called before IRDiffDumper so that the IR and the dumper do not
include the diff logic.
Test: ./test.py
Bug: 259148872
Change-Id: I93aaa3028bf6a30312f0b0e5b1ef5f6ae1041f21
`header-abi-diff --allow-extensions` allows function parameters to be
more qualified, and return types to be less qualified. The ABI tools
follows the qualifier conversion rules in C++.
The ABI tool only allows extending the qualifiers of the functions that
have corresponding symbols. The qualifiers of the other types, such as
function pointers, class members, and global variables, must be
identical between the old and new ABIs.
Test: ./test.py
Bug: 259148872
Change-Id: I227f6ed774cc88009713acce955e35f1c3cff1ca
DiffStatus is a class that exposes constants and member functions.
AbiDiffHelper calls the member functions to determine how to report the
diff. The actual value of a DiffStatus object is encapsulated so that
developers can define new status without changing existing logic.
Test: ./test.py
Bug: 259148872
Change-Id: I2c3be62046aa01d68c84690cb158f8fc7a5b474b