4 ms·
In the domain we’re in, “branch” means a branch instruction. If we used your definition, then any load and store instruction would count as a branch, which is n
by scott_s 9y ago
In the domain we’re in, “branch” means a branch instruction. If we used your definition, then any load and store instruction would count as a branch, which is not how people use the term. It gives the wrong idea, exemplified by the fact that the submitted article gets it wrong.
- akvadrako 9y agoIf you aren’t a cpu designer than any split between paths of execution is a branch. It gives the right idea, even if the terminology isn’t precise.
- scott_s 9y agoI'm not a "cpu designer," but I am a computer scientist, and when I say "branch," my colleagues expect that I'm talking about an actual branch instruction.
- akvadrako 9y agoIt is an actual branch - just because it has a special instruction is an implementation detail. In computer science there is no difference between throwing an error and skipping the rest of the instructions in the stack. If you wrote a vm with a cpu simulation you would implement it as a branch.
- tptacek 9y agoThis is not a great hill to die on. There are "exception branch tables" and "interrupt branch tables" to configure the implicit branch taken by (say) an interrupt, which acts like a sort of invisible branch; also, on some architectures, rather than "call" you have, literally, "branch and link". You made the point well above when you pointed out that the code paths don't depend on conditional branches that are predicted and explicitly speculated on. I don't think the rest of the semantics are worth litigating.