terminated's blog

By terminated, 10 years ago, In English

Should we really care about Branch Prediction while writing and submitting code on any online judge, as branch prediction drastically can increase or decrease a programs runtime?

  • Vote: I like it
  • 0
  • Vote: I do not like it

»
10 years ago, # |
  Vote: I like it 0 Vote: I do not like it

When it would actually affect your result (AC/TLE), then yes.

Most of the time, however, no.

  • »
    »
    10 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    Xellos have you ever got your code TLE due to branch prediction?

    • »
      »
      »
      10 years ago, # ^ |
        Vote: I like it +5 Vote: I do not like it

      Yeah, but not often and mostly when using suboptimal algorithms. It's not something you should primarily worry about.