1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-02 19:42:14 +00:00
serenity/Userland/Libraries/LibCore
Tom 7e77a2ec40 Everywhere: Improve CPU usage calculation
As threads come and go, we can't simply account for how many time
slices the threads at any given point may have been using. We need to
also account for threads that have since disappeared. This means we
also need to track how many time slices we have expired globally.

However, because this doesn't account for context switches outside of
the system timer tick values may still be under-reported. To solve this
we will need to track more accurate time information on each context
switch.

This also fixes top's cpu usage calculation which was still based on
the number of context switches.

Fixes #6473
2021-07-18 22:08:26 +02:00
..
Account.cpp LibCore: Generate new passwd file by checking pw_name 2021-07-14 08:06:30 +02:00
Account.h LibCore: Add setters for all user account properties 2021-07-14 08:06:30 +02:00
AnonymousBuffer.cpp LibCore: Make Core::AnonymousBuffer moveable 2021-07-07 18:02:43 +02:00
AnonymousBuffer.h LibCore: Make Core::AnonymousBuffer moveable 2021-07-07 18:02:43 +02:00
ArgsParser.cpp LibCore: Remove overly informal language in ArgsParser error message 2021-07-08 01:17:06 +02:00
ArgsParser.h LibCore: Add unsigned option to ArgsParser 2021-07-07 20:05:43 +04:30
CMakeLists.txt AK+LibCore: Remove empty files 2021-03-12 17:38:17 +01:00
Command.cpp LibCore+Everywhere: Move OpenMode out of IODevice 2021-05-12 11:00:45 +01:00
Command.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
ConfigFile.cpp LibCore+Everywhere: Move OpenMode out of IODevice 2021-05-12 11:00:45 +01:00
ConfigFile.h LibCore: Add getter for how many groups exist in a Core::ConfigFile 2021-06-30 08:18:28 +04:30
DateTime.cpp LibCore: Add a way to parse a DateTime from a string 2021-06-11 23:58:28 +04:30
DateTime.h LibCore: Add a way to parse a DateTime from a string 2021-06-11 23:58:28 +04:30
DirIterator.cpp LibCore: Avoid duplicate '/' in DirIterator::next_full_path() 2021-07-03 16:43:08 +02:00
DirIterator.h LibCore: Expose DirIterator's underlying file descriptor 2021-05-14 23:32:10 +02:00
ElapsedTimer.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
ElapsedTimer.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
Event.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
Event.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
EventLoop.cpp LibThreading: Rename Lock => Mutex 2021-07-09 11:15:50 +02:00
EventLoop.h AK: Rename Vector::append(Vector) => Vector::extend(Vector) 2021-06-12 13:24:45 +02:00
File.cpp LibCore: Convert File to east-const style 2021-07-14 14:35:16 +04:30
File.h LibCore: Convert File to east-const style 2021-07-14 14:35:16 +04:30
FileStream.h LibCore: Add InputFileStream::seek 2021-06-25 20:48:14 +04:30
FileWatcher.cpp AK+Everywhere: Remove "null state" of LexicalPath 2021-06-30 11:13:54 +02:00
FileWatcher.h Userland+LibCore: Update FileWatcher + its users for InodeWatcher 2.0 2021-05-12 22:38:20 +02:00
Forward.h LibGUI: Move widget registration to LibCore 2021-05-06 08:50:39 +02:00
GetPassword.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
GetPassword.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
IODevice.cpp AK: Remove the public ByteBuffer::trim method 2021-05-31 14:49:00 +04:30
IODevice.h LibCore: Open files with O_CLOEXEC by default 2021-05-17 13:32:19 +02:00
LocalServer.cpp LibCore: Close accepted sockets on exec() and make them non-blocking 2021-05-17 13:32:19 +02:00
LocalServer.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
LocalSocket.cpp LibCore: Add peer pid retrieval for LocalSocket 2021-07-01 17:49:18 +02:00
LocalSocket.h LibCore: Add peer pid retrieval for LocalSocket 2021-07-01 17:49:18 +02:00
MimeData.cpp LibCore+Userland: Add 13 more detectable file types 2021-05-24 18:55:56 +01:00
MimeData.h LibCore: Implement basic mime type guessing based on binary patterns 2021-05-07 11:46:53 +01:00
NetworkJob.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
NetworkJob.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
NetworkResponse.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
NetworkResponse.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
Notifier.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
Notifier.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
Object.cpp LibCore: Replace fprintf(stderr)/printf() with warnln()/out() 2021-05-31 17:43:54 +01:00
Object.h LibCore: Call optional did_construct() method when constucting objects 2021-06-20 14:57:26 +02:00
ProcessStatisticsReader.cpp Everywhere: Improve CPU usage calculation 2021-07-18 22:08:26 +02:00
ProcessStatisticsReader.h Everywhere: Improve CPU usage calculation 2021-07-18 22:08:26 +02:00
Promise.h LibCore+LibIMAP: Move Promise to LibCore 2021-07-15 11:11:14 +02:00
Property.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
Property.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
Socket.cpp LibCore: Tolerate misaligned addresses in struct hostent 2021-07-12 18:42:45 +04:30
Socket.h LibCore+Everywhere: Move OpenMode out of IODevice 2021-05-12 11:00:45 +01:00
SocketAddress.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
StandardPaths.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
StandardPaths.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
TCPServer.cpp LibCore: Allow TCPServer to be blocking 2021-06-16 09:10:48 +02:00
TCPServer.h LibCore: Allow TCPServer to be blocking 2021-06-16 09:10:48 +02:00
TCPSocket.cpp LibCore+Everywhere: Move OpenMode out of IODevice 2021-05-12 11:00:45 +01:00
TCPSocket.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
Timer.cpp LibCore: Add unit to Core::Timer interval arguments 2021-05-12 22:38:20 +02:00
Timer.h LibCore: Add unit to Core::Timer interval arguments 2021-05-12 22:38:20 +02:00
UDPServer.cpp AK: Remove the public ByteBuffer::trim method 2021-05-31 14:49:00 +04:30
UDPServer.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
UDPSocket.cpp LibCore+Everywhere: Move OpenMode out of IODevice 2021-05-12 11:00:45 +01:00
UDPSocket.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00