First-time binutils repository code-stare - indentation and contribution process

Francois H. Theron francois.theron@netronome.com
Thu Oct 26 14:47:00 GMT 2017


Good day


# Indentation

>From a 2007 email
(https://sourceware.org/ml/binutils/2007-03/msg00189.html) it seems
indentation for binutils is 2 spaces and coding style should be the
same as GNU Coding Styles
(https://www.gnu.org/prep/standards/standards.html#Formatting).

In readelf.c I see some inconsistent mixed use of real tabs and spaces
on the same line. I assume the normal convention applies where you
leave existing invalid whitespace alone, but use the correct style for
new code?

I'd like to suggest adding a ".editorconfig" file to the binutils repo
(http://editorconfig.org). It seems to be a perfect alternative to
adding "pages" of editor-specific modelines to all files. It also
serves as a very clear reference for what indentation should look like
to anyone looking at the repository if they choose not to use a plugin
for editorconfig.

# Contributing

I would like to start work on adding basic support for a new chip
architecture, or at least investigate the work involved in doing so. I
could not find a clear guide regarding patch submissions and review
processes. I did find
https://sourceware.org/binutils/binutils-porting-guide.txt which is
helpful, but I'm not sure how I would go about committing. Is it
recommended that the initial support for a new arch be contained in
one patch or would it be more sensible to have a series of patches
that each adds a small part of functionality?

For reference, the new architecture would be for a Netronome Flow
Processor which uses a fair amount of processor specific ELF flags,
section types, .notes and of course a processor specific instruction
set. EM_NFP has been assigned the value of 250
(https://groups.google.com/forum/#!topic/generic-abi/7QVcsE1quQ4) and
it seems appropriate to add support to binutils rather than only
providing a stand-alone toolset for file dump and disassembly.


Regards

Francois H. Theron



More information about the Binutils mailing list