/eid-hermes

An open-source eBPF accelerator that can run on QEMU and AWS F1 instances

Primary LanguageC

eid-hermes: An open-source eBPF accelerator for QEMU and AWS F1 instances.

Introduction

This is an open-source Eideticom-led project that explores how eBPF-based accelerators can be used to offload application code from host processors.

This repository contains the source code for an eBPF-based PCIe accelerator design that can be run on AWS F1 servers. As such, anyone can use this project to run said accelerators on the cloud and develop host code (such as drivers and userspace libraries) targetting said accelerators.

Overview

This project consists of four main parts.

QEMU Model

This part of the project will develop and ideally upstream a hermes-based PCIe device model. Prior to upstream this code is hosted in this public fork of QEMU. Some early work on such a model results in this RFC.

AWS F1 Implementation

This part of the project implements an eid-hermes bitstream which can run on an AWS F1 instance. This code will be contained in this repo and will consist mostly of RTL.

Linux Driver

This part of the project implements a Linux driver for eid-hermes and should threfore work for both the QEMU model and the AWS F1 instance noted above. This code is hosted in this repo initially and ideally will be upstreamed into the Linux kernel.

The driver requires kernel version 4.14 or higher.

eBPF Userspace Library

This part of the project implements a userspace library that provides an API whereby applications can offload part of their computation to eBPF-capable devices like eid-hermes. Note that long term this part may span other device types like, for example, NVMe devices and may come under the perview of a standards body like SNIA.

Specification

The specification for eid-hermes is located in Markdown files in the specs folder. The files in that folder are as follows:

Host configuration

An Ansible playbook is provided to install some helper programs, such as pcimem15.

To run it, first install ansible then run:

cd ansible
ansible-playbook hermes.yml -K

Testing

We include unit tests on the tests directory. To run them:

sudo tests/unit_test

You may find the -v (verbose) and -f (failfast) options useful.

Licensing

Where possible the code in this repository is licensed under the Apache License, Version 2.0. This is a permissive license allowing anyone to use this code, even for commercial purposes, if they so wish. Please refer to the full text of the license for more information.

Contributing

Contributions in the form of pull-requests are most welcome. The upstream version of this repo is located at this link. Note that only PGP signed commits will be accepted so please setup PGP signing in order to commit to this project.