1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 19:37:35 +00:00

Kernel: Load executables on demand when symbolicating

Previously we would map the entire executable of a program in its own
address space (but make it unavailable to userspace code.)

This patch removes that and changes the symbolication code to remap
the executable on demand (and into the kernel's own address space
instead of the process address space.)

This opens up a couple of further simplifications that will follow.
This commit is contained in:
Andreas Kling 2020-03-02 10:40:40 +01:00
parent 055344f346
commit 678c87087d
4 changed files with 33 additions and 12 deletions

View file

@ -386,7 +386,11 @@ public:
Lock& big_lock() { return m_big_lock; }
const ELFLoader* elf_loader() const { return m_elf_loader.ptr(); }
struct ELFBundle {
OwnPtr<Region> region;
OwnPtr<ELFLoader> elf_loader;
};
OwnPtr<ELFBundle> elf_bundle() const;
int icon_id() const { return m_icon_id; }
@ -495,7 +499,6 @@ private:
FixedArray<gid_t> m_extra_gids;
RefPtr<ProcessTracer> m_tracer;
OwnPtr<ELFLoader> m_elf_loader;
WeakPtr<Region> m_master_tls_region;
size_t m_master_tls_size { 0 };