News for hackers. Stuff that matters.
Re:AVR-GCC Compiler Makes Questionable Code by nicoburns on Saturday December 17, 2022 @08:50PM (#34034281)
> So really anything on an AVR8 that isn't either an 8- or 16-bit int, unsigned or signed, is going to be complete and utter monster to deal with.

I don’t see why this a problem. Both C and Rust give you 8 bit and 16 bit types to work with. It’s true that you may sometimes need assembly to eke out the last drops of performance on such small chips, but equally sometimes you don’t and C/C++/Rust are excellent tools for the job.

Re:AVR-GCC Compiler Makes Questionable Code by arcticbull on Saturday December 17, 2022 @08:51PM (#34034289)
You can use larger types, maybe even floats I can't recall, they'll get lowered to the target architecture and the generated code will be in terms of smaller width registers. A 32-bit add will get turned into 1 8-bit add and 3 8-bit add-with-carry instructions. You won't even notice, unless to your point, you see a performance issue or start running out of code space.
Re:AVR-GCC Compiler Makes Questionable Code by bpye on Saturday December 17, 2022 @10:42PM (#34034833)
AVR GCC totally lets you use floats, I'm not sure about Rust. It does as you'd expect result in a lot of code, but it seems correct.
Re:AVR-GCC Compiler Makes Questionable Code by Gordonjcp on Sunday December 18, 2022 @10:32AM (#34038594)
It does, but they are unbearably slow.