Genode and clang

Norman Feske norman.feske at genode-labs.com
Fri Nov 13 11:46:05 CET 2020


Hi Piotr,

it is great to see the story behind your recent pull requests. Thanks
for sharing it. I'm happy to read that the experience left such a good
impression on you.

On 10.11.20 22:30, Piotr Tworek wrote:
> The reaason I'm writing this email is to ask if Genode project would be
> potentially interested in having clang support in the main repo? I know
> that officialy supporting another compiler might not be an interesting
> prospect for the project and I won't mind if the answer is no.

We (as Genode Labs) are unable to officially offer support for a second
compiler besides GCC because this addition would imply the need to
double our CI efforts. But this economic constraint should not stand in
the way of people who are fine with using another compiler at their own
risk. As nicely illustrated by your pull request [1], the quality of our
code base can only benefit from it.

[1] https://github.com/genodelabs/genode/pull/3938

Besides the code-quality aspect, I find your direction interesting for
two other reasons also.

First, I foresee an increasing relevance of tools like clang-tidy for
our project. In the back of my head, I'm thinking of potential ways to
formalize the use of Genode's coding style [2] beyond mere conventions.
The clang project would be the most natural basis for creating a static
analyzer with custom rules.

Second, when considering future support for languages like Rust or Zig,
which rely on LLVM as their basis, we will need to attain a certain
degree of compiler interoperability. Lowering the friction between
Genode and Clang will ultimately help in this respect.

[2] https://genodians.org/nfeske/2019-01-22-conscious-c++

> Its enough for me if generic fixes I make get merged :). If there is an
> interest in clang support however, I'll be happy to spend a few
> evenings cleaning up my work and making a few more PRs out of it. If
> needed I can also push my remaing clang support patches in the
> existing, slightly chaotic form, to some branch so Genode developers
> can see how much work having clang support in Genode would entail.

Your generic fixes are more than welcome. :-)

I'm certainly supportive for giving Genode users the choice to use Clang
as an option as long as it cannot be mistaken as a feature officially
provided by Genode Labs. The documentation of this option could simply
clarify that. So please don't hesitate to go forward. But don't feel
pressured to hurry either.

Cheers
Norman

-- 
Dr.-Ing. Norman Feske
Genode Labs

https://www.genode-labs.com · https://genode.org

Genode Labs GmbH · Amtsgericht Dresden · HRB 28424 · Sitz Dresden
Geschäftsführer: Dr.-Ing. Norman Feske, Christian Helmuth



More information about the users mailing list