Age | Commit message (Collapse) | Author |
|
|
|
`AK::find*`
Problem:
- The implementation of `find` is coupled to the implementation of `Vector`.
- `Vector::find` takes the predicate by value which might be expensive.
Solution:
- Decouple the implementation of `find` from `Vector` by using a
generic `find` algorithm.
- Change the name of `find` with a predicate to `find_if` so that a
binding reference can be used and the predicate can be forwarded to
avoid copies.
- Change all the `find(pred)` call sites to use `find_if`.
|
|
This allows SystemMonitor to parse -t or -open-tab argument
to open a specific tab. (ex. network, interrupts etc.)
|
|
We now show the total CPU usage as well as the kernel portion.
For the memory graphs we show the amount of committed memory,
actually allocated memory, and the portion of the kernel heap.
|
|
|
|
This makes it more likely to be able to get statistics when resources
are scarce.
|
|
|
|
This implements memory commitments and lazy-allocation of committed
memory.
|
|
When we have an abstract font class it makes no sense to keep
these methods in the Font class.
|
|
This is a lot more expressive in C++ as well, not just in GML. :^)
|
|
This way we can use it instead of icon_for_path() in a bunch of places
and avoid loading the full FileIconProvider configuration.
|
|
Instead of using the extremely hackish icon_id field in /proc/all,
we now retrieve process icons from their executable by using
GUI::FileIconProvider.
|
|
This implements a number of changes related to time:
* If a HPET is present, it is now used only as a system timer, unless
the Local APIC timer is used (in which case the HPET timer will not
trigger any interrupts at all).
* If a HPET is present, the current time can now be as accurate as the
chip can be, independently from the system timer. We now query the
HPET main counter for the current time in CPU #0's system timer
interrupt, and use that as a base line. If a high precision time is
queried, that base line is used in combination with quering the HPET
timer directly, which should give a much more accurate time stamp at
the expense of more overhead. For faster time stamps, the more coarse
value based on the last interrupt will be returned. This also means
that any missed interrupts should not cause the time to drift.
* The default system interrupt rate is reduced to about 250 per second.
* Fix calculation of Thread CPU usage by using the amount of ticks they
used rather than the number of times a context switch happened.
* Implement CLOCK_REALTIME_COARSE and CLOCK_MONOTONIC_COARSE and use it
for most cases where precise timestamps are not needed.
|
|
New serenity_app() targets can be defined which allows application
icons to be emedded directly into the executable. The embedded
icons will then be used when creating an icon for that file in
LibGUI.
|
|
Problem:
- `(void)` simply casts the expression to void. This is understood to
indicate that it is ignored, but this is really a compiler trick to
get the compiler to not generate a warning.
Solution:
- Use the `[[maybe_unused]]` attribute to indicate the value is unused.
Note:
- Functions taking a `(void)` argument list have also been changed to
`()` because this is not needed and shows up in the same grep
command.
|
|
I was looking through the proc folder, noticed this and thought
"why not?"
It's setup as an updating model because of the call count, however,
the call count doesn't appear to be working right now.
|
|
All of these files were getting ByteBuffer.h from someone else and then
using it. Let's include it explicitly.
|
|
|
|
|
|
|
|
SortingProxyModel
|
|
|
|
|
|
|
|
Drops the '16' suffix from filenames. Resizes inconsistent
audio-volume icons to intended size.
|
|
What you install with this API is a delegate that manages painting of
all the items in a specific column, so let's make the API reflect that.
|
|
This patch introduces the HeaderView class, which is a widget that
implements the column headers of TableView and TreeView.
This greatly simplifies event management in the view implementations
and also makes it much easier to eventually implement row headers.
|
|
Flatten the CPU features array instead of showing it as raw JSON data.
|
|
Let's try this out and see how it feels! :^)
|
|
|
|
This is really a nop, as the cpu_percent is computed later. Zero the
value just to keep things sane.
|
|
This way you don't have to keep track of which model it came from.
|
|
No need to pass the Model *and* a ModelIndex, the index knows which
model it belongs to anyway.
|
|
This is preparation for using ModelRole in the ModelIndex API.
|
|
If the process table grows or shrinks, we need to invalidate all the
ProcessModel indexes. This is not great, but it's the most precise
invalidation we can do at the moment.
|
|
Instead of SortingProxyModel having a column+order, we move that state
to AbstractView. When you click on a column header, the view tells the
model to resort the relevant column with the new order.
This is implemented in SortingProxyModel by simply walking all the
reified source/proxy mappings and resorting their row indexes.
|
|
This changes the graph caption from KB to KiB, but it keeps just "K"
instead of "KiB" for all the numbers in columns in the table, since "K"
is fairly well-established as abbreviation of "KiB" (the SI prefix is
lower-case), and space is at a premium here.
|
|
Let's use the one in AK/NumberFormat.h everywhere.
It has slightly different behavior than some of the copies this
removes, but it's probably nice to have uniform human readable
size outputs across the system.
|
|
The SI prefixes "k", "M", "G" mean "10^3", "10^6", "10^9".
The IEC prefixes "Ki", "Mi", "Gi" mean "2^10", "2^20", "2^30".
Let's use the correct name, at least in code.
Only changes the name of the constants, no other behavior change.
|
|
This is a follow-up to #3095. In particular:
https://github.com/SerenityOS/serenity/pull/3095#discussion_r469113354
|
|
With this information, it's a bit easier to intuit the current 'process tree'.
If you're reading this, can I convince you to implement a nice process tree for
SystemMonitor? It could be via PPID (unbounded depth), or SID+PGID (depth 3).
Or something else entirely :D
|
|
This uses the new ProcFS interface at /proc/<pid>/stacks/<tid>
|
|
This class was added in the very early days of LibGUI, when I wasn't
quite sure if subclassing table views made sense or not.
|
|
|
|
|
|
|
|
|
|
Otherwise, the numbers overflow the space after a while.
|
|
This will let the WindowManager choose the location of the window
|
|
|