Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
smeenai
· 9y ago · 0 comments
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...
Comments
[–]
nly
9y ago
This makes sense if you're only concerned with size. Locality or eliminating false sharing may be more important in large ones