diff options
| author | Dante Niewenhuis <d.niewenhuis@hotmail.com> | 2025-03-18 07:26:35 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-03-18 07:26:35 +0100 |
| commit | 97db8e0351b9451ece8fd16c25ca0588ec71a2ab (patch) | |
| tree | e72f32df2b12677e9ae2f9997b226c8da97e56e4 /opendc-simulator/opendc-simulator-compute/src/main/kotlin | |
| parent | 7dc2639a7fcdf51ef789f4af2e3afff11438be6e (diff) | |
Performance updates (#314)
Diffstat (limited to 'opendc-simulator/opendc-simulator-compute/src/main/kotlin')
| -rw-r--r-- | opendc-simulator/opendc-simulator-compute/src/main/kotlin/org/opendc/simulator/compute/Coroutines.kt | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/opendc-simulator/opendc-simulator-compute/src/main/kotlin/org/opendc/simulator/compute/Coroutines.kt b/opendc-simulator/opendc-simulator-compute/src/main/kotlin/org/opendc/simulator/compute/Coroutines.kt index 49baaf48..bbd6feaa 100644 --- a/opendc-simulator/opendc-simulator-compute/src/main/kotlin/org/opendc/simulator/compute/Coroutines.kt +++ b/opendc-simulator/opendc-simulator-compute/src/main/kotlin/org/opendc/simulator/compute/Coroutines.kt @@ -25,8 +25,6 @@ package org.opendc.simulator.compute import kotlinx.coroutines.suspendCancellableCoroutine import org.opendc.simulator.compute.machine.SimMachine import org.opendc.simulator.compute.workload.trace.TraceWorkload -import kotlin.coroutines.resume -import kotlin.coroutines.resumeWithException /** * Run the specified [SimWorkloadNew] on this machine and suspend execution util [workload] has finished. @@ -43,8 +41,8 @@ public suspend fun SimMachine.runWorkload( return suspendCancellableCoroutine { cont -> cont.invokeOnCancellation { this@runWorkload.shutdown() } - startWorkload(workload) { cause -> - if (cause != null) cont.resumeWithException(cause) else cont.resume(Unit) - } +// startWorkload(workload) { cause -> +// if (cause != null) cont.resumeWithException(cause) else cont.resume(Unit) +// } } } |
