Mozilla/5.0 (X11; Linux x86_64; rv:83.0) Gecko/20100101 Thunderbird/83.0
The attached patch reinstates the "prefix" optimization
from matchpathcon_init_prefix(), with the SELABEL_OPT_SUBSET equivalent.
The original code was added in:
https://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commitdiff;h=v6.9.89-7-g56e3106e9
and suggests an 8x perf improvement.
However I'm not seeing any perf difference,
and a very quick scan of the selinux source
suggests the option is moot in the presence of compiled contexts.
I'd rather not add back this code if possible.
Could Red Hat folks indicate how useful it is currently,
and if non compiled policies are a practical consideration for install(1).
thanks,
Pádraig