Re: mmap in php_passthru_fd in file.c ?
| From: | Rasmus Lerdorf | Date: | Fri, 18 May 2001 18:08:56 +0000 |
| Subject: | Re: mmap in php_passthru_fd in file.c ? | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-55816@lists.php.net to get a copy of this message | ||
> There seem to be some misconceptions about what we are really
> doing. We map a shared(*1), read-only copy of the file into
> our address space, we don't allocate any memory, we don't
> operate on the mmap'ed area, and this does not change when
> you "add headers or do something else to really large files".
Yes, I didn't understand the underlying nature of mmap correctly. After
Thies' message yesterday I did some reading and agree with you. The mmap
approach is good provided the OS doesn't screw up along the way.
-Rasmus