Safe Haskell | None |
---|---|
Language | Haskell2010 |
Multicore imperative code.
Synopsis
- type Program = Functions Multicore
- data Multicore
- type MCCode = Code Multicore
- data Scheduling
- data SchedulerInfo = SchedulerInfo {}
- data AtomicOp
- = AtomicAdd IntType VName VName (Count Elements (TExp Int32)) Exp
- | AtomicSub IntType VName VName (Count Elements (TExp Int32)) Exp
- | AtomicAnd IntType VName VName (Count Elements (TExp Int32)) Exp
- | AtomicOr IntType VName VName (Count Elements (TExp Int32)) Exp
- | AtomicXor IntType VName VName (Count Elements (TExp Int32)) Exp
- | AtomicXchg PrimType VName VName (Count Elements (TExp Int32)) Exp
- | AtomicCmpXchg PrimType VName VName (Count Elements (TExp Int32)) VName Exp
- newtype ParallelTask = ParallelTask (Code Multicore)
- module Futhark.CodeGen.ImpCode
Documentation
A multicore operation.
SegOp String [Param] ParallelTask (Maybe ParallelTask) [Param] SchedulerInfo | |
ParLoop String (Code Multicore) [Param] | |
GetLoopBounds VName VName | Retrieve inclusive start and exclusive end indexes of the
chunk we are supposed to be executing. Only valid immediately
inside a |
GetTaskId VName | Retrieve the task ID that is currently executing. Only valid
immediately inside a |
GetNumTasks VName | Retrieve the number of subtasks to execute. Only valid
immediately inside a |
Atomic AtomicOp |
data Scheduling Source #
Whether the Scheduler should schedule the tasks as Dynamic or it is restainted to Static
Instances
Pretty Scheduling Source # | |
Defined in Futhark.CodeGen.ImpCode.Multicore |
data SchedulerInfo Source #
Information about parallel work that is do be done. This is passed to the scheduler to help it make scheduling decisions.
SchedulerInfo | |
|
Instances
Pretty SchedulerInfo Source # | |
Defined in Futhark.CodeGen.ImpCode.Multicore ppr :: SchedulerInfo -> Doc # pprPrec :: Int -> SchedulerInfo -> Doc # pprList :: [SchedulerInfo] -> Doc # | |
FreeIn SchedulerInfo Source # | |
Defined in Futhark.CodeGen.ImpCode.Multicore freeIn' :: SchedulerInfo -> FV Source # |
Atomic operations return the value stored before the update.
This old value is stored in the first VName
. The second VName
is the memory block to update. The Exp
is the new value.
newtype ParallelTask Source #
A task for a SegOp
.
Instances
Pretty ParallelTask Source # | |
Defined in Futhark.CodeGen.ImpCode.Multicore ppr :: ParallelTask -> Doc # pprPrec :: Int -> ParallelTask -> Doc # pprList :: [ParallelTask] -> Doc # | |
FreeIn ParallelTask Source # | |
Defined in Futhark.CodeGen.ImpCode.Multicore freeIn' :: ParallelTask -> FV Source # |
module Futhark.CodeGen.ImpCode