Home
Research
Papers
Posters
Manuals
Talks
Download
People
Help
Wiki
Internal
C
HARM++
Programming Language Manual
Up:
Other Manuals
Next:
1 Introduction
The
C
HARM++
Programming Language
Manual
1
Introduction
1
.
1
Overview
1
.
2
History
2
C
HARM++
Overview
2
.
1
Proxies and Handles
2
.
2
C
HARM++
Execution Model
2
.
3
Entities in C
HARM++
programs
2
.
3
.
1
Sequential Objects
2
.
3
.
2
Messages
2
.
3
.
3
Chares
2
.
3
.
4
Chare Arrays
2
.
3
.
5
Chare Groups
2
.
3
.
6
Chare Nodegroups
3
The C
HARM++
Language
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
Prioritized Execution
3
.
4
.
6
Immediate Messages
3
.
5
Chare Objects
3
.
5
.
1
Chare Creation
3
.
5
.
2
Method Invocation on Chares
3
.
5
.
3
Local Access
3
.
6
Read-only Variables, Messages and Arrays
3
.
7
Basic Arrays
3
.
7
.
1
Declaring a 1D Array
3
.
7
.
2
Creating a Simple Array
3
.
7
.
3
Messages
3
.
7
.
4
Broadcasts
3
.
7
.
5
Reductions on Chare Arrays
3
.
7
.
6
Destroying Arrays
3
.
8
Advanced Arrays
3
.
8
.
1
Declaring Multidimensional, or User-defined Index Arrays
3
.
8
.
2
Advanced Array Creation
3
.
8
.
3
Advanced Array Creation: CkArrayOptions
3
.
8
.
4
Advanced Array Creation: Map Object
3
.
8
.
5
Advanced Array Creation: Initial Elements
3
.
8
.
6
Advanced Array Creation: Bound Arrays
3
.
8
.
7
Advanced Array Creation: Dynamic Insertion
3
.
8
.
8
Advanced Array Creation: Demand Creation
3
.
8
.
9
User-defined array index type
3
.
8
.
10
Migratable Array Elements
3
.
8
.
11
Load Balancing Chare Arrays
3
.
8
.
12
Local Access
3
.
8
.
13
Array Section
3
.
8
.
13
.
1
Array Section Reduction
3
.
8
.
13
.
2
Array section multicast/reduction when migration happens
3
.
9
Group Objects
3
.
9
.
1
Group Creation
3
.
9
.
2
Method Invocation on Groups
3
.
10
NodeGroup Objects
3
.
10
.
1
Method Invocation on NodeGroups
3
.
11
Load Balancing
3
.
11
.
1
Measurement-based Object Migration Strategies
3
.
11
.
2
Available Load Balancing Strategies
3
.
11
.
3
Load Balancing Chare Arrays
3
.
11
.
4
Migrating objects
3
.
11
.
5
Other utility functions
3
.
11
.
6
Compiler and run-time options to use load balancing module
3
.
11
.
7
Load Balancing Simulation
3
.
11
.
8
Future load predictor
3
.
11
.
9
Seed load balancers - load balancing Chares at creation time
3
.
11
.
10
Simple Load Balancer Usage Example - Automatic with Sync LB
3
.
12
Advanced Load Balancing
3
.
12
.
1
Write a Measurement-based Object Migration Strategy
3
.
12
.
2
Understand Load Balancing Database Data Structure
3
.
13
Quiescence Detection
3
.
14
Reductions
3
.
14
.
1
Reduction Clients
3
.
14
.
2
Built-in Reduction Types
3
.
14
.
3
Defining a New Reduction Type
3
.
15
Callbacks
3
.
15
.
1
Client Interface
3
.
15
.
2
Library Interface
3
.
16
PUP
3
.
16
.
1
PUP contract
3
.
16
.
1
.
1
PUP operator
3
.
16
.
1
.
2
PUP as bytes
3
.
16
.
1
.
3
PUP overhead
3
.
16
.
1
.
4
PUP structured dagger
3
.
16
.
1
.
5
PUP modes
3
.
16
.
2
Life Cycle
3
.
16
.
3
Dynamic Allocation
3
.
16
.
3
.
1
No allocation
3
.
16
.
3
.
2
Allocation outside pup
3
.
16
.
3
.
3
Allocation during pup
3
.
16
.
3
.
4
Allocatable array
3
.
16
.
3
.
5
NULL object pointer
3
.
16
.
3
.
6
Array of classes
3
.
16
.
3
.
7
Array of pointers to classes
3
.
16
.
4
Subclass allocation via PUP::able
3
.
16
.
5
C and Fortran bindings
3
.
16
.
6
Common PUP::ers
3
.
16
.
7
PUP::seekBlock
3
.
16
.
8
Writing a PUP::er
3
.
17
Terminal I/O
3
.
18
initnode
and
initproc
routines
3
.
19
Other Calls
3
.
20
Delegation
3
.
20
.
1
Client Interface
3
.
20
.
2
Manager Interface
3
.
21
Communication Optimizations Framework
3
.
21
.
1
Using commlib
3
.
21
.
2
Loadbalancing and Migration support
3
.
21
.
3
Compiling User Code
3
.
21
.
4
Supported Operations and Strategies
3
.
21
.
5
Many-to-many Strategies
3
.
21
.
6
Broadcast Strategies
3
.
21
.
7
Section Multicast Strategies
3
.
21
.
8
Streaming Strategies
3
.
21
.
9
Communication Optimization Development
3
.
22
Python scripting language
3
.
22
.
1
The client side
3
.
22
.
2
PythonExecute
3
.
22
.
3
Auto-imported modules
3
.
22
.
4
Iterate mode
3
.
22
.
5
PythonPrint
3
.
22
.
6
PythonFinished
3
.
22
.
7
The server side
3
.
22
.
8
Server
read
and
write
functions
3
.
22
.
9
Server iterator functions
3
.
22
.
10
Server utility functions
3
.
22
.
11
High level scripting
4
Inheritance and Templates in Charm++
4
.
1
Chare Inheritance
4
.
2
Inheritance for Messages
4
.
3
Generic Programming Using Templates
5
Checkpoint/Restart
5
.
1
Disk-based Checkpoint/Restart
5
.
1
.
1
Checkpointing
5
.
1
.
2
Restarting
5
.
1
.
3
Choosing What to Save
5
.
2
Double Memory/Disk Checkpoint/Restart
5
.
2
.
1
Checkpointing
5
.
2
.
2
Restarting
5
.
2
.
3
Double in-disk checkpoint/restart
A. Structured Dagger
A..
1
Usage
A..
2
Grammar
A..
2
.
1
Tokens
A..
2
.
2
Grammar in EBNF Form
B. Further Information
B..
1
Related Publications
B..
2
Associated Tools and Libraries
B..
2
.
1
P
ROJECTIONS
B..
3
Contacts
About this document ...
June 29, 2008
Charm Homepage