On architectures that support unaligned memory access, most compilers support an option or pragma to "pack" the structure. But the usual demand is speed over space, and aligned access is usually faster, so that is the default.
↧