From 7bb2dd75cddf1556083c258aafb5e1b714af6939 Mon Sep 17 00:00:00 2001 From: Morph <39850852+Morph1984@users.noreply.github.com> Date: Thu, 7 Oct 2021 13:29:33 -0400 Subject: service: Reduce header include overhead --- src/core/hle/ipc_helpers.h | 3 --- src/core/hle/service/am/applet_ae.h | 2 +- src/core/hle/service/am/applet_oe.h | 2 +- src/core/hle/service/audio/audin_u.cpp | 1 - src/core/hle/service/audio/audout_u.cpp | 1 - src/core/hle/service/audio/audren_u.cpp | 1 - src/core/hle/service/audio/hwopus.cpp | 1 - src/core/hle/service/btdrv/btdrv.cpp | 1 - src/core/hle/service/btm/btm.cpp | 1 - src/core/hle/service/caps/caps.h | 3 ++- src/core/hle/service/fgm/fgm.cpp | 1 - src/core/hle/service/filesystem/fsp_ldr.cpp | 1 - src/core/hle/service/filesystem/fsp_pr.cpp | 1 - src/core/hle/service/glue/arp.cpp | 2 -- src/core/hle/service/hid/hid.cpp | 4 ---- src/core/hle/service/lbl/lbl.cpp | 1 - src/core/hle/service/mii/mii.cpp | 1 - src/core/hle/service/nfc/nfc.cpp | 1 - src/core/hle/service/ns/ns.cpp | 1 - src/core/hle/service/olsc/olsc.cpp | 1 - src/core/hle/service/set/set_sys.cpp | 1 - src/core/hle/service/sockets/bsd.h | 2 -- src/core/hle/service/sockets/sfdnsres.h | 1 - src/core/hle/service/sockets/sockets.h | 6 +++++- src/core/hle/service/spl/spl_module.cpp | 2 -- src/core/hle/service/ssl/ssl.cpp | 1 - src/core/hle/service/time/time.cpp | 2 +- src/core/hle/service/time/time.h | 1 - src/core/hle/service/usb/usb.cpp | 1 - src/core/hle/service/vi/vi.h | 1 - src/yuzu/configuration/configure_system.cpp | 2 +- 31 files changed, 11 insertions(+), 39 deletions(-) diff --git a/src/core/hle/ipc_helpers.h b/src/core/hle/ipc_helpers.h index ceff2532d..cf204f570 100644 --- a/src/core/hle/ipc_helpers.h +++ b/src/core/hle/ipc_helpers.h @@ -4,17 +4,14 @@ #pragma once -#include #include #include -#include #include #include #include "common/assert.h" #include "common/common_types.h" #include "core/hle/ipc.h" #include "core/hle/kernel/hle_ipc.h" -#include "core/hle/kernel/k_client_port.h" #include "core/hle/kernel/k_process.h" #include "core/hle/kernel/k_resource_limit.h" #include "core/hle/kernel/k_session.h" diff --git a/src/core/hle/service/am/applet_ae.h b/src/core/hle/service/am/applet_ae.h index adb207349..f89f65649 100644 --- a/src/core/hle/service/am/applet_ae.h +++ b/src/core/hle/service/am/applet_ae.h @@ -5,7 +5,7 @@ #pragma once #include -#include "core/hle/kernel/hle_ipc.h" + #include "core/hle/service/service.h" namespace Service { diff --git a/src/core/hle/service/am/applet_oe.h b/src/core/hle/service/am/applet_oe.h index 6c1aa255a..64b874ead 100644 --- a/src/core/hle/service/am/applet_oe.h +++ b/src/core/hle/service/am/applet_oe.h @@ -5,7 +5,7 @@ #pragma once #include -#include "core/hle/kernel/hle_ipc.h" + #include "core/hle/service/service.h" namespace Service { diff --git a/src/core/hle/service/audio/audin_u.cpp b/src/core/hle/service/audio/audin_u.cpp index 840d1d883..34cc659ed 100644 --- a/src/core/hle/service/audio/audin_u.cpp +++ b/src/core/hle/service/audio/audin_u.cpp @@ -5,7 +5,6 @@ #include "common/logging/log.h" #include "core/core.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/kernel/k_event.h" #include "core/hle/service/audio/audin_u.h" diff --git a/src/core/hle/service/audio/audout_u.cpp b/src/core/hle/service/audio/audout_u.cpp index beb387745..81adbfe09 100644 --- a/src/core/hle/service/audio/audout_u.cpp +++ b/src/core/hle/service/audio/audout_u.cpp @@ -13,7 +13,6 @@ #include "common/swap.h" #include "core/core.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/kernel/k_event.h" #include "core/hle/kernel/kernel.h" #include "core/hle/service/audio/audout_u.h" diff --git a/src/core/hle/service/audio/audren_u.cpp b/src/core/hle/service/audio/audren_u.cpp index 1f69d39cc..cdb2a9521 100644 --- a/src/core/hle/service/audio/audren_u.cpp +++ b/src/core/hle/service/audio/audren_u.cpp @@ -15,7 +15,6 @@ #include "common/string_util.h" #include "core/core.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/kernel/k_event.h" #include "core/hle/kernel/kernel.h" #include "core/hle/service/audio/audren_u.h" diff --git a/src/core/hle/service/audio/hwopus.cpp b/src/core/hle/service/audio/hwopus.cpp index 33a6dbbb6..7da1f2969 100644 --- a/src/core/hle/service/audio/hwopus.cpp +++ b/src/core/hle/service/audio/hwopus.cpp @@ -13,7 +13,6 @@ #include "common/assert.h" #include "common/logging/log.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/service/audio/hwopus.h" namespace Service::Audio { diff --git a/src/core/hle/service/btdrv/btdrv.cpp b/src/core/hle/service/btdrv/btdrv.cpp index ecd3bd22a..088a1a18a 100644 --- a/src/core/hle/service/btdrv/btdrv.cpp +++ b/src/core/hle/service/btdrv/btdrv.cpp @@ -5,7 +5,6 @@ #include "common/logging/log.h" #include "core/core.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/kernel/k_event.h" #include "core/hle/kernel/kernel.h" #include "core/hle/service/btdrv/btdrv.h" diff --git a/src/core/hle/service/btm/btm.cpp b/src/core/hle/service/btm/btm.cpp index 780a99c2d..7aabacc19 100644 --- a/src/core/hle/service/btm/btm.cpp +++ b/src/core/hle/service/btm/btm.cpp @@ -7,7 +7,6 @@ #include "common/logging/log.h" #include "core/core.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/kernel/k_event.h" #include "core/hle/kernel/kernel.h" #include "core/hle/service/btm/btm.h" diff --git a/src/core/hle/service/caps/caps.h b/src/core/hle/service/caps/caps.h index 3c4290c88..b18adcb9d 100644 --- a/src/core/hle/service/caps/caps.h +++ b/src/core/hle/service/caps/caps.h @@ -4,7 +4,8 @@ #pragma once -#include "core/hle/service/service.h" +#include "common/common_funcs.h" +#include "common/common_types.h" namespace Core { class System; diff --git a/src/core/hle/service/fgm/fgm.cpp b/src/core/hle/service/fgm/fgm.cpp index 25c6c0194..d7a638f96 100644 --- a/src/core/hle/service/fgm/fgm.cpp +++ b/src/core/hle/service/fgm/fgm.cpp @@ -5,7 +5,6 @@ #include #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/service/fgm/fgm.h" #include "core/hle/service/service.h" #include "core/hle/service/sm/sm.h" diff --git a/src/core/hle/service/filesystem/fsp_ldr.cpp b/src/core/hle/service/filesystem/fsp_ldr.cpp index 1f6c17ba5..f112ae9d0 100644 --- a/src/core/hle/service/filesystem/fsp_ldr.cpp +++ b/src/core/hle/service/filesystem/fsp_ldr.cpp @@ -3,7 +3,6 @@ // Refer to the license.txt file included. #include "core/hle/service/filesystem/fsp_ldr.h" -#include "core/hle/service/service.h" namespace Service::FileSystem { diff --git a/src/core/hle/service/filesystem/fsp_pr.cpp b/src/core/hle/service/filesystem/fsp_pr.cpp index 00e4d1662..9b7f7d861 100644 --- a/src/core/hle/service/filesystem/fsp_pr.cpp +++ b/src/core/hle/service/filesystem/fsp_pr.cpp @@ -3,7 +3,6 @@ // Refer to the license.txt file included. #include "core/hle/service/filesystem/fsp_pr.h" -#include "core/hle/service/service.h" namespace Service::FileSystem { diff --git a/src/core/hle/service/glue/arp.cpp b/src/core/hle/service/glue/arp.cpp index 5a3b54cc1..70cd63c6b 100644 --- a/src/core/hle/service/glue/arp.cpp +++ b/src/core/hle/service/glue/arp.cpp @@ -8,13 +8,11 @@ #include "core/core.h" #include "core/file_sys/control_metadata.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/kernel/k_process.h" #include "core/hle/kernel/kernel.h" #include "core/hle/service/glue/arp.h" #include "core/hle/service/glue/errors.h" #include "core/hle/service/glue/glue_manager.h" -#include "core/hle/service/service.h" namespace Service::Glue { diff --git a/src/core/hle/service/hid/hid.cpp b/src/core/hle/service/hid/hid.cpp index 8c363142c..043320d50 100644 --- a/src/core/hle/service/hid/hid.cpp +++ b/src/core/hle/service/hid/hid.cpp @@ -8,12 +8,9 @@ #include "common/settings.h" #include "core/core.h" #include "core/core_timing.h" -#include "core/core_timing_util.h" #include "core/frontend/emu_window.h" #include "core/frontend/input.h" -#include "core/hardware_properties.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/k_client_port.h" #include "core/hle/kernel/k_readable_event.h" #include "core/hle/kernel/k_shared_memory.h" #include "core/hle/kernel/k_transfer_memory.h" @@ -23,7 +20,6 @@ #include "core/hle/service/hid/hid.h" #include "core/hle/service/hid/irs.h" #include "core/hle/service/hid/xcd.h" -#include "core/hle/service/service.h" #include "core/memory.h" #include "core/hle/service/hid/controllers/console_sixaxis.h" diff --git a/src/core/hle/service/lbl/lbl.cpp b/src/core/hle/service/lbl/lbl.cpp index 37ff37277..5c8ae029c 100644 --- a/src/core/hle/service/lbl/lbl.cpp +++ b/src/core/hle/service/lbl/lbl.cpp @@ -7,7 +7,6 @@ #include "common/logging/log.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/service/lbl/lbl.h" #include "core/hle/service/service.h" #include "core/hle/service/sm/sm.h" diff --git a/src/core/hle/service/mii/mii.cpp b/src/core/hle/service/mii/mii.cpp index 9d863486a..0b907824d 100644 --- a/src/core/hle/service/mii/mii.cpp +++ b/src/core/hle/service/mii/mii.cpp @@ -6,7 +6,6 @@ #include "common/logging/log.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/service/mii/mii.h" #include "core/hle/service/mii/mii_manager.h" #include "core/hle/service/service.h" diff --git a/src/core/hle/service/nfc/nfc.cpp b/src/core/hle/service/nfc/nfc.cpp index b014ea826..f77037842 100644 --- a/src/core/hle/service/nfc/nfc.cpp +++ b/src/core/hle/service/nfc/nfc.cpp @@ -7,7 +7,6 @@ #include "common/logging/log.h" #include "common/settings.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/service/nfc/nfc.h" #include "core/hle/service/service.h" #include "core/hle/service/sm/sm.h" diff --git a/src/core/hle/service/ns/ns.cpp b/src/core/hle/service/ns/ns.cpp index 8ce1f3296..931b48f72 100644 --- a/src/core/hle/service/ns/ns.cpp +++ b/src/core/hle/service/ns/ns.cpp @@ -9,7 +9,6 @@ #include "core/file_sys/patch_manager.h" #include "core/file_sys/vfs.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/service/ns/errors.h" #include "core/hle/service/ns/language.h" #include "core/hle/service/ns/ns.h" diff --git a/src/core/hle/service/olsc/olsc.cpp b/src/core/hle/service/olsc/olsc.cpp index 3bbe1bfe2..39a8031a5 100644 --- a/src/core/hle/service/olsc/olsc.cpp +++ b/src/core/hle/service/olsc/olsc.cpp @@ -3,7 +3,6 @@ // Refer to the license.txt file included. #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/service/olsc/olsc.h" #include "core/hle/service/service.h" #include "core/hle/service/sm/sm.h" diff --git a/src/core/hle/service/set/set_sys.cpp b/src/core/hle/service/set/set_sys.cpp index 8299c6b68..286578b17 100644 --- a/src/core/hle/service/set/set_sys.cpp +++ b/src/core/hle/service/set/set_sys.cpp @@ -7,7 +7,6 @@ #include "core/file_sys/errors.h" #include "core/file_sys/system_archive/system_version.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/k_client_port.h" #include "core/hle/service/filesystem/filesystem.h" #include "core/hle/service/set/set_sys.h" diff --git a/src/core/hle/service/sockets/bsd.h b/src/core/hle/service/sockets/bsd.h index d68beef5c..a387e50df 100644 --- a/src/core/hle/service/sockets/bsd.h +++ b/src/core/hle/service/sockets/bsd.h @@ -5,11 +5,9 @@ #pragma once #include -#include #include #include "common/common_types.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/service/service.h" #include "core/hle/service/sockets/sockets.h" diff --git a/src/core/hle/service/sockets/sfdnsres.h b/src/core/hle/service/sockets/sfdnsres.h index faa6b7d0d..5d3b4dc2d 100644 --- a/src/core/hle/service/sockets/sfdnsres.h +++ b/src/core/hle/service/sockets/sfdnsres.h @@ -4,7 +4,6 @@ #pragma once -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/service/service.h" namespace Core { diff --git a/src/core/hle/service/sockets/sockets.h b/src/core/hle/service/sockets/sockets.h index 5a65ed2a9..02dbbae40 100644 --- a/src/core/hle/service/sockets/sockets.h +++ b/src/core/hle/service/sockets/sockets.h @@ -4,13 +4,17 @@ #pragma once +#include "common/common_funcs.h" #include "common/common_types.h" -#include "core/hle/service/service.h" namespace Core { class System; } +namespace Service::SM { +class ServiceManager; +} + namespace Service::Sockets { enum class Errno : u32 { diff --git a/src/core/hle/service/spl/spl_module.cpp b/src/core/hle/service/spl/spl_module.cpp index 918633af5..ed4c06260 100644 --- a/src/core/hle/service/spl/spl_module.cpp +++ b/src/core/hle/service/spl/spl_module.cpp @@ -3,10 +3,8 @@ // Refer to the license.txt file included. #include -#include #include #include -#include #include #include "common/logging/log.h" #include "common/settings.h" diff --git a/src/core/hle/service/ssl/ssl.cpp b/src/core/hle/service/ssl/ssl.cpp index 921f4d776..a81a595ea 100644 --- a/src/core/hle/service/ssl/ssl.cpp +++ b/src/core/hle/service/ssl/ssl.cpp @@ -3,7 +3,6 @@ // Refer to the license.txt file included. #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/service/service.h" #include "core/hle/service/sm/sm.h" #include "core/hle/service/ssl/ssl.h" diff --git a/src/core/hle/service/time/time.cpp b/src/core/hle/service/time/time.cpp index 8fdd5076f..d84a111c2 100644 --- a/src/core/hle/service/time/time.cpp +++ b/src/core/hle/service/time/time.cpp @@ -8,11 +8,11 @@ #include "core/core_timing_util.h" #include "core/hardware_properties.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/k_client_port.h" #include "core/hle/kernel/k_scheduler.h" #include "core/hle/kernel/kernel.h" #include "core/hle/service/time/time.h" #include "core/hle/service/time/time_interface.h" +#include "core/hle/service/time/time_manager.h" #include "core/hle/service/time/time_sharedmemory.h" #include "core/hle/service/time/time_zone_service.h" diff --git a/src/core/hle/service/time/time.h b/src/core/hle/service/time/time.h index ce9c479c6..30e2cd369 100644 --- a/src/core/hle/service/time/time.h +++ b/src/core/hle/service/time/time.h @@ -6,7 +6,6 @@ #include "core/hle/service/service.h" #include "core/hle/service/time/clock_types.h" -#include "core/hle/service/time/time_manager.h" namespace Core { class System; diff --git a/src/core/hle/service/usb/usb.cpp b/src/core/hle/service/usb/usb.cpp index 2ee103b37..502dfbb4a 100644 --- a/src/core/hle/service/usb/usb.cpp +++ b/src/core/hle/service/usb/usb.cpp @@ -6,7 +6,6 @@ #include "common/logging/log.h" #include "core/hle/ipc_helpers.h" -#include "core/hle/kernel/hle_ipc.h" #include "core/hle/service/service.h" #include "core/hle/service/sm/sm.h" #include "core/hle/service/usb/usb.h" diff --git a/src/core/hle/service/vi/vi.h b/src/core/hle/service/vi/vi.h index eec531d54..2fd7f8e61 100644 --- a/src/core/hle/service/vi/vi.h +++ b/src/core/hle/service/vi/vi.h @@ -4,7 +4,6 @@ #pragma once -#include #include "common/common_types.h" namespace Core { diff --git a/src/yuzu/configuration/configure_system.cpp b/src/yuzu/configuration/configure_system.cpp index 99a5df241..24a67ad46 100644 --- a/src/yuzu/configuration/configure_system.cpp +++ b/src/yuzu/configuration/configure_system.cpp @@ -12,7 +12,7 @@ #include "common/assert.h" #include "common/settings.h" #include "core/core.h" -#include "core/hle/service/time/time.h" +#include "core/hle/service/time/time_manager.h" #include "ui_configure_system.h" #include "yuzu/configuration/configuration_shared.h" #include "yuzu/configuration/configure_system.h" -- cgit v1.2.3 From bea7824bd1757e2d67e90fad055b686db04977f7 Mon Sep 17 00:00:00 2001 From: Morph <39850852+Morph1984@users.noreply.github.com> Date: Thu, 7 Oct 2021 13:30:20 -0400 Subject: kernel: hle_ipc: Foward declare KAutoObject --- src/core/hle/kernel/hle_ipc.cpp | 1 + src/core/hle/kernel/hle_ipc.h | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/core/hle/kernel/hle_ipc.cpp b/src/core/hle/kernel/hle_ipc.cpp index ca68fc325..cee96dd9b 100644 --- a/src/core/hle/kernel/hle_ipc.cpp +++ b/src/core/hle/kernel/hle_ipc.cpp @@ -15,6 +15,7 @@ #include "common/logging/log.h" #include "core/hle/ipc_helpers.h" #include "core/hle/kernel/hle_ipc.h" +#include "core/hle/kernel/k_auto_object.h" #include "core/hle/kernel/k_handle_table.h" #include "core/hle/kernel/k_process.h" #include "core/hle/kernel/k_readable_event.h" diff --git a/src/core/hle/kernel/hle_ipc.h b/src/core/hle/kernel/hle_ipc.h index a61870f8b..55e6fb9f7 100644 --- a/src/core/hle/kernel/hle_ipc.h +++ b/src/core/hle/kernel/hle_ipc.h @@ -17,7 +17,6 @@ #include "common/concepts.h" #include "common/swap.h" #include "core/hle/ipc.h" -#include "core/hle/kernel/k_auto_object.h" #include "core/hle/kernel/svc_common.h" union ResultCode; @@ -38,6 +37,7 @@ namespace Kernel { class Domain; class HLERequestContext; +class KAutoObject; class KernelCore; class KHandleTable; class KProcess; -- cgit v1.2.3