anchor.diff:              | Some (start, length) -> File.ReadBinaryChunk(fileName, start, length)
           ByteFile(fileName, bytes) :> BinaryFile
   
  -let tryMemoryMapWholeFile opts fileName = 
  -    let file = 
  -        try 
  -            MemoryMapFile.Create fileName :> BinaryFile
  -        with _ ->
  -            createByteFileChunk opts fileName None
  -    let disposer = 
  -        { new IDisposable with 
  -           member __.Dispose() = 
  -            match file with 
  -            | :? MemoryMapFile as m -> m.Close() // Note that the PE file reader is not required after this point for metadata-only reading
  -            | _ -> () }
  -    disposer, file
  +let createMemoryMapFile fileName = 
  +    let mmf, accessor, length = 
  +        let fileStream = File.Open(fileName, FileMode.Open, FileAccess.Read, FileShare.Read)
  +        let length = fileStream.Length
  +        let mmf = MemoryMappedFile.CreateFromFile(fileStream, null, length, MemoryMappedFileAccess.Read, HandleInheritability.None, leaveOpen=false)
  +        mmf, mmf.CreateViewAccessor(0L, fileStream.Length, MemoryMappedFileAccess.Read), length
  +    let safeHolder =
  +        { new obj() with
  +            override x.Finalize() =
  +                (x :?> IDisposable).Dispose()
  +          interface IDisposable with
  +            member x.Dispose() =
  +                GC.SuppressFinalize x
  +                accessor.Dispose()
  +                mmf.Dispose()
  +                stats.memoryMapFileClosedCount <- stats.memoryMapFileClosedCount + 1 }
  +    stats.memoryMapFileOpenedCount <- stats.memoryMapFileOpenedCount + 1
  +    safeHolder, RawMemoryFile(fileName, safeHolder, accessor.SafeMemoryMappedViewHandle.DangerousGetHandle(), int length) :> BinaryFile
   
   let OpenILModuleReaderFromBytes fileName bytes opts = 
       let pefile = ByteFile(fileName, bytes) :> BinaryFile
  
positive.code: 
                  // For metadata-only, always use a temporary, short-lived PE file reader, preferably over a memory mapped file.
                  // Then use the metadata blob as the long-lived memory resource.
                  let disposer, pefileEager = tryMemoryMapWholeFile opts fullPath
                  use _disposer = disposer
                  let (metadataPhysLoc, metadataSize, peinfo, pectxtEager, pevEager, _pdb) = openPEFileReader (fullPath, pefileEager, None, false) 
                  let mdfile = 
  
negative.code:     member __.FileName = fileName
      interface BinaryFile with
          override __.GetView() = view :>_
  
  /// Read file from memory blocks 
  type ByteView(bytes: byte[]) = 
  