Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

✨ [rtl] add simple branch prediction #306

Merged
merged 3 commits into from
Apr 23, 2022
Merged

Conversation

stnolting
Copy link
Owner

@stnolting stnolting commented Apr 23, 2022

This PR adds something like a very branch prediction (predict "always taken") to the CPU front-end (fetch engine).

Whenever a branch or jump instruction is being executed by the execute engine, the fetch engine will stop fetching further instruction data until the branch target address has been computed (also in case of a non-taken conditional branch).

  • reduces branch penalty: no need to wait until a "speculative" instruction fetch has been completed since the fetch engine waits for the branch/jump instruction to retire
  • reduces bus traffic (eventually blocking data memory access)
  • higher performance

@stnolting stnolting added enhancement New feature or request HW hardware-related labels Apr 23, 2022
@stnolting stnolting self-assigned this Apr 23, 2022
@stnolting stnolting changed the title [rtl] add simple branch prediction ✨ [rtl] add simple branch prediction Apr 23, 2022
@stnolting stnolting marked this pull request as ready for review April 23, 2022 05:10
@stnolting stnolting merged commit c1a9cdc into main Apr 23, 2022
@stnolting stnolting deleted the add_branch_prediction branch April 23, 2022 15:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request HW hardware-related
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant