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

specializations for the Base array aliasing API #53

Open
nsajko opened this issue May 4, 2024 · 2 comments
Open

specializations for the Base array aliasing API #53

nsajko opened this issue May 4, 2024 · 2 comments

Comments

@nsajko
Copy link
Collaborator

nsajko commented May 4, 2024

AFAIK specializing Base.dataids could improve performance, while specializing Base.mightalias could improve aliasing safety. There's also Base.unaliascopy. None of these are officially API, though...

Xref JuliaLang/julia#51753

@nsajko
Copy link
Collaborator Author

nsajko commented May 4, 2024

specializing Base.dataids could improve performance

In pathological cases adding two FixedSizeVectors can spend most of its time in Base.dataids (which falls back to objectid). Adding equal Arrays spends much less time in Base.dataids.

@nsajko
Copy link
Collaborator Author

nsajko commented May 4, 2024

Actually I think we only need dataids: mightalias is accurate after overloading dataids. unaliascopy seems like it's not necessary for FixedSizeArrays.jl because we already have copy(::FixedSizeArray) returning a value of the same type as its argument.

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

No branches or pull requests

1 participant