News for hackers. Stuff that matters.
Re:Why is Rosetta 2 fast? by vgatherps on Thursday November 10, 2022 @12:34AM (#33542661)
I believe intel used to always predict forward branches not taken and backward branches always taken if it didn’t have any history.

Regardless, you can at least lay out code in a way that heavily favors one branch over the other, and potentially optimize for one branch (I.e. give one branch very expensive prelude/exit to make another branch very cheap). The last thing I’ve seen compilers greatly struggle with though…

There are no comments on this comment yet.