mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 10:48:11 +00:00
UserspaceEmulator: Inline some very hot functions
This improves the browser's load time on welcome.html by ~2%.
This commit is contained in:
parent
1b9a85e4f1
commit
da413a464a
6 changed files with 33 additions and 34 deletions
|
@ -185,4 +185,12 @@ private:
|
|||
FlatPtr m_signal_trampoline { 0 };
|
||||
};
|
||||
|
||||
ALWAYS_INLINE bool Emulator::is_in_malloc_or_free() const
|
||||
{
|
||||
return (m_cpu.base_eip() >= m_malloc_symbol_start && m_cpu.base_eip() < m_malloc_symbol_end)
|
||||
|| (m_cpu.base_eip() >= m_free_symbol_start && m_cpu.base_eip() < m_free_symbol_end)
|
||||
|| (m_cpu.base_eip() >= m_realloc_symbol_start && m_cpu.base_eip() < m_realloc_symbol_end)
|
||||
|| (m_cpu.base_eip() >= m_malloc_size_symbol_start && m_cpu.base_eip() < m_malloc_size_symbol_end);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue