benchmarks/syscallbench: a few fixes

PiperOrigin-RevId: 513967221
This commit is contained in:
Andrei Vagin
2023-03-04 00:55:39 -08:00
committed by gVisor bot
parent 5ba34bd1a5
commit 8c6b76defc
2 changed files with 2 additions and 2 deletions
@@ -52,7 +52,7 @@ int main(int argc, char *argv[]) {
{0, 0, 0, 0}};
int option_index = 0;
while ((c = getopt_long(argc, argv, "l:s", long_options, &option_index)) !=
while ((c = getopt_long(argc, argv, "l:s:", long_options, &option_index)) !=
-1) {
switch (c) {
case 'l':
+1 -1
View File
@@ -68,7 +68,7 @@ func BenchmarkSyscallbench(b *testing.B) {
b.Fatalf("run failed with: %v", err)
}
b.Run(name, func(b *testing.B) {
cmd := []string{"syscallbench", fmt.Sprintf("--loops=%d --syscall %d", b.N, tc.syscallArg)}
cmd := []string{"syscallbench", fmt.Sprintf("--loops=%d", b.N), fmt.Sprintf("--syscall=%d", tc.syscallArg)}
b.ResetTimer()
out, err := container.Exec(ctx, dockerutil.ExecOpts{}, cmd...)
if err != nil {