Mill Computing, Inc. Forums The Mill Architecture Switches Reply To: Switches

Ivan Godard
Keymaster
Post count: 689

This is an interpreter, a class of application that is notorious for bad prediction behavior.

Direct interpreters have two branches per iteration: the switch and the loop back. The loop back will predict, the switch won’t.

In answer to your question: Mill does support indirect branches and indirect calls. Because there is only one branch site in the loop the Mill use of exit prediction is the same as a conventional branch predictor BTB. The mispredict rate is governed by the quality of the predictor and the “lumpiness” of the branching pattern, and should be similar between Mill and conventional. There may be some advantage to the Mill because the Mill prediction table is expected to be substantially larger than a conventional BTB, and so may be better at picking up history patterns; we have no data yet on that.

There’s nothing up the sleeve to let us predict the unpredictable. However, we do have one big advantage: Mill mispredict restart cost is five cycles, while that of a conventional is treble that or more.