This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: score gcc-8 warning fixes


On 05/12/2018 03:02 AM, Alan Modra wrote:
> Rather than just silencing the gcc-8 warnings, I decided to rewrite
> the buffer handling in the two functions where gcc was warning.
> The rest of the file could do with the same treatment.  We're not
> supposed to have line length limits in the assembler.
> 
> 	* config/tc-score.c (s3_do_macro_bcmp): Don't use fixed size
> 	buffers.
> 	(s3_do_macro_bcmpz): Likewise.

+1

Where possible we fixup code in glibc to remove gcc-8 warnings where
it's a clear win.

These two cases you fix here are relatively easy to clean up, the rest
looks like quite a complicated refactoring, particularly when it comes
to copying error messages based on input from a line etc. There would
be quite a bit of work to clean it all up. It seems to me like you'd
want to delete s3_MAX_LITERAL_POOL_SIZE and fixup the fallout by
dynamically allocating whatever you needed? I've been looking for a
straight forward cleanup project for a new person on my team :-)

-- 
Cheers,
Carlos.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]