pastefile1
~ via C v16.0.0-clang 🌸 sw_vers
ProductName: macOS
ProductVersion: 15.0
BuildVersion: 24A5264n
~ via C v16.0.0-clang took 24ms 🌸 shasum 04-dot-product.c
94e07b787d1a0c64b6826a18a5cdb67362933e9c 04-dot-product.c
~ via C v16.0.0-clang took 29ms 🌸 clang --version
Apple clang version 16.0.0 (clang-1600.0.20.10)
Target: arm64-apple-darwin24.0.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin
~ via C v16.0.0-clang took 34ms 🌸 clang -o dot 04-dot-product.c -arch x86_64 -mavx -Wall -Wpedantic
04-dot-product.c:52:9: warning: a function declaration without a prototype is deprecated in all versions of C [-Wstrict-prototypes]
52 | int main() {
| ^
| void
1 warning generated.
~ via C v16.0.0-clang took 137ms 🌸 hyperfine ./dot -N --warmup 30
Benchmark 1: ./dot
Time (mean ± σ): 5.1 ms ± 0.2 ms [User: 2.4 ms, System: 1.6 ms]
Range (min … max): 4.8 ms … 7.8 ms 501 runs
Warning: Statistical outliers were detected. Consider re-running this benchmark on a quiet system without any interferences from other programs. It might help to use the '--warmup' or '--prepare' options.
~ via C v16.0.0-clang took 2s 🌸 ./dot
2255.000000
2255.000000
~ via C v16.0.0-clang took 32ms 🌸