Use toolchain reference timer frequency - #5
Open
xross wants to merge 1 commit into
Open
Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates Basix’s reference timer frequency handling by deriving BASIX_TIMER_HZ from toolchain-provided timer macros (VX/XS), rather than using a hard-coded default, and updates the corresponding “pass” test to validate the new behavior.
Changes:
- Define
BASIX_TIMER_HZfromVX_TIMER_HZorXS1_TIMER_HZwhen not application-overridden. - Add
<timer.h>usage to access toolchain timer frequency macros. - Update
test_basix_passto validateBASIX_TIMER_HZagainst the toolchain macro(s) instead of100000000U.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| tests/test_basix_pass/src/test_basix_pass.c | Updates runtime checks so the test validates BASIX_TIMER_HZ against toolchain timer macros. |
| lib_basix/api/basix/architecture.h | Switches BASIX_TIMER_HZ defaulting logic to use toolchain timer frequency macros and errors if none are available. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
xross
force-pushed
the
feature/timer_define
branch
from
August 7, 2026 13:56
61d5352 to
9eb0e21
Compare
Define BASIX_TIMER_HZ from the XS or VX toolchain timer macros while preserving application overrides.
xross
force-pushed
the
feature/timer_define
branch
from
August 7, 2026 13:57
9eb0e21 to
1a7e032
Compare
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Define BASIX_TIMER_HZ from the XS or VX toolchain timer macros while preserving application overrides.