Y
Hacker News
new
|
ask
|
show
|
jobs
by
smeenai
3146 days ago
clang-tidy has a struct padding check which diagnoses non-optimal struct orders, and a coworker contributed a clang tool to reorder fields:
https://github.com/llvm-mirror/clang-tools-extra/tree/master...
1 comments
nly
3146 days ago
This makes sense if you're only concerned with size. Locality or eliminating false sharing may be more important in large ones
link