Home
Research
Papers
Posters
Manuals
Talks
Download
People
Help
Internal
C
HARM++
Programming Language Manual
Previous:
2.3 Entities in CHARM++
Up:
The CHARM++ Programming Language
Next:
3.1 Modules
3
The C
HARM++
Language
Subsections
3
.
1
Modules
3
.
1
.
1
Structure of a C
HARM++
Program
3
.
1
.
2
Functions in the ``decl.h'' and ``def.h'' files
3
.
2
Entry Methods
3
.
2
.
1
Entry Method Attributes
3
.
3
Parameter Marshalling
3
.
3
.
1
Marshalling User-Defined Structures and Classes
3
.
4
Messages
3
.
4
.
1
Message Creation and Deletion
3
.
4
.
2
Messages with Variable Length Arrays
3
.
4
.
3
Message Packing
3
.
4
.
4
Custom Packed Messages
3
.
4
.
5
Immediate Messages
3
.
5
Delivery Order
3
.
5
.
1
Queueing Strategies
3
.
5
.
2
Prioritized Execution
3
.
5
.
3
Skipping the Queue
3
.
6
Chare Objects
3
.
6
.
1
Chare Creation
3
.
6
.
2
Method Invocation on Chares
3
.
6
.
3
Local Access
3
.
7
Read-only Variables, Messages and Arrays
3
.
8
Basic Arrays
3
.
8
.
1
Declaring a 1D Array
3
.
8
.
2
Creating a Simple Array
3
.
8
.
3
Messages
3
.
8
.
4
Broadcasts
3
.
8
.
5
Reductions on Chare Arrays
3
.
8
.
6
Destroying Arrays
3
.
9
Advanced Arrays
3
.
9
.
1
Declaring Multidimensional, or User-defined Index Arrays
3
.
9
.
2
Advanced Array Creation
3
.
9
.
3
Advanced Array Creation: CkArrayOptions
3
.
9
.
4
Advanced Array Creation: Map Object
3
.
9
.
5
Advanced Array Creation: Initial Elements
3
.
9
.
6
Advanced Array Creation: Bound Arrays
3
.
9
.
7
Advanced Array Creation: Dynamic Insertion
3
.
9
.
8
Advanced Array Creation: Demand Creation
3
.
9
.
9
User-defined array index type
3
.
9
.
10
Migratable Array Elements
3
.
9
.
11
Load Balancing Chare Arrays
3
.
9
.
12
Local Access
3
.
9
.
13
Array Section
3
.
9
.
13
.
1
Array Section Reduction
3
.
9
.
13
.
2
Array section multicast/reduction when migration happens
3
.
9
.
13
.
3
Cross Array Sections
3
.
10
Group Objects
3
.
10
.
1
Group Creation
3
.
10
.
2
Method Invocation on Groups
3
.
11
NodeGroup Objects
3
.
11
.
1
Method Invocation on NodeGroups
3
.
12
Load Balancing
3
.
12
.
1
Measurement-based Object Migration Strategies
3
.
12
.
2
Available Load Balancing Strategies
3
.
12
.
3
Load Balancing Chare Arrays
3
.
12
.
4
Migrating objects
3
.
12
.
5
Other utility functions
3
.
12
.
6
Compiler and run-time options to use load balancing module
3
.
12
.
7
Load Balancing Simulation
3
.
12
.
8
Future load predictor
3
.
12
.
9
Seed load balancers - load balancing Chares at creation time
3
.
12
.
10
Simple Load Balancer Usage Example - Automatic with Sync LB
3
.
13
Advanced Load Balancing
3
.
13
.
1
Control CPU Load Statistics
3
.
13
.
2
Model-based Load Balancing
3
.
13
.
3
Writing a communication-aware load balancing strategy
3
.
13
.
4
Adding a load balancer to Charm++
3
.
13
.
5
Understand Load Balancing Database Data Structure
3
.
14
Futures
3
.
15
Quiescence Detection
3
.
15
.
1
Completion Detection
3
.
16
Reductions
3
.
16
.
1
Reduction Clients
3
.
16
.
2
Typed Reductions
3
.
16
.
3
Built-in Reduction Types
3
.
16
.
4
Defining a New Reduction Type
3
.
17
Callbacks
3
.
17
.
1
Client Interface
3
.
17
.
2
Library Interface
3
.
18
PUP
3
.
18
.
1
PUP contract
3
.
18
.
1
.
1
PUP operator
3
.
18
.
1
.
2
PUP as bytes
3
.
18
.
1
.
3
PUP overhead
3
.
18
.
1
.
4
PUP structured dagger
3
.
18
.
1
.
5
PUP modes
3
.
18
.
2
Life Cycle
3
.
18
.
3
Dynamic Allocation
3
.
18
.
3
.
1
No allocation
3
.
18
.
3
.
2
Allocation outside pup
3
.
18
.
3
.
3
Allocation during pup
3
.
18
.
3
.
4
Allocatable array
3
.
18
.
3
.
5
NULL object pointer
3
.
18
.
3
.
6
Array of classes
3
.
18
.
3
.
7
Array of pointers to classes
3
.
18
.
4
Subclass allocation via PUP::able
3
.
18
.
5
C and Fortran bindings
3
.
18
.
6
Common PUP::ers
3
.
18
.
7
PUP::seekBlock
3
.
18
.
8
Writing a PUP::er
3
.
19
Terminal I/O
3
.
20
initnode
and
initproc
routines
3
.
21
Other Calls
3
.
22
Delegation
3
.
22
.
1
Client Interface
3
.
22
.
2
Manager Interface
3
.
23
Communication Optimizations Framework
3
.
23
.
1
Using commlib
3
.
23
.
2
Loadbalancing and Migration support
3
.
23
.
3
Compiling User Code
3
.
23
.
4
Supported Operations and Strategies
3
.
23
.
5
Many-to-many Strategies
3
.
23
.
6
Broadcast Strategies
3
.
23
.
7
Section Multicast Strategies
3
.
23
.
8
Streaming Strategies
3
.
23
.
9
Communication Optimization Development
3
.
24
All-to-All
3
.
24
.
1
MeshStreamer
3
.
25
Python scripting language
3
.
25
.
1
The client side
3
.
25
.
2
PythonExecute
3
.
25
.
3
Auto-imported modules
3
.
25
.
4
Iterate mode
3
.
25
.
5
PythonPrint
3
.
25
.
6
PythonFinished
3
.
25
.
7
The server side
3
.
25
.
8
Server
read
and
write
functions
3
.
25
.
9
Server iterator functions
3
.
25
.
10
Server utility functions
3
.
25
.
11
High level scripting
February 12, 2012
Charm Homepage