Techniques such as branch prediction and speculative execution are used to reduce these branch penalties . Techniques such as branch prediction and speculative execution are used to lessen these branch penalties .