Page MenuHomePhabricator

[mlir] Add getNumThreads to MLIRContext
ClosedPublic

Authored by Mogball on Dec 23 2021, 5:41 PM.

Details

Summary

Querying threads directly from the thread pool fails if there is no thread pool or if multithreading is not enabled. Returns 1 by default.

Diff Detail

Event Timeline

Mogball created this revision.Dec 23 2021, 5:41 PM
Mogball requested review of this revision.Dec 23 2021, 5:41 PM
mehdi_amini accepted this revision.Dec 23 2021, 5:43 PM
mehdi_amini added inline comments.
mlir/lib/IR/MLIRContext.cpp
522

(see the method below)

This revision is now accepted and ready to land.Dec 23 2021, 5:43 PM
Mogball updated this revision to Diff 396127.Dec 23 2021, 6:02 PM

add assert

This revision was landed with ongoing or failed builds.Dec 23 2021, 6:03 PM
This revision was automatically updated to reflect the committed changes.