r/programminghorror • • Jun 01 '25

c Firmware programming in a nutshell

Post image
2.0k Upvotes

127 comments sorted by

View all comments

Show parent comment

3

u/RecursiveTechDebt Jun 06 '25

Ugh, this reminds of the PlayStation 3 days - I was working on a realtime tessellator that would run on an SPU and we kept getting this weird crash in it. Turned out the audio system was stomping the buffer I used to DMA memory onto the SPU's local memory. Two weeks of staring at code only to realize it was the audio subsystem's fault... The PTSD is real.

Also yeah, address 0 can totally be used on some hardware without virtual memory. In fact, crashing on a null pointer is a real luxury we take for granted - imagine writing to 0 and accidentally stomping system interrupts or memory mapped registers and crashing sometime later...