Skip to content

Conversation

@Niram7777
Copy link
Contributor

Fix build error, the Triple constructor is not implicit anymore.

llvm/llvm-project@fff720d#diff-5008de5706b85963c456532be4d2e8c5b478959be9d315f77c338946bd1fc586R353-R354

[marin@pc-linux ~]$ clang++ --version
clang version 22.0.0git (https://github.com/llvm/llvm-project.git 1669bd3ae9af0cac4414479d8f1e53e329fa3efb)

@Niram7777
Copy link
Contributor Author

The Triple constructors only exist in llvm/llvm-project@fff720d#diff-5008de5706b85963c456532be4d2e8c5b478959be9d315f77c338946bd1fc586R353-R354
We can reopen the PR once we upgrade LLVM

@Niram7777 Niram7777 closed this Aug 3, 2025
@AniLeo
Copy link
Member

AniLeo commented Aug 3, 2025

You can also leave it up as draft

@Niram7777 Niram7777 reopened this Aug 6, 2025
@Niram7777 Niram7777 marked this pull request as draft August 6, 2025 09:47
@qurious-pixel
Copy link
Contributor

Is it possible to use ifdefs in the style of minimum version to build LLVM 19 and LLVM 21?

	auto null_mod = std::make_unique<llvm::Module>("null_", *m_context);
#if LLVM_VERSION_MAJOR > 20
	null_mod->setTargetTriple(llvm::Triple(jit_compiler::triple1()));
#else
	null_mod->setTargetTriple(jit_compiler::triple1());
#endif

This fixes the compilation error for LLVM triple on Windows Msys2 clang64 when wrapping all the explicit Triples.

@elad335
Copy link
Contributor

elad335 commented Oct 4, 2025

Is it possible to use ifdefs in the style of minimum version to build LLVM 19 and LLVM 21?

	auto null_mod = std::make_unique<llvm::Module>("null_", *m_context);
#if LLVM_VERSION_MAJOR > 20
	null_mod->setTargetTriple(llvm::Triple(jit_compiler::triple1()));
#else
	null_mod->setTargetTriple(jit_compiler::triple1());
#endif

This fixes the compilation error for LLVM triple on Windows Msys2 clang64 when wrapping all the explicit Triples.

@qurious-pixel yes

@AniLeo
Copy link
Member

AniLeo commented Oct 15, 2025

@Niram7777 if you can add the ifdefs, we can merge this

@Niram7777 Niram7777 force-pushed the build-llvm-triple-explicit-21-1-0 branch from 3ad7fdc to 08065ce Compare October 15, 2025 17:40
@Niram7777 Niram7777 force-pushed the build-llvm-triple-explicit-21-1-0 branch from 08065ce to 6b15626 Compare October 15, 2025 17:43
@Niram7777 Niram7777 marked this pull request as ready for review October 15, 2025 17:44
@Megamouse Megamouse added the Build and CI Anything related to the build process and continuous integration label Oct 15, 2025
@Niram7777
Copy link
Contributor Author

@Niram7777 if you can add the ifdefs, we can merge this

I just found there was #16807 but I have updated my PR in case you want to handle all LLVM versions and a quick fix

@qurious-pixel
Copy link
Contributor

With this commit and #17552, Clang should build again.

@Megamouse Megamouse merged commit 41a122a into RPCS3:master Oct 15, 2025
8 of 9 checks passed
@Niram7777 Niram7777 deleted the build-llvm-triple-explicit-21-1-0 branch October 15, 2025 18:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Build and CI Anything related to the build process and continuous integration

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants