Skip to content

Conversation

yanmulin
Copy link

原始版本

Initial energy: -13.414000
Final energy: -13.356842
Time elapsed: 1498 ms

优化1. 添加-ffast-math -march=native 编译选项

Initial energy: -13.413999
Final energy: -13.356841
Time elapsed: 980 ms

优化2. 使用std::sqrt,提取循环不变量

Initial energy: -13.413998
Final energy: -13.356841
Time elapsed: 735 ms

优化3. 使用SOA内存布局,更高效利用缓存

Initial energy: -13.414011
Final energy: -13.403986
Time elapsed: 159 ms

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant