+ (sb-posix:mmap nil size prot sb-posix::MAP-SHARED fd 0)
+ (sb-posix:syscall-error nil))
+ #+win32
+ (let ((mapping
+ (sb-win32:create-file-mapping
+ (sb-win32:get-osfhandle fd) nil 2 0 size nil)))
+ (typecase mapping
+ ((integer -1 0) nil)
+ (t (let ((sap (prog1 (sb-win32:map-view-of-file
+ mapping 4 0 0 size)
+ (sb-win32:close-handle mapping))))
+ (and (not (zerop (sb-sys:sap-int sap))) sap)))))))