title: Memory Alignment vs Page Alignment
body: <p>Often we hear that aligning our variables to an N-byte boundary in memory can improve performance (by preventing the CPU from having to load two separate 'words' in to the cache to read our variable).</p>
  
  <p>On the other hand, we also hear (less often) that aligning a large block of memory (array/buffer) to a nice, round power-of-two address can be bad because the hashing function that allocates memory addresses to cache addresses is no longer uniform (this is called page alignment).</p>
  
  <p>Therefore, my question is, is there some sort of rule or threshold point about when we should deliberately misalign data to avoid the problem of page alignment; and when not to, to gain the benefits of standard memory alignment?</p>