OSDev.org
https://forum.osdev.org/

Why so many custom-build toolchains?
https://forum.osdev.org/viewtopic.php?f=13&t=33060
Page 2 of 2

Author:  simeonz [ Wed Jul 11, 2018 6:49 am ]
Post subject:  Re: Why so many custom-build toolchains?

Velko wrote:
What about LLVM? The Wiki page is not very generous, but the impression is that there is no need to build one for each target.

I imagine, that some effort is needed in order to obtain OS Specific Toolchain for userspace, but for pure kernel work - isn't pre-built, pre-packaged versions enough?
I accidentally found this page in the wiki. But I doubt that it will work anymore, because llvm has switched to the cmake build system.

Aside from that - llvm will be able to generate code for multiple architectures, and may have some things working as they should be - such as the built-in macros, but the libgcc/compiler-rt problem is still there if you use the stock library. I will speculate here, but assuming that you don't use the stock library (and you don't trigger compilation of code that uses it implicitly), and assuming that you configure the search paths and ABI appropriately (red-zone, sse, etc), there is no reason why the build wont work. Then again, aside from the code generation and the predefined macros, there wont be a lot of shortcuts with llvm.

Page 2 of 2 All times are UTC - 6 hours
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/