mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-02 23:56:06 +00:00
LibWasm: ALWAYS_INLINE some very hot functions
These function couldn't be inlined before because the compiler would've started flagging invalid paths in Variant as maybe-uninitialized.
This commit is contained in:
parent
d3db45c60b
commit
aa2916c21b
Notes:
sideshowbarker
2024-07-18 12:31:48 +09:00
Author: https://github.com/alimpfard
Commit: aa2916c21b
Pull-request: https://github.com/SerenityOS/serenity/pull/7950
3 changed files with 17 additions and 14 deletions
|
@ -472,10 +472,10 @@ public:
|
|||
Stack() = default;
|
||||
|
||||
[[nodiscard]] ALWAYS_INLINE bool is_empty() const { return m_data.is_empty(); }
|
||||
FLATTEN void push(EntryType entry) { m_data.append(move(entry)); }
|
||||
FLATTEN auto pop() { return m_data.take_last(); }
|
||||
FLATTEN auto& peek() const { return m_data.last(); }
|
||||
FLATTEN auto& peek() { return m_data.last(); }
|
||||
ALWAYS_INLINE void push(EntryType entry) { m_data.append(move(entry)); }
|
||||
ALWAYS_INLINE auto pop() { return m_data.take_last(); }
|
||||
ALWAYS_INLINE auto& peek() const { return m_data.last(); }
|
||||
ALWAYS_INLINE auto& peek() { return m_data.last(); }
|
||||
|
||||
ALWAYS_INLINE auto size() const { return m_data.size(); }
|
||||
ALWAYS_INLINE auto& entries() const { return m_data; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue