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

Re-enable ALU32 for sBPFv1 #104

Open
2 tasks
ripatel-fd opened this issue Jul 4, 2024 · 1 comment
Open
2 tasks

Re-enable ALU32 for sBPFv1 #104

ripatel-fd opened this issue Jul 4, 2024 · 1 comment

Comments

@ripatel-fd
Copy link

The sBPFv1 instruction set features a 32-bit ALU instruction class.
The SBF LLVM target currently doesn't make use of it (the ALU32 feature is not enabled for the sBPFv1 target).

Allowing the compiler to generate 32-bit ALU instructions has potential performance benefits:

  • The compiled code currently has to emulate wraparound behavior when using 32-bit integer types.
  • On x86_64, instructions with 32-bit operands are typically shorter than their 64-bit counterparts, which could lead to improved instruction fetch performance when using a JIT compiler.

There are a few problems:

@LucasSte
Copy link
Collaborator

LucasSte commented Dec 6, 2024

Not SBPFv1, but I fixed this for SBPFv2: #116

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

2 participants