提交 f23716a1 编写于 作者: E Eason

use java command

上级 93de7578
......@@ -66,7 +66,7 @@
消耗时间(毫秒):100
### c. 使用perf验证缓存命中率
#### 使用array[i][j]遍历数组
`perf stat -e cache-references,cache-misses,instructions,cycles,L1-dcache-load-misses,L1-dcache-loads ./traverse_2d_array -f`
`perf stat -e cache-references,cache-misses,instructions,cycles,L1-dcache-load-misses,L1-dcache-loads java traverse_2d_array -f`
* 输出结果:
```
Performance counter stats for 'java traverse_2d_array -f':
......@@ -84,7 +84,7 @@
0.047877000 seconds sys
```
#### 使用array[j][i]遍历数组
`perf stat -e cache-references,cache-misses,instructions,cycles,L1-dcache-load-misses,L1-dcache-loads ./traverse_2d_array -s`
`perf stat -e cache-references,cache-misses,instructions,cycles,L1-dcache-load-misses,L1-dcache-loads java traverse_2d_array -s`
* 输出结果:
```
Performance counter stats for 'java traverse_2d_array -s':
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册