From optimization and branch predictor point of view, is there any difference between those two codes?
First:
void think_and_do(){
    if(expression){
        //Set_A of instructions
    }
    else{
         //Set_B of instructions
    }
}
int main(){
    think_and_do();
}
Second:
void do_A(){
    //Set_A of instructions
}
void do_B(){
    //Set_B of instructions
}
int main(){
    if(expression){
        do_A();
    }
    else{
        do_B();
    }
}
 
    