Earlier quoted context omitted.
> it sends preprocessed files just to not depend on remote env. to then be compiled by the host compiler ..
Sure, one compiler can't be egcs 2.95 and the other clang 8 (at least not in most cases) but the target compiler system doesn't even have to have include files, libs, libfoo-devel packages installed or they can be, but from old versions. As a proof of concept I once had a linux with gcc4.2.1 make c->.o files that later ran on OpenBSD. Would I trust that resulting binary? Sure not. But in cases of "lets spin up 10 com…
Parallel GCC: a research project aiming to parallelize a real-world compiler
71–73 of 73 posts
Re: Parallel GCC: a research project aiming to parallelize a real-world compiler
#72OT but why isn't there a compiler that simply does absolutely basic passes to get the IR into a 'normalized' form then apply optimizations based on a 'database' of super optimized 'chunks'? For unoptimized parts run the super optimizer.
So basically a code lowering engine that works a bit like https://en.wikipedia.org/wiki/Hashlife . Interesting! (NB. Googling "lowering" turned up the seemingly-random https://news.ycombinator.com/item?id=14422944 ; that page isn't such a bad set of starting links, so I figured I'd include it.)
Re: Parallel GCC: a research project aiming to parallelize a real-world compiler
#73Earlier quoted context omitted.
In LLVM, even with LLVM_ENABLE_THREADS, the compilation of a module is still sequential as far as I know. The LLVM Context is the unit of isolation between threads. For instance the multi-threaded ThinLTO optimizer/codegen will use one LLVM Context per-thread, and so each thread is processing a single Module / TU. The issue for concurrency is fairly deep in LLVM (use-lists, constant stored uniquely in context, etc.)…
Could you elaborate on what MLIR has done differently wrt making it multithread safe and what complications it's causing and what the trade offs are..