News for hackers. Stuff that matters.
Re:AVR-GCC Compiler Makes Questionable Code by bjt2n3904 on Saturday December 17, 2022 @12:39PM (#34030090)
I actually have no idea who maintains AVR-GCC, but this seems like an excellent bug report that could improve the performance of a very important tool chain!
Re:AVR-GCC Compiler Makes Questionable Code by psychphysic on Saturday December 17, 2022 @01:01PM (#34030361)
5.4.0 is ancient I think.
Re:AVR-GCC Compiler Makes Questionable Code by qayxc on Saturday December 17, 2022 @05:07PM (#34032762)
Amazing how in the world of software, 6 years is considered "ancient".

I know the field is a fast moving one, but my goodness. The target architecture is used in the world of embedded hardware where product lifetimes often can be measured in decades (think locomotives, industrial installations, ships, etc.)

For compliance and certification reasons alone you're often stuck with using older software versions. 6 years isn't actually that bad in that context. Keep in mind that many devices, such as ATMs, still use OS/2(!) or Windows 2000(!) as their operating systems, for example.

Re:AVR-GCC Compiler Makes Questionable Code by psychphysic on Saturday December 17, 2022 @05:17PM (#34032857)
Very good point.

Although my meaning was more that in the context of opening an issue on a project, this version is ancient.

Re:AVR-GCC Compiler Makes Questionable Code by Gibbon1 on Saturday December 17, 2022 @06:51PM (#34033524)
Well and it's not like WG14 has been doing anything constructive for the last 20 years. So it's not like there are any new features to take advantage of.

Far as I can tell the only thing I get out of newer versions of gcc is more pointless warnings to silence.

Re:AVR-GCC Compiler Makes Questionable Code by Teongot on Saturday December 17, 2022 @02:36PM (#34031333)
An excellent bug report for a compiler would

* have reduced source code for the example, preferably a single source file, in a form which can be compiled

* have the exact command line used to build it

* have the exact compiler version being used

* apply to a supported version of the compiler (GCC 5 is from 2015...)

* include an accurate explanation of what is wrong with the generated code

Maybe the last one is covered by this blog post, but things like

> I can maybe understand the subtraction of constant 0, if there’s another code path that jumps to 7ba6

suggests that the author hasn't fully analysed the generated code.

The analysis is OK though and with source code it would be a pretty good bug report.