Class MachiningParallelProc
- Namespace
- Hi.MachiningProcs
- Assembly
- HiMech.dll
The step pipeline of a MachiningActRunner (play-core migration P17): the shell thread freezes every
built step into one machining_pipeline_step_in_t and submits it to the native pool of core.dll (t1 sweep,
t2 subtraction, t3 force on std::thread workers; P16's machining_pipeline.hiapi.cpp behind the P15
contract), and one pump thread of this class polls the completed records back in submit order and runs the
sequential stage (t4: the thermal chain over the managed SeqPhysicsState, the step, the events, the
consignment) as the seq worker ran it before. The four Hi.Parallels schedulers of the TPL pipeline are gone
from the play path. What crosses, when and on which thread is the contract of
CppCore/inc/mech/machining/machining_pipeline.hiapi.h (revision 2).
The public shape is kept: RunStep(int, double, double, SpindleDirection, CoolantMode, TimeSpan, TimeSpan, double, ISentenceCarrier, Action<MachiningStep>, StepTaskBundle, CollidedKeyPair[], CancellationToken, IMachiningService, StepDiagnosticProgress, StepScopedProgress) answers a MachiningParallelProc.StepTaskBundle whose three tasks the pump
completes (Hi.MachiningProcs.MachiningParallelProc.StepTaskBundle.StepSubstractionTask and Hi.MachiningProcs.MachiningParallelProc.StepTaskBundle.StepMillingPhysicsStepTask
before the sequential stage, D-19; Hi.MachiningProcs.MachiningParallelProc.StepTaskBundle.PostSeqPhysicsTask with the published step), the
step index is the strip position's by construction (the position is added inside the submit lock and the record's
index is overwritten with its index before the step is built, P15 R5 / P17-4), the deflection reader waits on the
pipeline (__wait_force) or reads the facade of a retired step (R3), and WaitAll() drains the pool
and the pump before the writer.
public class MachiningParallelProc : IDisposable
- Inheritance
-
MachiningParallelProc
- Implements
- Inherited Members
- Extension Methods
Constructors
MachiningParallelProc(MachiningActRunner)
Initializes a new instance of the MachiningParallelProc class: the worker counts by today's formulas
(P15 R7: sweep = max(PC / 3, 1) with the processor-count override; force = clamp(Cap − sweep − 3, 1, 3)
with Cap the capacity a List<Action>(Environment.ProcessorCount) had after sweep adds – the
retired starter's quirk, kept for the bench's comparability), the depths 120 / 3840, the priorities Lowest /
BelowNormal / Lowest, the pipeline started and the pump begun.
public MachiningParallelProc(MachiningActRunner millingActRunner)
Parameters
millingActRunnerMachiningActRunnerThe machining act runner to manage milling operations.
Properties
MachiningActRunner
Gets the machining act runner that manages the milling operations.
public MachiningActRunner MachiningActRunner { get; }
Property Value
Methods
CloseLeftOverPipelines()
Internal Use Only. LocalApp.AppEnd's first step: every pipeline left alive in the process is closed,
its pump joined or the closed pipeline polled to empty on the calling thread (one poller after a close),
drained and deleted – before the background tree disposals are drained, so that no pool thread is inside
core.dll at exit().
public static void CloseLeftOverPipelines()
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
public void Dispose()
Dispose(bool)
Releases the pipeline (P15 R6's DISPOSE order): its own park released (a reached park on a pipeline its owner
disposes has nothing else to release it), submits refused, today's WaitAll() (every in-flight live
step published), __close, the pump stopped on closed_and_empty, the in-flight callers at 0, the
cancel registrations disposed, __delete. Before the tree's dispose and before LocalApp.AppEnd.
protected virtual void Dispose(bool disposing)
Parameters
disposingboolTrue to release both managed and unmanaged resources; false to release only unmanaged resources.
WaitAll()
Waits for every submitted step to be published: the pool drained (__drain, never from the pump), the
pump idle with nothing complete and unpolled (the idle protocol), then the consignment writer.
public void WaitAll()
Exceptions
- InvalidOperationException
Called on the pump thread.