MMapFile on windows

@pondering Code is tested under Windows x64. Please test it on mac. If everything goes well, please merge it.