View on GitHub


A Compiler-free PGAS Library

Writing Habanero-UPC++ programs

Habanero-UPC++ defines a C++-based interface in the hcupc-spmd.h header file. Just use the include directive in your program to import the interfaces and import the Habanero-UPC++ namespace

#include "hcupc-spmd.h"

Compiling Habanero-UPC++ program

First set the environment variables as mentioned in the README file. A sample Makefile for compiling a Habanero-UPC++ file test.cpp is as shown below:

include $(HABANERO_UPC_INSTALL)/include/hcupc_spmd.mak
all: test

test: test.o
        $(CXX) $(PROJECT_LDFLAGS) -o $@ $^ $(PROJECT_LDLIBS)

test.o: test.cpp
        $(CXX) $(PROJECT_CXXFLAGS) -o $@ -c $<

Executing Habanero-UPC++ program

See the README file in habanero-upc git repository.