有没有检测和报告 C 或 C++ 应用程序中 False Sharing 的工具?
有没有检测和报告 C 或 C++ 应用程序中 False Sharing 的工具?
尝试使用valgrind的DRD(数据竞争检测)模块。
从手册上看,它似乎可以用于检测虚假共享问题。
Perf("Performance Counters for Linux")
命令:
sudo perf record -e cache-misses,anything_else_you_want ./your_program
sudo perf report