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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CPU] area and timing optimization; closing further illegal instruction holes #293

Merged
merged 15 commits into from
Apr 5, 2022

Conversation

stnolting
Copy link
Owner

@stnolting stnolting commented Apr 4, 2022

馃搱 This PR improves the overall efficiency of the CPU: the logic optimizations from this PR reduce the area costs of the CPU (~8% less) while also shortening the CPU's critical path (~12% higher f_max).

馃敀 Furthermore, this PR closes further illegal instruction holes (illegal instruction words that where not correctly detected or that caused side effects even if identified as "illegal").

馃悰 This PR also fixes a rare bug in the core of the NEORV32 runtime-environment (RTE): if the C-extensions is disabled, a malformed instruction word that uses an opcode from the RVC (compressed) instruction space would cause the computation of an incorrect return address.

moved memory data registers and optimized data alignment logic: ~20% less hardware required due to better logic->LUT combining
added malformed "mret" (incorrect opcode) that will crash the system if any part of it gets executed
use malformed "mret" for testing and also check for unintended side effects
@stnolting stnolting added the HW hardware-related label Apr 4, 2022
@stnolting stnolting self-assigned this Apr 4, 2022
@stnolting stnolting changed the title [CPU] area and timing optimization [CPU] area and timing optimization; closing further illegal instruction holes Apr 4, 2022
* reduced hardware costs (smaller logic)
* shortened critical path (branch logic); ~10% higher f_max
* closed further illegal instruction holes
@stnolting stnolting marked this pull request as ready for review April 4, 2022 13:17
fixed rare bug: malformed instruction word (with opcode from the compressed instructions space) caused computation of wrong return address if C extension is disabled
* further optimizations
* added logic to avoid side-effects of illegal xret instructions
achieving 130MHz on Intel Cyclone IV!
@stnolting stnolting merged commit 1dffa64 into main Apr 5, 2022
@stnolting stnolting deleted the area_and_clock_opt branch April 5, 2022 09:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
HW hardware-related
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant