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

Array_gpu::operator= does not allocate correctly #31

Open
stijnh opened this issue Feb 5, 2024 · 1 comment
Open

Array_gpu::operator= does not allocate correctly #31

stijnh opened this issue Feb 5, 2024 · 1 comment

Comments

@stijnh
Copy link

stijnh commented Feb 5, 2024

On the current main branch, I feel that operator= of Array_gpu is not implemented correctly. It first sets this->ncells and then checks if this->ncells == 0 to allocate memory if required. However, this well never happens since ncells was just set beforehand:

else if (this->ncells == 0)

I will fix this in a PR once I understand the Array class better.

@Chiil
Copy link
Member

Chiil commented Feb 6, 2024

You are correct. I implemented the view option later and something seem to have gone wrong here. As said before. On the long term we are also open for other array classes if you have better alternatives.

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

2 participants