Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Branch Misses

Name: Anonymous 2011-09-26 17:26

How bad do branch misses hurt a programs performance? In C and Java?

for example how big of an impact would :


int shitinanus()
{
    int val = getanus();
    if(val != 0)
        return ANALTONIGHT;
    return ALONETONIGHT;
}


be knowing that val will most likely be 0 99% of the time compared to the below function


int shitinanus()
{
    int val = getanus();
    if(val == 0)
        return ALONETONIGHT;
    return ANALTONIGHT;
}

Name: Anonymous 2012-03-29 22:37

>>127
Did you notice the AMD chip there? AMD has nowhere near the amount of money Intel does. And yet...
AMD Athlon 64 X2 (K8): 0.90 MIPS/MHz/thread

There's also this dark horse:
MCST Elbrus-3S: 1.25 MIPS/MHz/thread

which is apparently "VLIW" but also "x86 compatible".

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List