Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
buffer more reads from a boot-file file descriptor
Without this additional buffering, loading boot files can trigger thousands of small reads to parse a boot file. Introducing buffering earlier in the process to reduce the number of those `read` system calls to between 100 and 200. The difference in startup time turns out to be very small on Linux and macOS --- just a a couple of milliseconds, if anything. But buffering is generally a good idea, and the change makes a startup system-call trace look less suspicious. In addition to buffering changes, this commit adds `Sregister_boot_file_bytes`, so that an embedding application can point to bytes that are already loaded into memory.
- Loading branch information