mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* hardening and other opts in kernel config used for benchmarking?
@ 2023-08-08 15:25 Mateusz Guzik
  2023-08-10  5:52 ` Yin Fengwei
  0 siblings, 1 reply; 2+ messages in thread
From: Mateusz Guzik @ 2023-08-08 15:25 UTC (permalink / raw)
  To: ying.huang, feng.tang, fengwei.yin
  Cc: oe-lkp, lkp, linux-kernel, Linus Torvalds, Christian Brauner

Hello,

I have no idea who should be in To: or Cc:, I grabbed names from an
e-mail I got regarding one of previous changes.

Recently I benchmarked a change which added unconditional file
position locking and found a minor regression from it (with profiler
output to justify it):
https://lore.kernel.org/linux-fsdevel/CAHk-=whJtLkYwEFTS9LcRiMjSqq_xswDeXo7hYNWT0Em6nL4Sw@mail.gmail.com/T/#m7c0cd6e913c6295732daea3c88f502bd4724ffb3

However, according to Christian the change was benchmarked by your
machinery and no difference was found.

I briefly poked around and found that used configs have:
CONFIG_RANDOMIZE_KSTACK_OFFSET=y

This is an optional and very expensive hardening feature, my question
is if it was enabled on purpose. The cost comes from adding rdtsc to
every syscall.

Looking at the rest of the config you have a mixed bag (e.g., hardened
usercopy but *no* init_on_alloc) so I genuinely don't know.

Given the high cost of the opt I would suggest removing it, as it
avoidably muddles the waters for single-threaded changes (one way or
the other -- slowdowns can hide and speed ups go unnoticed).

I did not review the whole config.

Any comments? :)

Thanks,
-- 
Mateusz Guzik <mjguzik gmail.com>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-08-10  5:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-08 15:25 hardening and other opts in kernel config used for benchmarking? Mateusz Guzik
2023-08-10  5:52 ` Yin Fengwei

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®