Преглед на файлове

LibRegex: Reduce RegexMatcher's BumpAllocator chunk size

Before the BumpAllocator OOB access issue was understood and fixed, the
chunk size was increased to 8MiB as a workaround in commit:
27d555bab0d84913599cea3c4a6b0a0ed2a15b66.

The issue is now resolved by: 0f1425c895ace40fbb10d68a55eeb3a6354479d3.

We can reduce the chunk size to 2MiB, which has the added benefit of
reducing runtime of the RegExp.prototype.exec test.
Timothy Flynn преди 3 години
родител
ревизия
fea181bde3
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      Userland/Libraries/LibRegex/RegexMatcher.cpp

+ 1 - 1
Userland/Libraries/LibRegex/RegexMatcher.cpp

@@ -391,7 +391,7 @@ private:
         Node* previous { nullptr };
     };
 
-    UniformBumpAllocator<Node, true, 8 * MiB> m_allocator;
+    UniformBumpAllocator<Node, true, 2 * MiB> m_allocator;
     Node* m_first { nullptr };
     Node* m_last { nullptr };
 };