Subject: | LSK feature request |
---|---|
Date: | Tue, 2 Jun 2015 10:26:29 +0000 |
From: | Gaurav Jindal (Gaurav Jindal) <Gaurav.Jindal@spreadtrum.com> |
To: | Alex.Shi@linaro.org <Alex.Shi@linaro.org>, khilman@linaro.org <khilman@linaro.org>, linaro-kernel@lists.linaro.org <linaro-kernel@lists.linaro.org> |
Hi all
Please find the patch
for Save extra cpu cycles in getting slow/fast domain(Commit
ID : 2926ff354657c02ad4e1c453138f8670d031d7c4)
Description:
In present code, it
is compulsory to check if the cpu is in slowest/fastest
domain before calling the functions;
hmp_slower_domain()
and hmp_faster_domain() to get the relative slower/faster
domains.
If the caller calls
without checking, it will give invlaid address which can
result in undefined behavior.
Also in the functions
hmp_select_slower_cpu(),
hmp_select_faster_cpu() and hmp_best_little_cpu(),
extra cpu cycles and
instructions can be saved by changing the flow to get the
relative slower/faster domain. As with this change the
function
hmp_slower_domain()
and hmp_faster_domain() will itself take care of the
condition if the current cpu is in slowest or fastest
domain.
So extra checks
before getting the relative faster/slower domains can be
avoided thus reducing function calls and prevent cpu cycles
thus improving the performance.
Regards
Gaurav Jindal
+91-8800803297
CPCEX ID:
gaurav.j