Skip to content

Commit

Permalink
meson.build: enable LTO and -O3 for C schedulers
Browse files Browse the repository at this point in the history
Signed-off-by: John Titor <[email protected]>
  • Loading branch information
JohnRTitor committed Jan 8, 2025
1 parent ce715ba commit 382c879
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions meson.build
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
project('sched_ext schedulers', 'c',
version: '1.0.8',
license: 'GPL-2.0',
meson_version : '>= 1.2.0',)
meson_version : '>= 1.2.0',
default_options : [
'optimization=3',
'b_lto=true',
])

fs = import('fs')

Expand Down Expand Up @@ -247,7 +251,7 @@ if cpu not in arch_dict
endif

sys_incls = run_command(get_sys_incls, bpf_clang, check: true).stdout().splitlines()
bpf_base_cflags = ['-g', '-O2', '-Wall', '-Wno-compare-distinct-pointer-types',
bpf_base_cflags = ['-g', '-O3', '-Wall', '-Wno-compare-distinct-pointer-types',
'-D__TARGET_ARCH_' + arch_dict[cpu], '-mcpu=v3',
'-m@0@-endian'.format(host_machine.endian())] + sys_incls

Expand Down

0 comments on commit 382c879

Please sign in to comment.