On 11/9/26 8:45 AM, Shiva S wrote:
When the host compiler is not GCC (GCC_VERSION < 3004), hwint.h declares
floor_log2, exact_log2 and related functions out of line instead of
defining them inline.  Generators that use vec.o and objects in
libcommon then fail to link because hwint.o is only part of OBJS.

gcc/ChangeLog:

        * hwint.cc: Include bconfig.h for generator files.
        * Makefile.in (BUILD_RTL): Add build/hwint.o.
        (OBJS): Move hwint.o from here...
        (OBJS-libcommon): ...to here.
        (build/hwint.o): New rule.
        (build/gencfn-macros, build/genmatch): Depend on build/hwint.o.

Signed-off-by: Shiva <[email protected]>
---

Bootstrapped and regression-tested on x86_64-pc-linux-gnu and
aarch64-unknown-linux-gnu.  I do not have write access; please commit
if approved.
Note this can be triggered with GCC by hacking those conditions such that GCC_VERSION < 3004 is unconditionally false, then trying a bootstrap with GCC.   I did that just to make sure things were sensible.  Other than a type mismatch in one of the loops everything was happy.  It's also Sashiko clean.  I've pushed your patch to the trunk.

Thanks,
jeff


Reply via email to