-
Notifications
You must be signed in to change notification settings - Fork 211
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
Rm/2426 #2517
base: master
Are you sure you want to change the base?
Rm/2426 #2517
Conversation
There is a bug souffle-lang#2426, which causes an assertion in the SelingerProfileSipsMetric::getReordering. Rther than fixing the problem I decided to work-around it for the time being, until we have a proper fix. We can work around this problem in one of two ways: 1. don't assert and just don't reorder atoms (this should be fine) 2. don't create the metric in the first place, if there is no profile I decided to use souffle-lang#2 as that seems to be the safer option. I added code for a warning, but disabled it because it is incompatible with the ctest suite.
We should print a warning about --auto-schedule not being enabled. If we do that we also need to change the unit test setups for scheduler tests.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #2517 +/- ##
==========================================
- Coverage 81.12% 81.11% -0.01%
==========================================
Files 492 492
Lines 33361 33362 +1
==========================================
- Hits 27063 27062 -1
- Misses 6298 6300 +2
|
// TODO: enable this, but if we do the scheduler tests won't run as they do now | ||
#if 0 | ||
std::cerr << "WARNING: `--auto-schedule` cannot be used due to missing scheduler stats; falling back " | ||
"to heuristic '" | ||
<< heuristic << "'" << ::std::endl; | ||
#endif |
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 this TODO be addressed?
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 think we should print the warning, but I'm not too familiar with CMAKE to make the updates to the test scripts.
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.
Do you mind merging as is?
Issue #2426 shows a problem (crash) when using the auto-scheduler on valid input. This MR is an attempt to circumvent the issue by not using the auto-scheduler if there is no good profile and falling back to a heuristic.
I realize that this is not ideal, but I would prefer using a heuristic to crashing. This fix also gives us some more time to address the underlying bug. If you think the underlying bug is easy to fix, I can take a stab at it, but since it's been open for 1 year, it's probably harder to fix.
There is code for a warning message when there is a problem with the auto-scheduler, but I could not figure out how to integrate that into the ctest suite. The problem is because the warning causes the two expected err outputs to be different between the two runs and the test isn't set up to support that.