-
Notifications
You must be signed in to change notification settings - Fork 310
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
[BUG]: Use of raft::span initialize in per_v_transform_e.cuh results in failure of is_allowed_element_type_converstion_t #4850
Comments
You mean this code tries to assign a Or did I misinterpret your question? |
Just below that. So the two instances where you try to initialize from
The other uses of the std::optional<std::variant<>> stuff in the rest of this compilation unit don't try to use this particular way to initialize the the lhs so they don't run in to this problem but this one does and while there's nothing wrong per se with what you're doing here it runs afoul of the the |
I am not following this. Which type & version of compiler are you using? This code path is actually used and I haven't seen a build error. Initializing a If we are assigning Let me know if I am misinterpreting your question or I am missing something else. And it will be really helpful if I can reproduce your build error. |
I'm just pointing out something in your code that is not standards compliant and passes when it shouldn't. Clang catches this. Maybe nvcc interprets this differently but I don't understand why yet. What I do know is that it fails the is_allowed_element_type_convert_t test and nvcc for some reason passes it (yet doesn't pass it in the simplified example I sent which, honestly, after years of doing this isn't surprising...i.e. a complex example failing and a simplified example passing....this is just the reverse). So you have a situation where A = B B is used to initialize A. To do this we need to call an operator= member function in span.hpp which acts as our constructor.
So the bit in bold is the bit that should fail based on what it's trying to do. In span, that test looks like
If the test were different, i.e.
This would pass if From was However,the test is trying to determine if 'uint32_t (*)[]' (a pointer to an array) is convertible to |
Your explanation makes perfect sense if the type of
What I am struggling to understand is why the constructor to create I am digging into the documentation of |
Version
25.02
Which installation method(s) does this occur on?
No response
Describe the bug.
In compiling 25.02, specifically the file src/prims/detail/per_v_transform_e.cuh, one runs in an error in the following code block:
The particular error occurs in the if/else block where hypersparse_non_deg1_key_offsets is intialized using raft::device_span (both instances, on in the if block, the other in the else block. Tracking this down one can see that the failure occurs in raft's span.hpp where you have
The error occurs because is_allowed_element_type_conversion_t returns false, causing the enable_if to fail and thus not implement the constructor. The compiler then is unable to find a suitable constructor amongst the available options.
It appears this is just a 'failure' of span to be willing to convert one integer pointer to another another integer pointer of a different size.
Minimum reproducible example
Relevant log output
Environment details
Other/Misc.
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: