As memory files use the native memory address size associated with their underlying platform architecture, they must match the attributes of that platform. Importantly, a memory file on a 64-bit OS requires 64-bit offset support. (Contrast that to filesystem support which is separate and independent of memory architecture support.)
Memory files on 32-bit OS platforms must use 32-bit file offsets (and cannot be HUGE).
Memory files on 64-bit OS platforms must use 64-bit file offsets (and must have HUGE file support).
When using memory files on a 64-bit server: If you create any indexes that allow duplicates, be sure to include 8 additional bytes in the total key length (rather than the typical 4 bytes) for the record offset indicator. This will avoid potentially triggering a 582 error. 115 errors can also be observed as key segment lengths do not match the assigned key length.