summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLiav A <liavalb@gmail.com>2023-02-24 20:25:52 +0200
committerJelle Raaijmakers <jelle@gmta.nl>2023-06-04 21:32:34 +0200
commit927926b9247522b4c8854d48a79b55599108cff2 (patch)
tree706a4aa247ddde4ed4c055d98d247b007a664f3e
parentb88c1d90e1d65d62f5438686bdb386652c3d7d40 (diff)
downloadserenity-927926b9247522b4c8854d48a79b55599108cff2.zip
Kernel: Move Performance-measurement code to the Tasks subdirectory
-rw-r--r--Kernel/Arch/PageFault.cpp2
-rw-r--r--Kernel/Arch/x86_64/Interrupts.cpp2
-rw-r--r--Kernel/CMakeLists.txt2
-rw-r--r--Kernel/FileSystem/SysFS/Subsystems/Kernel/Profile.cpp2
-rw-r--r--Kernel/Heap/kmalloc.cpp2
-rw-r--r--Kernel/Memory/AddressSpace.cpp2
-rw-r--r--Kernel/Syscall.cpp2
-rw-r--r--Kernel/Syscalls/execve.cpp2
-rw-r--r--Kernel/Syscalls/exit.cpp2
-rw-r--r--Kernel/Syscalls/fork.cpp2
-rw-r--r--Kernel/Syscalls/mmap.cpp4
-rw-r--r--Kernel/Syscalls/perf_event.cpp2
-rw-r--r--Kernel/Syscalls/profiling.cpp2
-rw-r--r--Kernel/Syscalls/read.cpp2
-rw-r--r--Kernel/Syscalls/thread.cpp2
-rw-r--r--Kernel/Tasks/PerformanceEventBuffer.cpp (renamed from Kernel/PerformanceEventBuffer.cpp)2
-rw-r--r--Kernel/Tasks/PerformanceEventBuffer.h (renamed from Kernel/PerformanceEventBuffer.h)0
-rw-r--r--Kernel/Tasks/PerformanceManager.h (renamed from Kernel/PerformanceManager.h)2
-rw-r--r--Kernel/Tasks/Process.cpp4
-rw-r--r--Kernel/Tasks/Process.h2
-rw-r--r--Kernel/Tasks/Scheduler.cpp2
-rw-r--r--Kernel/Tasks/Thread.cpp2
-rw-r--r--Kernel/Time/TimeManagement.cpp2
23 files changed, 24 insertions, 24 deletions
diff --git a/Kernel/Arch/PageFault.cpp b/Kernel/Arch/PageFault.cpp
index a341de455a..033bb41f3a 100644
--- a/Kernel/Arch/PageFault.cpp
+++ b/Kernel/Arch/PageFault.cpp
@@ -9,7 +9,7 @@
#include <Kernel/Arch/Processor.h>
#include <Kernel/Arch/RegisterState.h>
#include <Kernel/Arch/SafeMem.h>
-#include <Kernel/PerformanceManager.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Thread.h>
namespace Kernel {
diff --git a/Kernel/Arch/x86_64/Interrupts.cpp b/Kernel/Arch/x86_64/Interrupts.cpp
index a210c22740..d43ffe940f 100644
--- a/Kernel/Arch/x86_64/Interrupts.cpp
+++ b/Kernel/Arch/x86_64/Interrupts.cpp
@@ -16,9 +16,9 @@
#include <Kernel/Interrupts/SpuriousInterruptHandler.h>
#include <Kernel/Interrupts/UnhandledInterruptHandler.h>
#include <Kernel/Library/Panic.h>
-#include <Kernel/PerformanceManager.h>
#include <Kernel/Sections.h>
#include <Kernel/Security/Random.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Tasks/Scheduler.h>
#include <Kernel/Tasks/Thread.h>
diff --git a/Kernel/CMakeLists.txt b/Kernel/CMakeLists.txt
index 405a0d863a..c8d736ebc7 100644
--- a/Kernel/CMakeLists.txt
+++ b/Kernel/CMakeLists.txt
@@ -258,7 +258,6 @@ set(KERNEL_SOURCES
Net/Socket.cpp
Net/TCPSocket.cpp
Net/UDPSocket.cpp
- PerformanceEventBuffer.cpp
Syscall.cpp
Security/AddressSanitizer.cpp
Security/Credentials.cpp
@@ -347,6 +346,7 @@ set(KERNEL_SOURCES
Tasks/CrashHandler.cpp
Tasks/FinalizerTask.cpp
Tasks/FutexQueue.cpp
+ Tasks/PerformanceEventBuffer.cpp
Tasks/Process.cpp
Tasks/ProcessGroup.cpp
Tasks/ProcessList.cpp
diff --git a/Kernel/FileSystem/SysFS/Subsystems/Kernel/Profile.cpp b/Kernel/FileSystem/SysFS/Subsystems/Kernel/Profile.cpp
index 7a12ea0a03..51622d358d 100644
--- a/Kernel/FileSystem/SysFS/Subsystems/Kernel/Profile.cpp
+++ b/Kernel/FileSystem/SysFS/Subsystems/Kernel/Profile.cpp
@@ -5,8 +5,8 @@
*/
#include <Kernel/FileSystem/SysFS/Subsystems/Kernel/Profile.h>
-#include <Kernel/PerformanceEventBuffer.h>
#include <Kernel/Sections.h>
+#include <Kernel/Tasks/PerformanceEventBuffer.h>
namespace Kernel {
diff --git a/Kernel/Heap/kmalloc.cpp b/Kernel/Heap/kmalloc.cpp
index 5266a47b8f..9212c36d4c 100644
--- a/Kernel/Heap/kmalloc.cpp
+++ b/Kernel/Heap/kmalloc.cpp
@@ -15,8 +15,8 @@
#include <Kernel/Library/StdLib.h>
#include <Kernel/Locking/Spinlock.h>
#include <Kernel/Memory/MemoryManager.h>
-#include <Kernel/PerformanceManager.h>
#include <Kernel/Sections.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#if ARCH(X86_64) || ARCH(AARCH64)
static constexpr size_t CHUNK_SIZE = 64;
diff --git a/Kernel/Memory/AddressSpace.cpp b/Kernel/Memory/AddressSpace.cpp
index 643f6bd94a..0d972cd1cc 100644
--- a/Kernel/Memory/AddressSpace.cpp
+++ b/Kernel/Memory/AddressSpace.cpp
@@ -12,8 +12,8 @@
#include <Kernel/Memory/AnonymousVMObject.h>
#include <Kernel/Memory/InodeVMObject.h>
#include <Kernel/Memory/MemoryManager.h>
-#include <Kernel/PerformanceManager.h>
#include <Kernel/Security/Random.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Tasks/Scheduler.h>
diff --git a/Kernel/Syscall.cpp b/Kernel/Syscall.cpp
index a3282e9bb7..c6130882cb 100644
--- a/Kernel/Syscall.cpp
+++ b/Kernel/Syscall.cpp
@@ -10,8 +10,8 @@
#include <Kernel/Arch/TrapFrame.h>
#include <Kernel/Library/Panic.h>
#include <Kernel/Memory/MemoryManager.h>
-#include <Kernel/PerformanceManager.h>
#include <Kernel/Sections.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Tasks/Scheduler.h>
#include <Kernel/Tasks/ThreadTracer.h>
diff --git a/Kernel/Syscalls/execve.cpp b/Kernel/Syscalls/execve.cpp
index ebce643278..c18d11f0cd 100644
--- a/Kernel/Syscalls/execve.cpp
+++ b/Kernel/Syscalls/execve.cpp
@@ -16,8 +16,8 @@
#include <Kernel/Memory/MemoryManager.h>
#include <Kernel/Memory/Region.h>
#include <Kernel/Memory/SharedInodeVMObject.h>
-#include <Kernel/PerformanceManager.h>
#include <Kernel/Security/Random.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Tasks/Scheduler.h>
#include <Kernel/Time/TimeManagement.h>
diff --git a/Kernel/Syscalls/exit.cpp b/Kernel/Syscalls/exit.cpp
index e257f0ebb9..9911d5bd5b 100644
--- a/Kernel/Syscalls/exit.cpp
+++ b/Kernel/Syscalls/exit.cpp
@@ -5,7 +5,7 @@
*/
#include <Kernel/KSyms.h>
-#include <Kernel/PerformanceManager.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Tasks/Thread.h>
diff --git a/Kernel/Syscalls/fork.cpp b/Kernel/Syscalls/fork.cpp
index da478ed134..556d5e86e9 100644
--- a/Kernel/Syscalls/fork.cpp
+++ b/Kernel/Syscalls/fork.cpp
@@ -8,8 +8,8 @@
#include <Kernel/Debug.h>
#include <Kernel/FileSystem/Custody.h>
#include <Kernel/Memory/Region.h>
-#include <Kernel/PerformanceManager.h>
#include <Kernel/TTY/TTY.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Tasks/Scheduler.h>
diff --git a/Kernel/Syscalls/mmap.cpp b/Kernel/Syscalls/mmap.cpp
index 9ae33bd4a6..d296da6114 100644
--- a/Kernel/Syscalls/mmap.cpp
+++ b/Kernel/Syscalls/mmap.cpp
@@ -17,8 +17,8 @@
#include <Kernel/Memory/PrivateInodeVMObject.h>
#include <Kernel/Memory/Region.h>
#include <Kernel/Memory/SharedInodeVMObject.h>
-#include <Kernel/PerformanceEventBuffer.h>
-#include <Kernel/PerformanceManager.h>
+#include <Kernel/Tasks/PerformanceEventBuffer.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Process.h>
#include <LibELF/Validation.h>
diff --git a/Kernel/Syscalls/perf_event.cpp b/Kernel/Syscalls/perf_event.cpp
index 543d3d0224..a359c8e885 100644
--- a/Kernel/Syscalls/perf_event.cpp
+++ b/Kernel/Syscalls/perf_event.cpp
@@ -4,7 +4,7 @@
* SPDX-License-Identifier: BSD-2-Clause
*/
-#include <Kernel/PerformanceEventBuffer.h>
+#include <Kernel/Tasks/PerformanceEventBuffer.h>
#include <Kernel/Tasks/Process.h>
namespace Kernel {
diff --git a/Kernel/Syscalls/profiling.cpp b/Kernel/Syscalls/profiling.cpp
index c21d4c4afa..f8a3a13f1d 100644
--- a/Kernel/Syscalls/profiling.cpp
+++ b/Kernel/Syscalls/profiling.cpp
@@ -4,8 +4,8 @@
* SPDX-License-Identifier: BSD-2-Clause
*/
-#include <Kernel/PerformanceManager.h>
#include <Kernel/Tasks/Coredump.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Tasks/Scheduler.h>
#include <Kernel/Time/TimeManagement.h>
diff --git a/Kernel/Syscalls/read.cpp b/Kernel/Syscalls/read.cpp
index b350e17691..6c18561db0 100644
--- a/Kernel/Syscalls/read.cpp
+++ b/Kernel/Syscalls/read.cpp
@@ -6,7 +6,7 @@
#include <Kernel/Debug.h>
#include <Kernel/FileSystem/OpenFileDescription.h>
-#include <Kernel/PerformanceManager.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Process.h>
namespace Kernel {
diff --git a/Kernel/Syscalls/thread.cpp b/Kernel/Syscalls/thread.cpp
index c2fbbd2485..7017012f85 100644
--- a/Kernel/Syscalls/thread.cpp
+++ b/Kernel/Syscalls/thread.cpp
@@ -6,7 +6,7 @@
#include <AK/Checked.h>
#include <Kernel/Memory/MemoryManager.h>
-#include <Kernel/PerformanceManager.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Tasks/Scheduler.h>
diff --git a/Kernel/PerformanceEventBuffer.cpp b/Kernel/Tasks/PerformanceEventBuffer.cpp
index 929e569f0d..7a67708e10 100644
--- a/Kernel/PerformanceEventBuffer.cpp
+++ b/Kernel/Tasks/PerformanceEventBuffer.cpp
@@ -12,7 +12,7 @@
#include <Kernel/Arch/SmapDisabler.h>
#include <Kernel/FileSystem/Custody.h>
#include <Kernel/Library/KBufferBuilder.h>
-#include <Kernel/PerformanceEventBuffer.h>
+#include <Kernel/Tasks/PerformanceEventBuffer.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Time/TimeManagement.h>
diff --git a/Kernel/PerformanceEventBuffer.h b/Kernel/Tasks/PerformanceEventBuffer.h
index 74233424be..74233424be 100644
--- a/Kernel/PerformanceEventBuffer.h
+++ b/Kernel/Tasks/PerformanceEventBuffer.h
diff --git a/Kernel/PerformanceManager.h b/Kernel/Tasks/PerformanceManager.h
index bf2c1f500b..14a73f5d17 100644
--- a/Kernel/PerformanceManager.h
+++ b/Kernel/Tasks/PerformanceManager.h
@@ -6,7 +6,7 @@
#pragma once
-#include <Kernel/PerformanceEventBuffer.h>
+#include <Kernel/Tasks/PerformanceEventBuffer.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Tasks/Thread.h>
#include <Kernel/Time/TimeManagement.h>
diff --git a/Kernel/Tasks/Process.cpp b/Kernel/Tasks/Process.cpp
index 7b8f348221..fcc74c5b86 100644
--- a/Kernel/Tasks/Process.cpp
+++ b/Kernel/Tasks/Process.cpp
@@ -31,10 +31,10 @@
#include <Kernel/Library/StdLib.h>
#include <Kernel/Memory/AnonymousVMObject.h>
#include <Kernel/Memory/SharedInodeVMObject.h>
-#include <Kernel/PerformanceEventBuffer.h>
-#include <Kernel/PerformanceManager.h>
#include <Kernel/Sections.h>
#include <Kernel/TTY/TTY.h>
+#include <Kernel/Tasks/PerformanceEventBuffer.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Tasks/Scheduler.h>
#include <Kernel/Tasks/Thread.h>
diff --git a/Kernel/Tasks/Process.h b/Kernel/Tasks/Process.h
index b94ff7d381..19ebfbb813 100644
--- a/Kernel/Tasks/Process.h
+++ b/Kernel/Tasks/Process.h
@@ -28,11 +28,11 @@
#include <Kernel/Locking/Mutex.h>
#include <Kernel/Locking/MutexProtected.h>
#include <Kernel/Memory/AddressSpace.h>
-#include <Kernel/PerformanceEventBuffer.h>
#include <Kernel/Security/Credentials.h>
#include <Kernel/Security/Jail.h>
#include <Kernel/Tasks/AtomicEdgeAction.h>
#include <Kernel/Tasks/FutexQueue.h>
+#include <Kernel/Tasks/PerformanceEventBuffer.h>
#include <Kernel/Tasks/ProcessGroup.h>
#include <Kernel/Tasks/Thread.h>
#include <Kernel/UnixTypes.h>
diff --git a/Kernel/Tasks/Scheduler.cpp b/Kernel/Tasks/Scheduler.cpp
index 8e2632c7c2..c5cd5539c0 100644
--- a/Kernel/Tasks/Scheduler.cpp
+++ b/Kernel/Tasks/Scheduler.cpp
@@ -12,8 +12,8 @@
#include <Kernel/Debug.h>
#include <Kernel/InterruptDisabler.h>
#include <Kernel/Library/Panic.h>
-#include <Kernel/PerformanceManager.h>
#include <Kernel/Sections.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Tasks/Scheduler.h>
#include <Kernel/Time/TimeManagement.h>
diff --git a/Kernel/Tasks/Thread.cpp b/Kernel/Tasks/Thread.cpp
index d0cbc22e3c..3dd20af5db 100644
--- a/Kernel/Tasks/Thread.cpp
+++ b/Kernel/Tasks/Thread.cpp
@@ -21,8 +21,8 @@
#include <Kernel/Library/Panic.h>
#include <Kernel/Memory/MemoryManager.h>
#include <Kernel/Memory/ScopedAddressSpaceSwitcher.h>
-#include <Kernel/PerformanceEventBuffer.h>
#include <Kernel/Sections.h>
+#include <Kernel/Tasks/PerformanceEventBuffer.h>
#include <Kernel/Tasks/Process.h>
#include <Kernel/Tasks/Scheduler.h>
#include <Kernel/Tasks/Thread.h>
diff --git a/Kernel/Time/TimeManagement.cpp b/Kernel/Time/TimeManagement.cpp
index 23d66b971c..003bc3fca5 100644
--- a/Kernel/Time/TimeManagement.cpp
+++ b/Kernel/Time/TimeManagement.cpp
@@ -26,8 +26,8 @@
#include <Kernel/Boot/CommandLine.h>
#include <Kernel/Firmware/ACPI/Parser.h>
#include <Kernel/InterruptDisabler.h>
-#include <Kernel/PerformanceManager.h>
#include <Kernel/Sections.h>
+#include <Kernel/Tasks/PerformanceManager.h>
#include <Kernel/Tasks/Scheduler.h>
#include <Kernel/Time/HardwareTimer.h>
#include <Kernel/Time/TimeManagement.h>