-
Notifications
You must be signed in to change notification settings - Fork 1.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
Add a warning if a Generator declares any Outputs before the final Input (Fixes #7669) #7697
Conversation
internal_assert(param->generator == nullptr || param->generator == generator); | ||
param->generator = generator; | ||
filter_generator_params.push_back(param); | ||
const char *const io_order_warning = "Generators will always produce code that orders all Inputs before all Outputs; " |
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.
The warning should probably include instructions to override that method if you explicitly want to have outputs declared before inputs
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.
Not sure if I entirely agree with this -- part of me wants to push back and say that anyone who really needs it will figure it out. But I'm probably overthinking it...
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.
PTAL
Accidentally checked in #7697 with the failure mode as error, not warning
Accidentally checked in #7697 with the failure mode as error, not warning
…put (Fixes halide#7669) (halide#7697) * Add a warning if a Generator declares any Outputs before the final Input (Fixes halide#7669) See halide#7669 for details * Update abstractgeneratortest_generator.cpp * Add note about allow_out_of_order_inputs_and_outputs() to warning
Accidentally checked in halide#7697 with the failure mode as error, not warning
See #7669 for details
attn @Copper280z