Commit 0ad2624c authored by Steffen Michels's avatar Steffen Michels

remove debug code

parent 05c564fd
Pipeline #12649 passed with stage
in 2 minutes and 58 seconds
......@@ -10,7 +10,7 @@ import iTasks.Internal.Util
from iTasks.WF.Combinators.Core import :: SharedTaskList
from iTasks.WF.Combinators.Core import :: ParallelTaskType(..), :: ParallelTask(..)
from Data.Map as DM import qualified newMap, fromList, toList, get, put, del, mapSize
from Data.Map as DM import qualified newMap, fromList, toList, get, put, del
from Data.Queue import :: Queue (..)
from Data.Queue as DQ import qualified newQueue, enqueue, dequeue, empty
from iTasks.Internal.SDS as SDS import qualified read, write, modify
......@@ -22,10 +22,6 @@ from iTasks.Internal.Tonic.AbsSyn import :: ExprId (..)
derive gEq TIMeta
import StdArray, dynamic_string, StdDebug, Data.GenDiff
derive gDiff TaskTree,Map,LUI,LUIEffectStage,LUINo,TaskId,AttachmentStatus,EditMask,Either,LUIEffects,LUIChanges,JSONNode,UIType,FieldMask,Set,Maybe
gDiff{|DeferredJSON|} x y = gDiff{|*|} (toJSON x) (toJSON y)
mkEvalOpts :: TaskEvalOpts
mkEvalOpts =
{ TaskEvalOpts
......@@ -58,13 +54,12 @@ getNextTaskId iworld=:{current=current=:{TaskEvalState|taskInstance,nextTaskNo}}
= (TaskId taskInstance nextTaskNo, {IWorld|iworld & current = {TaskEvalState|current & nextTaskNo = nextTaskNo + 1}})
processEvents :: !Int *IWorld -> *(!MaybeError TaskException (), !*IWorld)
processEvents max iworld=:{IWorld| memoryShares}
processEvents max iworld
| max <= 0 = (Ok (), iworld)
| otherwise
= case dequeueEvent iworld of
(Nothing,iworld) = (Ok (),iworld)
(Just (instanceNo,event),iworld)
//# iworld = trace_n ("memory shares size " +++ toString (size $ copy_to_string memoryShares) +++ ", num "+++ toString ('DM'.mapSize memoryShares)) iworld
= case evalTaskInstance instanceNo event iworld of
(Ok taskValue,iworld)
= processEvents (max - 1) iworld
......@@ -125,7 +120,7 @@ where
Ok _
//Store updated reduct
# (nextTaskNo,iworld) = getNextTaskNo iworld
# (_,iworld) = 'SDS'.modify (\r -> let x = ((),{TIReduct|r & tree = tree, nextTaskNo = nextTaskNo, nextTaskTime = nextTaskTime + 1}) in x)
# (_,iworld) = 'SDS'.modify (\r -> ((),{TIReduct|r & tree = tree, nextTaskNo = nextTaskNo, nextTaskTime = nextTaskTime + 1}))
(sdsFocus instanceNo taskInstanceReduct) iworld
//FIXME: Don't write the full reduct (all parallel shares are triggered then!)
//Store update value
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment