GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - faasm/examples: Example applications and libraries cross-compiled to WebAssembly for Faasm.

BranchesTags
Open more actions menu

Latest commit

 

History

43 Commits
43 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
bin
bin
 
 
cpp @ fc018f1
cpp @ fc018f1
 
 
data
data
 
 
docker
docker
 
 
examples
examples
 
 
func
func
 
 
python @ b0e84ec
python @ b0e84ec
 
 
tasks
tasks
 
 
.gitignore
.gitignore
 
 
.gitmodules
.gitmodules
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
docker-compose.yml
docker-compose.yml
 
 
pyproject.toml
pyproject.toml
 
 
requirements.txt
requirements.txt
 
 

Repository files navigation

Example Applications for Faasm

This repository contains a list of applications and libraries that have been cross-compiled to WebAssembly for their use with Faasm.

WARNING: examples listed here have worked at some point in time. The fact that they are listed here does not mean that they still run, or that they are supported in any way.

Quick Start

To cross-compile any of the supported applications for its usage with Faasm, you must first start the build client:

source ./bin/workon.sh
inv cli build

Inside the build client, you can list the available tasks, and cross-compile any of the supported libraries/applications:

inv -l
inv lammps [--clean]

You can access the generated WASM file both from inside and outside the build client container.

# Outside the container
ls ./dev/faasm-local/wasm

# For LAMMPS
file ./dev/faasm-local/wasm/lammps/main/function.wasm

This WASM file is ready to be uploaded to a Faasm cluster using the HTTP API.

List of examples

Project Name WAVM WAMR WAMR + SGX
FFmpeg ✅ ✅ ❌
Kernels ✅ ❌ ❌
LAMMPS ✅ ✅ ❌
libpng ✅ ✅ ❌
ImageMagick ✅ ✅ ❌
LULESH ✅ ❌ ❌
PolyBench/C ✅ ✅ ❌
Tensorflow ✅ ✅ ❌

Bumping C++, Python, or Faasm's version

This repository depends on Faasm's toolchain repos (C++, and Python) and the Faasm runtime. As a consequence, it is versioned with the versions of the previous.

If you want to upgrade the Python or C++ tag, you must update the submodule and the files that track either version. You can do:

cd cpp
git pull origin main
cd ..
inv git.bump cpp

Similarly, for Faasm you can just do:

inv git.bump faasm [--ver=<specific_version>]

Then, tag the new version and re-build the docker images:

inv git.tag
inv docker.build -c build -c run --nocache --push

Adding a new application

To add a new application, you first need to cross-compile it to WebAssembly. You can check the tasks/ folder for examples of how we do it for existing applications. Most importantly, you will have to inidicate the right sysroot, and pass the environment variables that we read from faasmtools.

Once the application is cross-compiled, you must make it run with Faasm. The tests in GHA only test integration with the WAVM runtime in Faasm, but if you need to pick another one for a very specific reason, it can also be tested.

About

Example applications and libraries cross-compiled to WebAssembly for Faasm.

Resources

Readme
Apache-2.0 license
Activity
Custom properties

Stars

4 stars

Watchers

0 watching

Forks

2 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.