Re:FaCT: Constant Time Programming Language
by kragen on Monday October 24, 2022 @02:39PM
(#33320615)
Slightly higher real latency? Are you talking about asynchronous CPUs like the GreenArrays GA144? Or saying that if you're running off the internal RC oscillator the clock speed will vary because the supply voltage varies depending on memory access patterns? Or by "slightly higher real latency" do you mean that an instruction will take 2 clock cycles instead of 1 or 3 cycles instead of 2? I don't think any of those are true on things like the ATMega328 AVR8 mentioned above or the Padauk PMS150C. Maybe you mean something else?
Bitbanging protocols with tight timing requirements using cycle-accurate code is still a thing people routinely do on small microcontrollers, and it wouldn't work if instruction timing was as unpredictable as you're saying.
Nevertheless, I agree that removing data-dependent branches is a better way to close timing leaks.
Bitbanging protocols with tight timing requirements using cycle-accurate code is still a thing people routinely do on small microcontrollers, and it wouldn't work if instruction timing was as unpredictable as you're saying.
Nevertheless, I agree that removing data-dependent branches is a better way to close timing leaks.