• Home
Name Date Size #Lines LOC

..--

fonts/06-Sep-2024-

texts/06-Sep-2024-35,24034,348

Makefile.amD06-Sep-2024385 2417

README.mdD06-Sep-20241.4 KiB5539

benchmark-font.ccD06-Sep-20248.1 KiB320276

benchmark-map.ccD06-Sep-20242.7 KiB11178

benchmark-ot.ccD06-Sep-20242.1 KiB4534

benchmark-set.ccD06-Sep-20244 KiB152116

benchmark-shape.ccD06-Sep-20244.1 KiB181149

benchmark-subset.ccD06-Sep-20247.6 KiB278228

meson.buildD06-Sep-20241.9 KiB6356

README.md

1# Building and Running
2
3Benchmarks are implemented using [Google Benchmark](https://github.com/google/benchmark).
4
5To build the benchmarks in this directory you need to set the benchmark
6option while configuring the build with meson:
7
8```
9meson build -Dbenchmark=enabled --buildtype=release
10```
11or:
12```
13meson build -Dbenchmark=enabled --buildtype=debugoptimized
14```
15
16
17Then build a specific benchmark binaries with ninja:
18```
19ninja -Cbuild perf/benchmark-set
20```
21or just build the whole project:
22```
23ninja -Cbuild
24```
25
26Finally, to run one of the benchmarks:
27
28```
29./build/perf/benchmark-set
30```
31
32It's possible to filter the benchmarks being run and customize the output
33via flags to the benchmark binary. See the
34[Google Benchmark User Guide](https://github.com/google/benchmark/blob/main/docs/user_guide.md#user-guide) for more details.
35
36# Profiling
37
38Configure the build to include debug information for profiling:
39
40```
41CXXFLAGS="-fno-omit-frame-pointer" meson --reconfigure build -Dbenchmark=enabled --buildtype=debug
42ninja -Cbuild
43```
44
45Then run the benchmark with perf:
46
47```
48perf record -g build/perf/benchmark-subset --benchmark_filter="BM_subset_codepoints/subset_notocjk/100000" --benchmark_repetitions=5
49```
50You probably want to filter to a specific benchmark of interest and set the number of repititions high enough to get a good sampling of profile data.
51
52Finally view the profile with:
53
54perf report
55