-
Notifications
You must be signed in to change notification settings - Fork 233
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
✨ add optional CPU clock gating #775
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
clk_i: main clock, can be switched off clk_aux_i: always-on clock
- SYSINFO->SOC bit 7 - some minor VHDL clean-ups (remove use of custom bool-to-std_ulogic function)
- minor code clean-ups (remove private print true/false function)
default = false; update version ID
- add new CLOCK_GATING_EN generic
- simplify instruction fetch engine: remove PARKED state, use the IPB FIFO level to check if the instruction fetch has halted - make sure halt request signal is not registered by the switched-off clock - add registered sleep mode signal
- add CPU's clk_aux_i port - add new processor generic CLOCK_GATING_EN - refine section "sleep mode"
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR adds an optional clock gating mechanism to the processor. When enabled, the clock of the CPU core is shut down during sleep mode to reduce power consumption. This concept was developed/proposed by @mikaelsky in #772.
neorv32_clockgate.vhd
that implements the clock switchA secondary, always-on clock is added to the CPU. This additional clock is used to keep the interrupt buffer logic active while the rest of the CPU is switched off. Any (enabled) interrupt request (including a debug halt request) will make the CPU leave sleep mode.
The CPU's sleep signal is set high only when
Right now, just the CPU core is turned off during sleep mode. But I think it might be possible to shut down the caches and bus switch as well. If the DMA is not required the entire interconnect could be shut down as well.