Conversation
Merging this PR will not alter performance
Comparing Footnotes
|
b55afbd to
5a64947
Compare
Capstone is compiled for the primary platform only, and cycledecode.c does not build without it. On a bi-arch host with 32-bit multilib, a plain ./configure also enabled the secondary x86 Callgrind, which then failed in make with a missing capstone/capstone.h and the CLG_WITH_CAPSTONE #error. Default to --enable-only64bit unless --enable-only64bit or --enable-only32bit was given either way, and fail at configure time with a clear message if a secondary platform is still requested. Closes COD-3590 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
5a64947 to
faab01a
Compare
|
With ./configure -C, a config.cache from an earlier bi-arch run still holds vg_cv_only64bit=no. AC_CACHE_CHECK then skips the AC_ARG_ENABLE handler, so setting enable_only64bit=yes had no effect: the secondary platform stayed selected and the Capstone check aborted configure. Set vg_cv_only64bit=yes directly instead. A cached 32-bit only choice is kept, as it has no secondary platform either and forcing 64-bit on top of it would trip the "both --enable-only64bit and --enable-only32bit" error. Refs COD-3590 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Default to a 64-bit only build, and fail at configure time if a secondary platform is still requested.
On a multilib host (Arch with
lib32-glibc, Ubuntu withgcc-multilib), a plain./configurealso enables the x86 secondary platform. Capstone is only compiled for the primary platform, andcallgrind/Makefile.ampasses the Capstone flags only to the primary targets, socallgrind_x86_linuxfailed inmakeon the#errorincycledecode.c:350. CI and the Debian packaging never hit this: they pass--enable-only64bit, and the Ubuntu runners have no 32-bit toolchain.CODSPEED_ONLY64BIT_DEFAULTsets--enable-only64bitunless--enable-only64bitor--enable-only32bitwas given either way.CODSPEED_CAPSTONEnow errors out when a secondary platform remains (e.g.--disable-only64bit), instead of failing later inmake.Alternatives considered:
-m32Capstone and wiring it into the secondary targets: nothing runs a 32-bit Callgrind with cycle estimation, so it isn't worth the extra build.cycledecode.cwhen Capstone is absent: this would silently ship a Callgrind whose--cycle-estimationdoes nothing.Verified on a multilib Manjaro host: plain
./configuregives amd64 only andmakesucceeds;--disable-only64bitstops at configure with the new message;--enable-only32bitconfigures an x86-only build.Closes COD-3590