-
Notifications
You must be signed in to change notification settings - Fork 334
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
target/riscv: cache requests to trigger configuration
Depending on configuration, the existing implementation of watchpoints is rather inefficient for certain scenarios. Consider HW that: 1. triggers 0-3 can be used as instruction breakpoints 2. triggers 4-7 can be used as data breakpoints (watchpoints) 3. NAPOT triggers are not supported. Now, consider that we have a pending watchpoint. And we perform a "step" operation. According to the current implementation: * OpenOCD will disable watchpoints * Perform a single-step * Will try to restore the original watchpoints. It will need 12 attempts to find a suitable trigger: (8 attempts to try NAPOT, and another 4 to try GE+LE). This patch introduces a dedicated cache for requests to triggers. It significantly speeds things up, since we cache failed attempts and no additional interactions with HW is necessary.
- Loading branch information
1 parent
b5e57e1
commit ddc5f78
Showing
2 changed files
with
162 additions
and
9 deletions.
There are no files selected for viewing
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
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