Yes, I think its simpler to write anyway. Its definitely more modern and more streamlined - and has tons of registers.
They are not inlined assembly (more like intrinsics).
Again you are in a Baremetal section we don't really know about Raspbian but I guess it would be like
You might as well just start with Ultibo it's all in Pascal and has the most complete operation of peripherals up outside an O/S.
Looking at the code produced by recent GCC (7.2) I would change that from "unless you REALLY know the instruction set" to "even if you REALLY know the instruction set" - compilers have moved on since the 6502 and have many intrinsic advantages compared to humans.
Well never professionally of course, but purely for fun at home, maybe, with no expectations of beating the compiler (as the OP said FOR FUNZIES).
Of course you're right. But I did not meant the source referring to them. What I should have made clear, those are implemented as inlined Assembly in the C compiler's source. So the answer is yes, the C compiler is not entirely written in C. It must have tiny bits of inlined Assembly, and intristics (like __builtin_memcpy and __builtin_va_args) are good examples of that.
Users browsing this forum: No registered users and 4 guests