bytecodealliance / bytecodealliance/wasmtime
clock() function in ctime always return 0
Open
bug
- Dominant language
- Rust
- Stars
- 18.6k
- Forks
- 1.8k
- Avg merge
- 1d 18h
- Merged PRs (30d)
- 126
Description
### Test Case
```cpp
#include
#include
int main() {
clock_t time = clock();
printf("%ld\n", time);
}
```
### Steps to Reproduce
* Use wasi-sdk to compile.
* Use wasmtime run the WASM module.
### Expected Results
The clock tick after the module start to run.
### Actual Results
0
### Versions and Environment
Wasmtime version or commit: 0.28
Operating system: macOS 12.1 & Ubuntu 20.04
Architecture: x86_64
Contributor guide
Assessment
This issue has not been assessed yet.