Andreas Kling
23fe630057
AK: Allow printing a literal '%' character with the printf family.
2019-03-22 01:50:32 +01:00
Andreas Kling
c2a38c86cf
AK: Fix busted __udivmoddi4() implementation.
2019-03-21 17:33:06 +01:00
Andreas Kling
9dfcd95cd7
Use 64-bit integers inside Stopwatch to enable longer timings.
2019-03-21 13:41:36 +01:00
Andreas Kling
fe2fa4ac80
DNSLookupServer: Start working on a userspace DNS resolver.
...
This doesn't have any server functionality just yet, but it does post
decent-looking DNS queries and parse the responses.
2019-03-19 16:29:06 +01:00
Andreas Kling
43304d2adf
WindowServer: Add special treatment for modal windows.
...
While a WSClientConnection has a modal window showing, non-modal windows
belonging to that client are not sent any events.
2019-03-19 00:52:39 +01:00
Andreas Kling
214b67defd
AK: Add Vector::remove_first_matching(Callback).
...
This is a nice little helper to remove one item based on a matching
callback without having to do iteration yourself.
2019-03-18 20:51:40 +01:00
Andreas Kling
9ad076178a
GIODevice: Add a read_all() that returns a ByteBuffer with all we can read.
...
Use this to implement file opening in TextEditor.
2019-03-18 14:38:30 +01:00
Andreas Kling
ef05d8cbf6
AK: Use an OwnPtr for the VectorImpl.
...
I don't know why it wasn't implemented this way already. This fixes a leak
in operator=(Vector&&) that we were hitting on Ext2FS write.
2019-03-17 15:53:03 +01:00
Andreas Kling
1c6dfc3282
AK: Make ByteBuffer's copy() and wrap() take void*.
...
This way we don't have to cast whatever we're passing to copy()/wrap().
2019-03-17 00:36:41 +01:00
Andreas Kling
dd5ca1940a
AK: Hoist the assertion in Retainable::release() to RetainableBase.
...
This means we don't have to generate a __PRETTY_FUNCTION__ symbol there
for each and every specialization.
2019-03-16 13:48:56 +01:00
Andreas Kling
3ebb5fbb87
AK: Remove custom allocator feature from Vector.
...
This wasn't really used and generated a whole bunch of template bloat.
2019-03-16 13:24:39 +01:00
Andreas Kling
313ee8dd19
Move Lock from AK to Kernel, since it only works inside the kernel.
2019-03-16 13:18:22 +01:00
Andreas Kling
15657f0916
AK: Remove Buffer<T> since it was only ever instantiated with T=byte.
...
Instead make a specialized AK::ByteBufferImpl class for the backing store
of AK::ByteBuffer. This reduces template bloat.
2019-03-16 13:12:13 +01:00
Andreas Kling
955a0ff477
AK: Reduce template bloat by hoisting non-typed parts of Retainable.
...
This is a bit of an old school hack, but it does remove a whole bunch of
generated symbols.
2019-03-16 12:47:19 +01:00
Andreas Kling
f87dec1cbf
AK: Add CircularQueue::at().
2019-03-15 12:13:51 +01:00
Andreas Kling
209a16bb7f
IPv4: Dynamically allocate the UDP source port if needed.
2019-03-13 16:05:56 +01:00
Andreas Kling
60db082fdd
AK: Fix node leak in SinglyLinkedList::take_first().
2019-03-13 13:11:23 +01:00
Andreas Kling
87ecf290f4
Kernel: More work on the ICMP and IPv4 support.
2019-03-12 12:43:30 +01:00
Andreas Kling
90f60d2f65
Kernel: Cache MAC<->IP mappings (from ARP responses) seen on the wire.
2019-03-12 00:56:33 +01:00
Andreas Kling
35098cbde1
Kernel: Add a NetworkTask and a received network packet queue.
...
It will be easier to deal with incoming packets in a separate task.
2019-03-11 12:43:45 +01:00
Andreas Kling
0d5e6593b2
AK: Add a basic QuickSort template implementation.
...
It was depressing not being able to capture anything when passing a lambda
to qsort_r() so let's just have our own QuickSort. I was gonna have to do
this eventually anyway. :^)
2019-03-09 16:20:12 +01:00
Andreas Kling
46caa2663b
LibGUI: Use a separate data role for the table model sorting order.
...
This allows data to be displayed nicely while sorting happens based on some
underlying raw data. :^)
2019-03-09 14:24:34 +01:00
Andreas Kling
7d1142c7d9
Make it possible to sort a GTableModel by column+order.
...
This is accomplished by putting a GSortingProxyTableModel between the model
and the view. It's pretty simplistic but it works for this use case. :^)
2019-03-09 13:33:52 +01:00
Andreas Kling
48d48679b0
GTextEditor: Work on cut/copy/paste operations.
2019-03-08 14:08:15 +01:00
Andreas Kling
43d56b6f3a
GTextEditor: Support splitting lines at the cursor with the Return key.
2019-03-07 16:49:21 +01:00
Andreas Kling
8425ea971a
GTextEditor: Start working on editing, starting with inserting newlines.
2019-03-07 15:52:11 +01:00
Andreas Kling
75fabef57b
LibGUI: Add GVariant class and use it for table model data.
2019-02-28 16:20:29 +01:00
Andreas Kling
711e2b2651
AK: Accept any number of l's as printf format qualifiers.
...
This isn't entirely correct and will catch a bunch of things it's not
supposed to, but it works for now.
2019-02-27 08:39:19 +01:00
Andreas Kling
2fb3fa7f69
WindowServer: Add a simple CPU usage graph to the global menu bar.
...
This is pretty cute and helps me spot when something's chewing up CPU.
2019-02-26 02:17:25 +01:00
Andreas Kling
9624b54703
More moving towards using signed types.
...
I'm still feeling this out, but I am starting to like the general idea.
2019-02-25 22:06:55 +01:00
Andreas Kling
901b7d5d91
Fix a bunch of compiler warnings. Not all, but a lot.
2019-02-25 19:05:51 +01:00
Andreas Kling
15fb917f28
Convert more RetainPtr use to Retained.
2019-02-25 16:04:08 +01:00
Andreas Kling
2cfcbdc735
AK: Add Retained<T>, like RetainPtr, but never null.
...
Also use some Clang attribute wizardry to get a warning for use-after-move.
2019-02-25 12:43:52 +01:00
Andreas Kling
d7753c7c8d
Move over to building all of userspace with i686-pc-serenity-g++.
2019-02-22 14:45:14 +01:00
Andreas Kling
6788dcdb58
Start fixing things up to build with a proper cross-compiler.
2019-02-22 10:23:28 +01:00
Andreas Kling
3df4a902df
Ext2FS: Lock a lot. Go way overkill with locking for now.
2019-02-20 13:09:59 +01:00
Andreas Kling
809ffa56d7
Kernel: Reduce code duplication in exception handlers.
2019-02-20 12:28:41 +01:00
Andreas Kling
e74c833af3
AK: Fix broken instrumentation code for StringImpl.
2019-02-17 10:35:48 +01:00
Andreas Kling
022f7790db
Use modern C++ attributes instead of __attribute__ voodoo.
...
This is quite nice, although I wish [[gnu::always_inline]] implied inline.
Also "gnu::" is kind of a wart, but whatcha gonna do.
2019-02-15 12:30:48 +01:00
Andreas Kling
27df572381
AK: Fix bug in MMX memcpy() unaligned prologue handling.
2019-02-12 12:39:04 +01:00
Andreas Kling
fd5136a1ab
AK: Oops, the optimization in Vector::append(Vector&&) was broken.
...
It forgot to clear out the moved-from vector. It's easy to see where this bug
came from: I assumed m_impl was an OwnPtr. It would be comfy if move() on some
arbitrary T* would also null it out but alas that's not how things work.
2019-02-11 12:44:59 +01:00
Andreas Kling
7014daa235
Kernel: Add an LRU block cache.
...
This papers over some of the incredibly inefficient access patterns in the
Ext2FS implementation for a while longer. :^)
2019-02-10 20:07:14 +01:00
Andreas Kling
33d34d9b26
Kernel: Use a Lockable<bool> for sysctl booleans as well.
2019-02-08 16:18:24 +01:00
Andreas Kling
dabb3c902a
AK: Add a Lockable wrapping container.
2019-02-08 09:46:13 +01:00
Andreas Kling
5582a0a254
Kernel: When a lock is busy, donate remaining process ticks to lock holder.
...
Since we know who's holding the lock, and we're gonna have to yield anyway,
we can just ask the scheduler to donate any remaining ticks to that process.
2019-02-07 11:14:58 +01:00
Andreas Kling
44e1a45b2a
AK: Optimize Vector::append(Vector&&) for case where this->m_impl is null.
2019-02-07 09:09:30 +01:00
Andreas Kling
1f159eaab0
Add a fast memcpy() using MMX when we're moving >= 1KB.
...
This is a nice speedup for WindowServer. I'll eventually have to do this
with SSE but the kernel doesn't support SSE yet so this is it for now.
2019-02-07 08:46:52 +01:00
Andreas Kling
d0b2949b4d
AK: Lock should ASSERT_INTERRUPTS_ENABLED().
...
Trying to take a Lock while interrupts are disabled is always a bug.
2019-02-06 17:34:24 +01:00
Andreas Kling
a1b63bb6d4
Bootloader: Locate the kernel's data segment and clear it.
...
This was a constant source of stupid bugs and I kept postponing it because
I wasn't in the mood to write assembly code. Until now! :^)
2019-02-06 16:02:10 +01:00
Andreas Kling
781f216676
AK: Add a TemporaryChange helper class.
2019-02-06 16:01:59 +01:00