This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <cstddef> /* NULL */ | |
#include <metis.h> | |
#include <iostream> | |
// Install metis from: | |
// http://glaros.dtc.umn.edu/gkhome/fetch/sw/metis/metis-5.1.0.tar.gz | |
// Build with | |
// g++ metis.cc -lmetis |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <vector> | |
#include <iostream> | |
#include <algorithm> | |
#include <iterator> | |
template<typename T> | |
struct Scan { | |
T value; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# CMAKE FILE to separatly compile cuda and c++ files | |
# with the c++11 standard | |
# | |
# | |
# Folder structure: | |
# | |
# | | |
# +--main.cpp (with C++11 content) | |
# +--include/ | |
# | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> /* std::cout, std::endl */ | |
#include <type_traits> /* std::enable_if */ | |
// SFINAE test | |
template <typename T> | |
class has_extendedFoo { | |
typedef char one; | |
typedef long two; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
./bootstrap --prefix=$HOME | |
./b2 link=shared runtime-link=shared threading=multi,single variant=release debug-symbols=on toolset=gcc -a -q -j3 --layout=versioned architecture=power host-os=linux stage | |
./b2 link=shared runtime-link=shared threading=multi,single variant=release debug-symbols=on toolset=gcc -q -j3 --layout=versioned architecture=power host-os=linux install | |
# --without-iostreams | |
# for xlc: toolset=vacpp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env sh | |
git clone https://github.com/psychocoderHPC/picongpu-alpaka.git | |
cd picongpu-alpaka | |
git checkout topic-cupla | |
cd .. | |
git clone https://github.com/psychocoderHPC/alpaka.git | |
cd alpaka | |
git checkout topic-picongpu-alpaka |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env sh | |
# Intel tutorial: https://software.intel.com/en-us/articles/building-a-native-application-for-intel-xeon-phi-coprocessors | |
# Load modules | |
module load intel/2016.2.181 | |
module load cmake/3.3.1 | |
module load boost/1.60.0-intel2016.2.181-intelmpi5.1-knc | |
module load gcc/4.9.3 # gives hints to icc where to find libstdc++ | |
# Load some magic numbers |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env sh | |
# Create paths | |
cd ~ | |
mkdir projects | |
cd projects | |
# Load modules | |
module purge | |
module load gcc/4.9.2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env sh | |
# Init paths | |
cd ~ | |
mkdir -p projects | |
cd projects | |
# Load modules | |
module load git | |
module load intel/2016.2.181 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Heavily cribbed from the equivalent NixOS login script. | |
# This should work better with multi-user nix setups. | |
export NIXPKGS_CONFIG="/etc/nix/nixpkgs-config.nix" | |
export NIX_OTHER_STORES="/run/nix/remote-stores/*/nix" | |
export NIX_USER_PROFILE_DIR="/nix/var/nix/profiles/per-user/$USER" | |
export NIX_PROFILES="/nix/var/nix/profiles/default $HOME/.nix-profile" | |
export NIX_PATH="/nix/var/nix/profiles/per-user/root/channels" | |
export PATH="$HOME/.nix-profile/bin:$HOME/.nix-profile/sbin:/nix/var/nix/profiles/default/bin:/nix/var/nix/profiles/default/sbin:$PATH" |
OlderNewer