libgccjit provides a very neat interface to leverage GCC for optimizations and codegen (both just in time, as well as ahead of time). It would be nice to see this supported by Funtoo's sys-devel/gcc ebuilds. Attached is a patch against core-kit/1.0-prime sys-devel/gcc-7.2.0 that I have tested on a pure64 arch without any issues so far (but it would likely need testing on a multilib system; note that while this patch is loosely based on Gentoo's toolchain eclass, I needed to add the `--with-pic` in order for internal mpc to compile and also move the resulting shared library + symlinks into the gcc-specific subdirectoty for libraries to avoid clashes between GCC versions).
Because of the slowdown warning I intend to try out the building twice method that is mentioned there and provide another patch should it prove feasible.
- relates to
-
FL-5149 TRACKER: GCC (Toolchain)
- Closed