Skip to content

[Python:compiler] Replace readbytes with MMAP #6650

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

kot-begemot-uk
Copy link

This should be faster and much more "gentle" in terms of memory pressure on the host.

New contributor declaration

  • [x ] I am not making a trivial change, such as fixing a typo in a comment.

  • [x ] I have written a PR description following these
    rules.

  • [ x] I have run pre-commit run --from-ref origin/main --to-ref HEAD.

  • Select one of the following.

    • I have added tests.
      • /test for lit tests
      • /unittest for C++ tests
      • /python/test for end-to-end tests
    • This PR does not need a test because this should be 100% covered by existing tests.
  • Select one of the following.

    • [x ] I have not added any lit tests.
    • The lit tests I have added follow these best practices,
      including the "tests should be minimal" section. (Usually running Python code
      and using the instructions it generates is not minimal.)

@kot-begemot-uk kot-begemot-uk requested a review from ptillet as a code owner April 30, 2025 10:47
@kot-begemot-uk kot-begemot-uk force-pushed the mmap branch 4 times, most recently from 060fca0 to 51cb72e Compare May 1, 2025 06:10
This should be faster and much more "gentle" in terms of memory pressure
on the host.

Signed-off-by: Anton Ivanov <anton.ivanov@cambridgegreys.com>
@kot-begemot-uk
Copy link
Author

This requires a bit more thought - while the mmap datastructures should be OK for the driver load routines they fail the type checking.

Additionally, it looks like it will need tests after all because the default unit tests are of little help here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants