Dangers of Array Padding
- Compiler will automatically pad local data
- -O3 optimization will automatically pad common blocks
- Padding of common blocks is safe as long as the Fortran standard is not violated:
- Fix violation or do not to use this optimization either by compiling with lower optimization or using explicit compiler flag:
COMMON // A(512,512), B(512,512)