MCPcopy Create free account
hub / github.com/SakuraEngine/SakuraEngine / cancel_

Method cancel_

modules/engine/runtime/src/io/common/io_runner.cpp:344–361  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

342}
343
344bool RunnerBase::cancel_(IIORequest* rq, SkrAsyncServicePriority priority) SKR_NOEXCEPT
345{
346 if (auto pComp = io_component<IOStatusComponent>(rq))
347 {
348 pComp->setStatus(SKR_IO_STAGE_CANCELLED);
349 if (pComp->needPollFinish())
350 {
351 finish_queues[priority].enqueue(rq);
352 pComp->setFinishStep(SKR_ASYNC_IO_FINISH_STEP_WAIT_CALLBACK_POLLING);
353 }
354 else
355 {
356 pComp->setFinishStep(SKR_ASYNC_IO_FINISH_STEP_DONE);
357 }
358 skr_atomic64_add_relaxed(&processing_request_counts[priority], -1);
359 }
360 return true;
361}
362
363bool RunnerBase::complete_(IIORequest* rq, SkrAsyncServicePriority priority) SKR_NOEXCEPT
364{

Callers

nothing calls this directly

Calls 3

skr_atomic64_add_relaxedFunction · 0.85
setStatusMethod · 0.45
enqueueMethod · 0.45

Tested by

no test coverage detected