Coder Social home page Coder Social logo

odos's Introduction

Setup

  1. Setup environment variables for building and installation of LLVM
export PREFIX=/path/to/install/dir/
export BUILDDIR=/path/to/build/dir/
  1. Compile LLVM
cmake -S llvm-project/llvm                          \
      -B $BUILDDIR                                  \
      -DCMAKE_INSTALL_PREFIX="$PREFIX"              \
      -DCMAKE_BUILD_TYPE=Release                    \
      -DCMAKE_C_COMPILER="`which clang`"            \
      -DCMAKE_CXX_COMPILER="`which clang++`"        \
      -DCMAKE_EXE_LINKER_FLAGS="$LDFLAGS"           \
      -DLLVM_BUILD_UTILS=OFF                        \
      -DLLVM_ENABLE_PROJECTS="clang"                \
      -DGCC_INSTALL_PREFIX="/usr"                   \
      -DCLANG_ENABLE_ARCMT=OFF                      \
      -DCLANG_ENABLE_STATIC_ANALYZER=OFF

cd $BUILDDIR && make -j install
  1. Setup environment variables for building and installation of OpenMP preferably use the same installation directory and different build directory this time
export PREFIX=/path/to/install/dir/
export BUILDDIR=/path/to/build/dir/
  1. Compile OpenMP
cmake -S llvm-project/openmp                        \
      -B $BUILDDIR                                  \
      -DLLVM_ROOT="$PREFIX"                         \
      -DCMAKE_INSTALL_PREFIX="$PREFIX"              \
      -DCMAKE_BUILD_TYPE=Release                    \
      -DCMAKE_C_COMPILER="$PREFIX/bin/clang"        \
      -DCMAKE_CXX_COMPILER="$PREFIX/bin/clang++"    \
      -DCMAKE_EXE_LINKER_FLAGS="$LDFLAGS"           \
      -DCMAKE_EXPORT_COMPILE_COMMANDS=ON            \
      -DOPENMP_ENABLE_LIBOMPTARGET_PROFILING=OFF    \
      -DLIBOMP_HAVE_OMPT_SUPPORT=OFF                \
      -DLIBOMP_INSTALL_ALIASES=OFF                  \
      -DLIBOMPTARGET_ENABLE_DEBUG=OFF               \
      -DLLVM_BUILD_TOOLS=ON                         \
      -DLLVM_ENABLE_RUNTIMES=openmp                 \
      -DDOCA_PATH=/path/to/tools/doca/2.0.2/opt/mellanox/doca

cd $BUILDDIR && make -j install
  1. Compile the DOCA OpenMP Service within DPU: llvm-project/openmp/libomptarget/toos/docaservice/

Run

  1. Run DOCA OpenMP Service on BlueField DPU
  2. Compile application on host
clang -fopenmp -fopenmp-targets=aarch64-unknown-linux ./app.c -o app
  1. Run
./app

Note: please make sure that DOCA libraries are included in LD_LIBRARY_PATH. This project supportes DOCA v2.0.2

#Citation

If you find this software useful for your research or project, we kindly request that you cite the following paper:

M. Usman, S.Iserte, R. Ferrer, and A. J. Peña, "DPU Offloading Programming with the OpenMP API", in LLVM-HPC23 held in conjunction with SC, Denver, Colorado (USA), Nov. 2023.

Please make sure to appropriately acknowledge and cite the original paper in your work. Proper citation helps to give credit to the authors and supports the research community.

By citing the paper, you contribute to the acknowledgment of the original work and allow others to find the source for further reference. We appreciate your cooperation in citing the paper and hope that it has been valuable to your project or research.

#Contact

[email protected]

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.