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

Unpadded variants could avoid using Unsafe #387

Open
franz1981 opened this issue Jan 24, 2024 · 3 comments
Open

Unpadded variants could avoid using Unsafe #387

franz1981 opened this issue Jan 24, 2024 · 3 comments
Assignees

Comments

@franz1981
Copy link
Collaborator

franz1981 commented Jan 24, 2024

HI @nitsanw !

Now, for convenience we create the unpadded version of the queues out of the Unsafe-based ones, but actually, if users doesn't care about maximum performance by preventing false-sharing, maybe they are NOT interested either to use Unsafe as well, for the same reason. This would make the adoption of such wider, and life of native-image users, happier, wdyt?

@franz1981
Copy link
Collaborator Author

I can clearly provide a PR for such if you wish

@nitsanw
Copy link
Contributor

nitsanw commented Jan 25, 2024

We currently have:

  • queues
  • queues.unpadded
  • queues.atomic

You are effectively suggesting a further package of generated code, maybe queues.atomic.unpadded?

To do this we would need to look at the code gen code and generate the code, as well as modify the tests to cover the new variants. This will inflate the jar somewhat, but it's a modest increase to a pretty small jar, and people can alway strip away the extra code if they really care about size.

This is doable, but I'm not going to spend time on it :-), please feel free to PR.

@jponge
Copy link

jponge commented Apr 2, 2024

I think you can close this one due to #388 being merged 😄

Could we have a release soon? I'd replace the Unsafe/unpadded queues used in Mutiny, this also would simplify native compilation in Quarkus.

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

Successfully merging a pull request may close this issue.

3 participants