A STUDY OF THE PERFORMANCE AND OPTIMIZATION OF MODERN JAVASCRIPT DATA STRUCTURES AND METHODS: FROM BASIC COLLECTIONS TO ECMASCRIPT 2025 STANDARDS

Authors

DOI:

https://doi.org/10.28925/2663-4023.2026.34.1283

Keywords:

JavaScript, V8 JIT compiler, Maglev, data structures, algorithm performance, ECMAScript 2025, iterators, Set collections, Map collections, memory optimization

Abstract

This paper presents an exhaustive and profound analysis of the evolution of data structures, their processing algorithms, and iterative methods in the JavaScript programming language. The research encompasses the fundamental changes that have occurred within the ecosystem since the publication of previous baseline performance evaluations in 2021, expanding the focus from simple comparisons of arrays and sets to a comprehensive analysis of memory management, JIT compiler architecture, and the latest ECMAScript 2023–2025 specifications. This work serves as a modern re-evaluation of performance concepts, providing a substantive answer to the question regarding the necessity of updating classical benchmarks: in the contemporary context, obsolete optimization approaches may not only be inefficient but can also lead to critical failures in high-load systems. The unique value of this study lies in the detailed deconstruction of the V8 engine's architectural innovations, specifically the introduction of the Maglev mid-tier JIT compiler, which has radically altered the execution profile of hot code by providing rapid optimization without significant profiling latency.

A distinct and significant contribution of this article is the resolution of the previously documented issue regarding the inability to allocate Set or Map collections exceeding one hundred million elements. The study provides precise mathematical and architectural proof of the V8 engine's hardware limitations, which enforce a strict limit of 224 (approximately 16.7 million) elements due to the operational specifics of the FixedArray object and the mandatory hash table load factor. Based on the author's own experimental data, the performance of novel immutable operations (such as the toSorted method, introduced in ES2023) is examined in detail. Furthermore, considerable attention is devoted to the latest set algebra methods (Set.prototype.union, intersection, difference), standardized in ES2024. It is empirically proven that native implementations of these methods accelerate union operations by up to 5.8 times compared to classical polyfills, effectively optimizing hash collisions at a low level. The paper also profoundly analyzes the breakthrough efficiency of lazy iterators (Iterator Helpers), ratified in the ES2025 standard. The author's empirical data corroborates that the utilization of lazy evaluation is capable of halving peak random-access memory consumption during the processing of hyper-large arrays, while also revealing a non-obvious paradox of aggressive garbage collection on medium-sized datasets. The report concludes with an in-depth profiling of object degradation during dynamic mutations, providing software engineers with empirically substantiated criteria for selecting data structures when designing high-load server-side and client-side systems.

Downloads

Download data is not yet available.

References

Яскевич, В. (2021). Порівняння часу доступу до даних, організованих у різні структури мови JavaScript. У В. Абрамов, М. Бойко, Д. Бодненко та ін. (Ред.), Теоретичні та практичні аспекти використання математичних методів та інформаційних технологій в освіті й науці (с. 246-253). Київ: Київський університет імені Б. Грінченка.

V8 Team. (2023, December 5). Maglev - V8's fastest optimizing JIT. V8 Dev Blog. Retrieved from https://v8.dev/blog/maglev

V8 Team. (2025, February 25). Turbocharging V8 with mutable heap numbers. V8 Dev Blog. Retrieved from https://v8.dev/blog/mutable-heap-number

TC39. (2023). ECMAScript 2023 language specification. Ecma International.

TC39. (2024). ECMAScript 2024 language specification. Ecma International.

TC39. (2025). ECMAScript 2025 language specification. Ecma International.

Node.js Foundation. (2024, April 24). Node.js 22 is now available! Node.js Blog. Retrieved from https://nodejs.org/en/blog/announcements/v22-release-announce

Chromium Bug Tracker. (2021). Issue 11852: Maximum number of entries in a Map. Retrieved from https://bugs.chromium.org/p/v8/issues/detail?id=11852

MDN Web Docs. (2025). Set - JavaScript. Mozilla. Retrieved from https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set

PortSwigger. (2025). Prototype pollution. Web Security Academy. Retrieved from https://portswigger.net/web-security/prototype-pollution

Downloads


Abstract views: 8

Published

2026-09-24

How to Cite

Mashkina, I., Nosenko, T., Yaskevych, V., & Yaskevych, Y. (2026). A STUDY OF THE PERFORMANCE AND OPTIMIZATION OF MODERN JAVASCRIPT DATA STRUCTURES AND METHODS: FROM BASIC COLLECTIONS TO ECMASCRIPT 2025 STANDARDS. Electronic Professional Scientific Journal «Cybersecurity: Education, Science, Technique», 2(34), 169–181. https://doi.org/10.28925/2663-4023.2026.34.1283

Most read articles by the same author(s)