From 17bff999c80854d621a83ae7f39773342701b06b Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Fri, 14 Jul 2023 09:07:56 +0200 Subject: [PATCH] LibRegex: Remove redundant VERIFY in OpCode::argument() The bounds check here is already performed by the at() we're calling, and removing it appears to have non-trivial performance impact. --- Userland/Libraries/LibRegex/RegexByteCode.h | 1 - 1 file changed, 1 deletion(-) diff --git a/Userland/Libraries/LibRegex/RegexByteCode.h b/Userland/Libraries/LibRegex/RegexByteCode.h index 3ad660287e..46f50a9eb0 100644 --- a/Userland/Libraries/LibRegex/RegexByteCode.h +++ b/Userland/Libraries/LibRegex/RegexByteCode.h @@ -559,7 +559,6 @@ public: ALWAYS_INLINE ByteCodeValueType argument(size_t offset) const { - VERIFY(state().instruction_position + offset <= m_bytecode->size()); return m_bytecode->at(state().instruction_position + 1 + offset); }