Conversation
…lti-threaded timing
…way to converting hessian to square in issue-2821
…t conversion to square Hessian and passing it via Highs::passHessian
…alysis and calling setup before mipsolver.run()
…olverCallTime for multiple threads
…lobal_sub_solver_call_time_ into HiGHS.h so that any Highs instance can work with the sub_solver_call_time_ member from a root Highs instance
publish-nuget action
Added testing of passing square Hessian via `passModel` and `passHessian`
…into thread-mip-timer
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## hmw-mt #2966 +/- ##
==========================================
- Coverage 81.42% 81.18% -0.25%
==========================================
Files 361 361
Lines 89621 89801 +180
==========================================
- Hits 72976 72903 -73
- Misses 16645 16898 +253 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
@jajhall will review this sometime today! |
Opt-Mucca
left a comment
There was a problem hiding this comment.
Looks good @jajhall ! I've made some minor comments (assuming the printf statements will all be removed at some later point). Am a big fan of this abstracting away the + / - changes for run times in the middle of the MIP code.
Do you want to keep this on the separate branch for now, or merge it and finish it directly on hmw-mt?
| #endif | ||
| } | ||
|
|
||
| /* |
There was a problem hiding this comment.
Why is this test now commented out?
There was a problem hiding this comment.
This is because it's testing consistency between the subsolver times and the corresponding times in the MIP profiling - which isn't working at present.
I should have a unit test for the sub-solver timing for code coverage
| for (HighsInt thread_ix = 0; thread_ix < HighsInt(num_threads_used); | ||
| thread_ix++) { | ||
| if (totalPct[thread_ix]) { | ||
| ss << highsFormatToString(" %5.1f", totalPct[thread_ix]); |
There was a problem hiding this comment.
That's a great breakdown! (Did not consider printing results per thread)
There was a problem hiding this comment.
Thanks. I view this as a way to see how many threads are being used, and to what activity.
| clock_name.c_str()); | ||
| } | ||
| mip_clocks.timer_pointer_->stop(highs_timer_clock); | ||
| HighsInt local_thread_id = 0; // highs::parallel::thread_num(); |
There was a problem hiding this comment.
Sorry, there's a lot of incomplete code for the MIP profiling
Since I'm on the right track, I'll improve let's merge it. I'll do the MIP profiling later on a separate branch |
The sub-solver timers - sub-MIPs, and LP solves (primal/dual simplex with/without basis and IPM) - are now multi-threaded.
They are now (necessarily) built on common memory for recording sub-solver timing data across all threads that's passed down via a pointer. Hence the calls to
Highs::setGlobalSubSolverCallTimewhenever a new Highs instance is created - either explicitly, or by creating a HighsLpRelaxation instance.I had to develop the multi-threaded sub-solver timers in a branch
thread-mip-timerof latest, and then merge them intohmw-mt-timer- which is a branch of the most recenthmw-mt.This PR merges
hmw-mt-timerintohmw-mtso that @Opt-Mucca can see what's changed in the MIP solver. Of course, this does mean that a whole bunch of changes inlatestare merged in, too, but that's not a bad thing!The changes in
highs/mipare mainly simplifications of what was there before - when sub-solver data from one level was added in to data at the higher level. All that has gone now that common memory is passed aroundIn the course of this, I created
Highs::initializeGlobalScheduler();to callhighs::parallel::initialize_scheduler(this->options_.threads);(and perform some subsequent error checking and logging) rather than do it with duplicated code in two places. I also needed to add my own stuff.Currently the sub-solver timing data are always logged - for ease of development. Normally it is dependent on
this->options_.log_dev_level > 0The more detailed timing of MIP computational components will be done the same way, but I wanted to get this working first.