# perldoc > PerlIO::mmap

---
type: CommandReference
command: PerlIO::mmap
mode: perldoc
section: 
source: perldoc
---

## Quick Reference

- `open my $fh, '<:mmap', $filename;` — Open file with memory-mapped IO layer

## Name

PerlIO::mmap — Memory mapped IO

## Synopsis

shell
open my $fh, '<:mmap', $filename;
## Description

This layer performs `read()` and `write()` operations by `mmap()`ing the file if possible, but falls back to the default behavior if not.

## Implementation Note

`PerlIO::mmap` only exists to use XSLoader to load the C code that provides support for memory-mapped IO. One does not need to explicitly `use PerlIO::mmap;`.