-
Notifications
You must be signed in to change notification settings - Fork 379
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
100 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
// Copyright 2024 Google LLC | ||
// | ||
// This source code is licensed under the BSD-style license found in the | ||
// LICENSE file in the root directory of this source tree. | ||
|
||
|
||
#include <benchmark/benchmark.h> | ||
#include "bgemm.h" | ||
#include "packw-benchmark.h" | ||
#include "utils.h" | ||
#include "xnnpack/common.h" | ||
#include "xnnpack/hardware-config.h" | ||
#include "xnnpack/packw.h" | ||
|
||
static void qb4_packw(benchmark::State& state, const char* net, | ||
xnn_qb4_packw_gemm_goi_ukernel_fn ukernel, | ||
uint64_t arch_flags, size_t nr, size_t kr, size_t sr, size_t bl) { | ||
benchmark::utils::CheckArchFlags(state, arch_flags); | ||
qb4_packw(state, ukernel, nr, kr, sr, bl); | ||
} | ||
|
||
#define XNN_QB4_UKERNEL(arch_flags, ukernel, nr, kr, sr, bl, kblock, nr_scale, izp) \ | ||
BENCHMARK_CAPTURE_BGEMM(qb4_packw, ukernel##_, ukernel, arch_flags, nr, kr, sr, bl); | ||
|
||
#include "qb4-packw/qb4-packw.h" | ||
|
||
#undef XNN_QB4_UKERNEL | ||
|
||
|
||
#ifndef XNNPACK_BENCHMARK_NO_MAIN | ||
BENCHMARK_MAIN(); | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters