lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <yt9dee2jzrmc.fsf@linux.ibm.com>
Date:   Wed, 30 Mar 2022 12:01:15 +0200
From:   Sven Schnelle <svens@...ux.ibm.com>
To:     Mark Rutland <mark.rutland@....com>
Cc:     Thomas Gleixner <tglx@...utronix.de>,
        Peter Zijlstra <peterz@...radead.org>,
        Andy Lutomirski <luto@...nel.org>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] entry: fix compile error in
 dynamic_irqentry_exit_cond_resched()

Mark Rutland <mark.rutland@....com> writes:

>> I was wondering whether we can make dynamic_irqentry_exit_cond_resched()
>> static, so it gets inlined. On s390 the compiler generates a branch to
>> that function just to return immediately if the static key isn't enabled.
>> With static it would get inlined, and therefore save one function call.
>> What do you think?
>
> I appreciate that it saves one call, but does that actually matter in practice,
> given this is called only once per interrupt?
>
> I'm not fundamentally opposed to changing it, but doing so would make it
> different from all the other dynamic_*() cases which need the check to be
> out-of-line to avoid bloating the callers, and it's not clear to me that we'd
> gain much by doing so.
>
> FWIW, on arm64 we had some additional conditions we have to check, so we roll
> our own (out-of-line) implementation anyway. So doing something arch-specific
> is also an option.

I didn't measure it, i just noticed it by looking at the generated code.
Given your argument about consistency with the other functions i think
we leave it that way.

Thanks!
Sven

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ