Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
I
iTasks-SDK
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
73
Issues
73
List
Boards
Labels
Service Desk
Milestones
Merge Requests
6
Merge Requests
6
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
clean-and-itasks
iTasks-SDK
Commits
0ad2624c
Commit
0ad2624c
authored
Jul 04, 2018
by
Steffen Michels
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove debug code
parent
05c564fd
Pipeline
#12649
passed with stage
in 2 minutes and 58 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
8 deletions
+3
-8
Libraries/iTasks/Internal/TaskEval.icl
Libraries/iTasks/Internal/TaskEval.icl
+3
-8
No files found.
Libraries/iTasks/Internal/TaskEval.icl
View file @
0ad2624c
...
...
@@ -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
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment