Skip to content
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

Add all possible [@@noalloc] annotations to speed up generated code #64

Merged
merged 1 commit into from
Sep 11, 2021

Conversation

rixed
Copy link
Contributor

@rixed rixed commented Jun 15, 2021

The noallocs annotation makes calling the C primitives (especially short ones) much faster as it avoid useless trampolining through caml_c_call.
All external C functions not allocating memory (nor possibly raising exception) have been tagged with noalloc.

@rgrinberg rgrinberg merged commit 18d2bc6 into andrenth:master Sep 11, 2021
@rgrinberg
Copy link
Collaborator

Thanks!

rgrinberg added a commit to rgrinberg/opam-repository that referenced this pull request Oct 15, 2022
CHANGES:

## Fixes:

* Fix undefined reference to `get_uint128` (andrenth/ocaml-stdint#62)
* Add `[@@noalloc]` where possible (andrenth/ocaml-stdint#64)
* Fix compatibility with 5.0 (andrenth/ocaml-stdint#68)
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