Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BPF? #1015

Closed
ghost opened this issue Apr 1, 2020 · 4 comments
Closed

BPF? #1015

ghost opened this issue Apr 1, 2020 · 4 comments

Comments

@ghost
Copy link

ghost commented Apr 1, 2020

I watched the video Netflix talks about Extended BPF: A new software type
where Brendan Gregg mentions that new languages will be designed to target BPF.
It made me wonder if tinygo would be a good candidate to target BPF. I see LLVM can target BPF. The first question is, conceptually, could you see it as part of this project, or would it be better to have a separate project that solely targeted BPF?

@aykevl
Copy link
Member

aykevl commented Apr 1, 2020

I know very little about BPF, apart from that it is fairly limited. It might be able to port TinyGo to it, but there will be limitations. How severe those limitations are mainly depend on whether it is possible to have a heap.

TinyGo has many targets (some of which are highly experimental) so if you get it to work on BPF it would be fine to include it as part of this project.

@ghost
Copy link
Author

ghost commented Apr 1, 2020

I see this project:
https://github.com/iovisor/gobpf
I need to dig deeper to understand motivations for one over the other.
I think targeting BPF is not necessarily a resource constrained environment, but concerns would be around introducing latency in certain cases. I'll continue to research but wanted to throw the idea on the table. I'll close this issue, unless I find something compelling or someone else comments

@ghost ghost closed this as completed Apr 1, 2020
@aykevl
Copy link
Member

aykevl commented Apr 1, 2020

I believe gobpf is a very different project. It seems to concern itself mainly with loading, running (and compiling?) BPF programs whereas TinyGo is a compiler that could potentially add support for eBPF as a backend (but running those eBPF programs would be out of scope except for testing).

@ghost
Copy link
Author

ghost commented Apr 2, 2020

Ok, got it.
This document helped me understand a little better:
https://www.phoronix.com/scan.php?page=news_item&px=LLVM-BPF-VM-Backend-Lands

I think my initial intuition that the BPF in-kernel virtual machine is a tiny environment to target, and maybe tinygo could support it as a backend, isn't totally nuts. It would be an interesting experiment.

@ghost ghost reopened this Apr 2, 2020
@ghost ghost closed this as completed Apr 2, 2020
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant