| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
The process name will be read into the buffer containing
the proc name filepath. We need to reinitialize the buffer
before reading into it.
Change-Id: I67710819c895d3f9e2b0d486ab8a11f29f8318e8
|
|
|
|
|
|
|
|
|
| |
add_tid_to_cgroup was also being used to add threads to
cpusets. Split this into a generic write_tid_to_fd, and
wrap it for cpusets and cgroups. This lets errors align
with what the actual failure is.
Change-Id: I2c5c97117428a33b6a328f73741d3516d4141f78
|
|
|
|
|
|
|
|
| |
If a task only ever touches cgroups, don't initialize
cpusets. This makes logging fails for cpusets much
less spammy.
Change-Id: Iad9c58db68ecd2c2445255bfe5564318064949a5
|
|
|
|
|
|
|
| |
This can help resolve permissions issues for tasks that
want to twiddle the perf bits but don't have permissions.
Change-Id: I6285c5c38224d1fb207cb26229cd7b779a8322ac
|
|
|
|
|
|
|
|
| |
If you compile with cpusets enabled but the permissions are wrong
the behavior becomes no real policy enforced at all. Fix this by
making sched_policy fall back gracefully.
Change-Id: Ife96ca64b991e23232a5bd0d6c21e30a5d16bde8
|
|
|
|
|
|
|
|
|
|
|
| |
system-background can't be opened by most processes, since system-bg is
a privileged cpuset. Remove the log message when it can't be
opened. We'll still log a failure to use the fd if we try to use it
after it can't be opened, which is fine.
bug 26249842
Change-Id: I99f185c51645bc81b6a41732848227c27675cdf7
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
SurfaceFlinger needs some of its threads in the system-background cpuset
and some of its threads (the binder pool) outside of the
system-background cpuset in order to improve UI perf/power
consumption. Remove surfaceflinger from the system-background cpuset in
init.rc and allow a thread to place itself in the system-background
cpuset given enough permissions.
bug 25745866
Change-Id: I85f7e41c5439e6ad7cc2d355e51f5dfb3a0c7088
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If a thread is created while the parent thread is "Background",
then the default timerslack value gets set to the current
timerslack value of the parent (40ms). The default value is
used when transitioning to "Foreground" -- so the effect is that
the timerslack value becomes 40ms regardless of foreground/background.
This does occur intermittently for systemui when creating its
render thread (pretty often on hammerhead and has been seen on
shamu). If this occurs, then some systemui animations like navbar
ripples can wait for up to 40ms to draw a frame when they intended
to wait 3ms -- jank.
This fix is to explicitly set the foreground timerslack to 50us.
A consequence of setting timerslack behind the process' back is
that any custom values for timerslack get lost whenever the thread
has transition between fg/bg.
See Bug: 19398120
Change-Id: Idc259717f62fa2255f8bafbbf88b68c0043f29cf
|
|/
|
|
|
|
| |
bug 21782794
Change-Id: I3b2cf8ae4f3ed0c14f206584ae7fa2b1a1d11ad0
|
|
|
|
|
|
| |
bug 21782794
Change-Id: I249531754fb29442dc3c7434d77dbb103f4220a7
|
|\
| |
| |
| |
| |
| |
| | |
<sched.h>."
* commit 'fae953ebccfabfa500b3ebca93202063c8e3501d':
HAVE_ANDROID_OS implies that you have <pthread.h> and <sched.h>.
|
| |
| |
| |
| | |
Change-Id: Ica7940c00d1d5da9d50711fd138dd459deec9b6d
|
|\ \
| |/
|/|
| |
| |
| |
| | |
lmp-mr1-dev
* commit '33b335495c7b8eea4b9af13a7157cf83cd085129':
Make the default cgroup, the foreground cgroup.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
All kernel services will now be in the same cgroup as
foreground applications. This will now make kernel threads
not implicitly higher priority than android foreground
services.
Bug 17681097
Change-Id: I28e81c7aade50428d5395df86f00ce01c1e7af02
|
|\ \
| |/
|/|
| |
| | |
* commit '3859029a48aa78150fa61eb4988214f8632b33ce':
Remove androidGetTid.
|
| |
| |
| |
| |
| | |
Bug: 17048545
Change-Id: I93cbb2d7bd18d506b5f5f7f262dd9ac0fca053b4
|
| |
| |
| |
| | |
Change-Id: I3a27803d46b5b88a10aa8043a114d780ed685e56
|
| |
| |
| |
| | |
Change-Id: I708da00e36a9da8be9184c451453774be6b78c06
|
|\ \
| |/
| |
| |
| | |
* commit 'a0a461d3b7d85484c10db64f078427a5be3da189':
libcutils: turn on -Werror
|
| |
| |
| |
| |
| |
| | |
- Deal with some -Wunused / -Wunused-variable issues
Change-Id: I28c23fb213382a392ec30935749fb359e072d664
|
| |
| |
| |
| |
| |
| |
| | |
422852ef5c0c2b0b5e031f80f480486df3d185a0 for non-linux hosts.
Change-Id: I00b9c99b9d9d072f19549b3a9970a27e75cd49b7
Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com>
|
|/
|
|
|
| |
Change-Id: Ia998f349129acf4602b767d1ff94839607fdbdbd
Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com>
|
|
|
|
|
|
| |
Bug: 6528015
Change-Id: I6c2658b62442d811b53c6d18476fbd6cd45f9e3f
Signed-off-by: Dima Zavin <dima@android.com>
|
|
|
|
|
|
|
|
|
| |
Adds an apps cgroup which will contain fg tasks. Move the bg group
nested underneath it.
Bug: 6538553
Change-Id: I55279415da625e15a5bb061c2b45fbe7f7a4c047
Signed-off-by: Dima Zavin <dima@android.com>
|
|
|
|
| |
This reverts commit 4df54bc4a85eacfff9c81dc0a7ebf3fd88a99982.
|
|
|
|
|
| |
Bug: 4466013
Change-Id: I5633c841e71a48357bb04cd7ccc02550c17bde22
|
|
|
| |
This reverts commit e1440d81aef58e8b9983ab1f4540dc1fe5e63ab7
|
|
|
|
|
| |
Bug: 4466013
Change-Id: I0d2e915fc550a0ecaccad5e452dd4c87fc878b8b
|
|
|
|
| |
Change-Id: I52c8ea33b9b915fc08546f2ca0b191391f58506b
|
|
|
|
|
|
|
|
| |
Also tid == 0 maps to gettid() on platforms that support it.
This is needed by mediaserver code that was formerly using
the old C++ API.
Change-Id: I8baaa3e42315c9b924cec26b6da01e7cb69e0078
|
|
|
|
|
|
|
| |
This will make it easier to add additional policies (cgroups) if needed.
Also added comments to the sched_policy APIs.
Change-Id: I33ce1cc4deae10983241f7391294b7a512d2c47c
|
|
|
|
| |
Change-Id: I2c563b20197803cafa91214aeff2c06fc0c75580
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Re-use the file descriptor to change the cgroups. There's a fast path
in the kernel for the case where the value's already uncahnged. Also,
this is okay because the kernel ignores the write offset. This is
essentially a ioctl-ish/datagram interface, despite being a fd we're
writing to.
This reduces Dalvik->Dalvik void/void Binder calls on Sapphire from
~1.2 to ~0.8 ms. This is a bit slower than the ~0.7 ms we get
avoiding the write altogether.
strace confirms:
[pid 1557] ioctl(21, 0xc0186201 <unfinished ...>
[pid 1556] <... ioctl resumed> , 0x45399cd0) = 0
[pid 1556] write(22, "1556", 4) = 4
[pid 1556] ioctl(21, 0xc0186201 <unfinished ...>
[pid 1555] <... ioctl resumed> , 0x45299cd0) = 0
[pid 1555] write(22, "1555", 4) = 4
[pid 1555] ioctl(21, 0xc0186201 <unfinished ...>
[pid 1554] <... ioctl resumed> , 0x45199cd0) = 0
[pid 1554] write(22, "1554", 4) = 4
BUG=2660235
Change-Id: Ia9f9e1d5b792eaebc9560f89931faf6df0cf9c0d
|
|
|
|
|
|
|
|
|
|
|
| |
- use static /dev/cpuctl filenames, rather than sprintf() on the fly
- use a custom formatter instead of sprintf() for the tid number
This is a simplified version of Dan's original
Ifc9c81f74fe65f0695ead53b30194bc6adf00da0 to be less risky for Froyo.
Bug: 2660235
Change-Id: I744bbc2ec01fd2569612c814a497df40a933b622
|
|
|
|
|
| |
Change-Id: Id74c6895a8012c5915f2e259339101844de7c085
Signed-off-by: San Mehat <san@google.com>
|
|
|
|
|
|
| |
control groups
Signed-off-by: San Mehat <san@google.com>
|
|
|
|
|
|
| |
move exits on us
Signed-off-by: San Mehat <san@google.com>
|
|
|
|
|
|
| |
threads into the foreground
Signed-off-by: San Mehat <san@google.com>
|
|
|
|
| |
Signed-off-by: San Mehat <san@google.com>
|
|
|
|
| |
Signed-off-by: San Mehat <san@google.com>
|
|
|
|
|
|
|
| |
This introduces a new HAVE_SCHED_H arch define, which is used
to prevent from building sched_policy.c during the Windows SDK.
Change-Id: I3667857a4ae7d6baaf1efd1cd187a5baf91419d8
|
|
|
|
| |
Signed-off-by: San Mehat <san@google.com>
|
|
Also changes the background policy to use SCHED_BATCH. IDLEPRIO
can cause 100% starvation.
Signed-off-by: San Mehat <san@google.com>
|