I was arguing on a different forum about how to write "optimized" C/C++ code. The other person got really mad and just walked away. Mostly 'cause they started talking mad poop about how I probably don't know the difference between C or C++ or even understand programming at all (which made me lol; it's a videogame board, I'm not going into super detail talking about programming).
Anyway, they threw around the term "pipeline stall". I tried reading up on this but all I can find about it are super low-level computer architecture stuff. Basically, what causes a pipeline stall from the C perspective? What is it exactly? Why should I care?
It seems like a super micro-optimization that doesn't honestly matter.
It was also funny that they acted like changing thread priority was a valid means of "optimizing" code.
Edit : Oh God, so much computer architecture! Forget it, tooooo boring XD
Lol jk. But seriously, trying to read up on this is... It's a new world lol. I thought I was special because I was using the "restrict" keyword. Guess not O_o
It seems like conditional code (using an if) creates a stall (duh!). But also it seemed like using a function pointer prevented the processor from saturating the pipeline with future instructions. Is that a correct interpretation? I'm actually very curious about this now.