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

tests: benchmarks: latency_measure: timing measurement values are all 0 #30322

Closed
ABOSTM opened this issue Nov 30, 2020 · 3 comments · Fixed by #30327
Closed

tests: benchmarks: latency_measure: timing measurement values are all 0 #30322

ABOSTM opened this issue Nov 30, 2020 · 3 comments · Fixed by #30327
Assignees
Labels
bug The issue is a bug, or the PR is fixing a bug platform: STM32 ST Micro STM32 priority: high High impact/importance bug

Comments

@ABOSTM
Copy link
Collaborator

ABOSTM commented Nov 30, 2020

Describe the bug
Running tests/benchmarks/latency_measure on nucleo_f746zg,
test is passed, but all timing measurement values are 0 ns.

To Reproduce
Steps to reproduce the behavior:

  1. west build -p auto -b nucleo_f746zg tests/benchmarks/latency_measure
  2. west flash
  3. See log

Expected behavior
Non null timing measurement value

Logs and console output

*** Booting Zephyr OS build zephyr-v2.4.0-1849-gc0650217cc7c  ***
START - Time Measurement
Timing results: Clock frequency: 72 MHz
Average thread context switch using yield                   :       0 cycles ,        0 ns
Average context switch time between threads (coop)          :       0 cycles ,        0 ns
Switch from ISR back to interrupted thread                  :       0 cycles ,        0 ns
Time from ISR to executing a different thread               :       0 cycles ,        0 ns
Time to create a thread (without start)                     :       0 cycles ,        0 ns
Time to start a thread                                      :       0 cycles ,        0 ns
Time to suspend a thread                                    :       0 cycles ,        0 ns
Time to resume a thread                                     :       0 cycles ,        0 ns
Time to abort a thread (not running)                        :       0 cycles ,        0 ns
Average semaphore signal time                               :       0 cycles ,        0 ns
Average semaphore test time                                 :       0 cycles ,        0 ns
Semaphore take time (context switch)                        :       0 cycles ,        0 ns
Semaphore give time (context switch)                        :       0 cycles ,        0 ns
Average time to lock a mutex                                :       0 cycles ,        0 ns
Average time to unlock a mutex                              :       0 cycles ,        0 ns
===================================================================
PROJECT EXECUTION SUCCESSFUL

Environment (please complete the following information):

  • OS: Windows
  • Toolchain gnuarmemb
  • Commit SHA 1b65fd0

Additional context
Add any other context about the problem here.

@ABOSTM ABOSTM added bug The issue is a bug, or the PR is fixing a bug platform: STM32 ST Micro STM32 labels Nov 30, 2020
@ABOSTM ABOSTM self-assigned this Nov 30, 2020
@ABOSTM
Copy link
Collaborator Author

ABOSTM commented Nov 30, 2020

Issue is linked to DWT which never starts.
Writing to DWT registers is inefficient.
On Cortex M7 access to DWT register may be lock.
See #30327

@nashif
Copy link
Member

nashif commented Nov 30, 2020

@ioannisg FYI

@nashif nashif added the priority: high High impact/importance bug label Dec 1, 2020
@ioannisg ioannisg self-assigned this Dec 1, 2020
@ioannisg
Copy link
Member

ioannisg commented Dec 1, 2020

Will take a look, sure

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug The issue is a bug, or the PR is fixing a bug platform: STM32 ST Micro STM32 priority: high High impact/importance bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants