-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Make alias input_type protected for join_node #868
Make alias input_type protected for join_node #868
Conversation
@dbiswas2808, could you please remove the line related to another PR from this patch and it would be approved and merged. |
b0dd2fb
to
05bd4dd
Compare
Done! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
I think making the aliases protected might fix the failures. If you look at the above snippet the |
@dbiswas2808, as I understand the testing failure, the problem is the following ( I have simplified a code a bit):
Visual Studio compiler for some reason interprets the usage of |
@kboyarinov That is strange indeed I haven't seen that myself before. Any updates on how to fix this or get around this issue? |
@@ -667,12 +667,12 @@ | |||
|
|||
template<typename InputTuple, typename OutputTuple> | |||
class join_node_FE<reserving, InputTuple, OutputTuple> : public reserving_forwarding_base { | |||
public: | |||
private: | |||
static const int N = std::tuple_size<OutputTuple>::value; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should there be a comment here saying why these are private?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As discussed above, this parameter is part of the internal implementation details of join_node_FE
so it should not be part of oneapi::tbb::join_node
public API.
Do you think we really need an extra comment in the code for this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤷 I'm just trying to consider a future reader looking here without much context thinking "Why are N
, output_type
, input_type
, and base_node_type
private?" I'm thinking that would be clarified if they saw // These parameters are private because they are part of the internal implementation details of join_node_FE: After all, a join node doesn't have a single input port.
Just a thought.
@dbiswas2808, as a simplest way to workaround a VS issue, I would propose to rename the template parameter of |
05bd4dd
to
179237c
Compare
@kboyarinov I just Made the suggested change. Hopefully it compiles fine on MSVC. |
@kboyarinov I've fixed the msvc compile issue as you suggested in the last commit. LMK if it looks right. |
@dbiswas2808, some checks failed - seems like |
@kboyarinov I fixed the issue I think. Seems to build on my MacOS system |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the contribution! LGTM!
@dbiswas2808, one last request from my side. Could you please add a sign-off string to the commit message? See Contribution.md for details. After that, the PR can be merged to master. |
…de public interface Signed-off-by: Deepanjan Biswas <deepanjan.biswas@formlabs.com>
Signed-off-by: Deepanjan Biswas <deepanjan.biswas@formlabs.com>
Signed-off-by: Deepanjan Biswas <deepanjan.biswas@formlabs.com>
…uilds on macOS Signed-off-by: Deepanjan Biswas <deepanjan.biswas@formlabs.com>
3e552d6
to
fdf1543
Compare
@kboyarinov I just signed off all the commits and f-pushed it. Will need your approval for the pr-builder to start I think |
Currently the public aliases exposed by
flow_graph::join_node
includesinput_type
. This is a bit confusing sincejoin_node
has multiple input ports and I believe other nodes(with multiple inputs) don't have the same issue. I have been leveraging substitution failure withinput_ports_type
andinput_type
and similarly foroutput_ports_type
andoutput_type
for implementing a higher level interface for flow_graph. AFAIT onlyjoin_node
breaks this distinction. Also, havingjoin_node
exposeinput_type
as a public alias could be confusing to users.