Swift 6.0.1 for Gentoo on GURU

@Erik_Eckstein, it looks like you added the SIL verification that's failing in the repl here back in SwiftCompilerSources: refactor and verify conformances to ForwardingInstruction by eeckstein · Pull Request #71723 · swiftlang/swift · GitHub, so I figure you might be someone to check in with: any idea why SIL verification could fail this way, and only in the Swift repl? (Any expression executed in the repl dies with the same error: <instruction> should conform to ForwardingInstruction, whereas the same exact code builds fine outside of the repl)

I'm fairly unfamiliar with the SIL layer, so any pointers on how I could approach tracking down the cause would be super helpful!


For reference, we're building Swift 6.0.1 from source here (with an available Swift 5.10.1 compiler), and it appears that something about the compilation environment itself leads to the failure here: pulling in a prebuilt Swift 6.0.1 compiler (built for Fedora 39) works just fine on the same machine. (So it's at least not purely a runtime issue.)

In case it helps, here's the build preset I'm using for compilation:

[preset: gentoo]
mixin-preset=buildbot_linux,no_assertions,no_test
build-ninja=0
extra-cmake-options=
       -DLLVM_USE_LINKER=lld
       -DBUILD_TESTING:BOOL=NO
       -DSWIFT_INCLUDE_TESTS:BOOL=NO
       -DSWIFT_INCLUDE_TEST_BINARIES:BOOL=NO
       -DCOMPILER_RT_BUILD_ORC:BOOL=NO
       -DPython3_FIND_UNVERSIONED_NAMES=FIRST
libicu=0
llvm-targets-to-build=host
skip-build-curl
skip-build-zlib

Happy to offer any additional details that might help!