Files
Etienne PerotandgVisor bot 80ef8a68d9 bpf: Remove Input interface and simply use bytes as the input.
This removes the interface indirection from BPF evaluation, which is
a very hot path (runs for every application syscall for seccomp'd containers)
and simplifies the code in general.

```
            │   initial   │         hey_look_no_interfaces         │
            │   sec/op    │   sec/op     vs base                   │
Interpreter   26.31n ± 0%   21.12n ± 0%  -19.73% (p=0.000 n=21+20)
```

PiperOrigin-RevId: 576375947
2023-10-24 20:47:59 -07:00

46 lines
873 B
Python

load("//tools:defs.bzl", "bzl_library", "go_binary", "go_library")
package(
default_applicable_licenses = ["//:license"],
licenses = ["notice"],
)
go_library(
name = "secbench",
testonly = 1,
srcs = ["secbench.go"],
data = [
":runner",
],
visibility = [
"//:sandbox",
],
deps = [
"//pkg/abi/linux",
"//pkg/bpf",
"//pkg/seccomp",
"//pkg/test/testutil",
"//test/secbench/secbenchdef",
"@org_golang_x_sys//unix:go_default_library",
],
)
go_binary(
name = "runner",
testonly = 1,
srcs = ["runner.go"],
deps = [
"//pkg/abi/linux",
"//pkg/bpf",
"//pkg/gohacks",
"//pkg/seccomp",
"//test/secbench/secbenchdef",
],
)
bzl_library(
name = "defs",
srcs = ["defs.bzl"],
deps = ["//tools:defs_bzl"],
)