Skip to content

Only access Zephyr thread stats info when it's available #3962

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

Merged
merged 2 commits into from
Dec 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions core/shared/platform/zephyr/zephyr_time.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ os_time_get_boot_us()
uint64
os_time_thread_cputime_us(void)
{
/* On certain boards, enabling userspace could impact the collection of
* thread runtime statistics */
#ifdef CONFIG_THREAD_RUNTIME_STATS
k_tid_t tid;
struct k_thread_runtime_stats stats;
uint32 clock_freq;
Expand All @@ -27,4 +30,7 @@ os_time_thread_cputime_us(void)
}

return time_in_us;
#else
return os_time_get_boot_us();
#endif
}
2 changes: 1 addition & 1 deletion product-mini/platforms/zephyr/simple/build_and_run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ TARGET=$1

case $TARGET in
$X86_TARGET)
west build -b qemu_x86_nommu \
west build -b qemu_x86_tiny \
. -p always -- \
-DWAMR_BUILD_TARGET=X86_32
west build -t run
Expand Down
7 changes: 7 additions & 0 deletions tests/fuzz/wasm-mutator-fuzz/portal/osv-scanner.toml
Original file line number Diff line number Diff line change
Expand Up @@ -50,3 +50,10 @@ name = "vite"
ecosystem = "npm"
ignore = true
reason = "Development server not exposed to untrusted networks"

# GHSA-mwcw-c2x4-8c55
[[PackageOverrides]]
name = "nanoid"
ecosystem = "npm"
ignore = true
reason = "Accepted known vulnerabilities for testing purposes"
Loading