Questions tagged [v8]

V8 serves as the open-source JavaScript engine for Google.

npm release error: Out of memory - JS Allocation failed due to process overload

After numerous attempts, here is the outcome of my efforts to publish using npm: An error occurred in ../deps/v8/src/handles.h, line 48 CHECK(location_ != NULL) failed ==== C stack trace =============================== 1: V8_Fatal 2: v8::String::NewEx ...

Encountered an error stating 'WeakCallbackData' template does not exist in the 'v8' namespace while trying to install npm packages

There are some issues with installing certain packages that rely on https://www.npmjs.com/package/fibers, such as iron-meteor. The homepage of fibers advises meteor users to take a specific action, but it may not be very helpful. One suggestion provided ...

What is the best method for establishing a connection between NodeJS and PostgreSQL?

I'm having trouble figuring out the correct way to connect a PostgreSQL pool in my NodeJS application. I am using Express with Router, and all of my handlers are located in different files. Many people recommend creating a separate file for the DB connec ...

Virtual machines have encountered issues when attempting to utilize setTimeout within the browser with vm.runInNewContext

When running a JS script using the vm module in a browser, the following details are included: vm.runInNewContext(codeToEval, sandboxObject); Although interval methods like setTimeout and setInterval do not work, even when exposed in the sandboxObject cr ...

Differences between ClosureFeedbackCellArray and FeedbackVector in the V8 engine

Can you explain the distinction between ClosureFeedbackCellArray and FeedbackVector within V8? What steps are necessary to initiate the shift from ClosureFeedbackCellArray to FeedbackVector? What is the significance of the InterruptBudget attribute found ...

The concept of overloading operators in V8

Here's a question that I've been pondering, but couldn't seem to find any answers for on Google. While it may not be achievable in pure JavaScript, let's say I'm developing a container class in V8 and then returning that class bac ...

Can the V8 JavaScript engine made by Google be used on iOS devices?

Is V8 compatible with iOS? If not, what embeddable JavaScript engine would you suggest? UPDATE: We will only be using it for internal scripting purposes, rather than in combination with HTML rendering. ...

Is JavaScript parsed by Node.js before being passed to V8's engine?

Is it accurate to say that Node.js has its own parser and interpreter since V8 does not recognize terms like "require" and "setTimeout"? This would mean that Node.js identifies the non-JavaScript tokens and processes them before passing the rest of the c ...

What is the difference in memory usage for JavaScript objects between Node.js and Chrome?

It's puzzling to me why the size of the heap is twice as large as expected. I meticulously constructed a binary tree with perfection. I suspect v8 recognizes that each node consists of 3 fields. function buildTree(depth) { if (depth === 0) return null; ...

Is there a performance benefit to using node.js over client-side JavaScript in comparison to Chrome/V8?

Currently, I am working on a client-side javascript application for image manipulation. However, some of the operations are running quite slowly in the browser, taking about 2-3 seconds to complete. To address this issue, I am considering implementing a s ...

Error message stating: "Node.js 'readline' - Mark-compacts near heap limit are not effective. Allocation failed."

Here's the process I'm following in the code: Primarily, I am engaging in web scraping tasks. I start by reading a text file containing approximately 3500 links. Next, I iterate through each link, filter out the ones I need, and make a request to retriev ...

What is V8's approach to managing dictionaries?

After attending V8 presentations, it became clear to me that it optimizes constructions such as the one below by tagging a type object: function Point(x, y) { this.x = x; this.y = y; } I am curious about what happens if I were to return an object (JS ...

Are there any solutions for the malfunctioning v8 date parser?

The V8 Date parsing functionality is not functioning properly: > new Date('asd qw 101') Sat Jan 01 101 00:00:00 GMT+0100 (CET) I have attempted to use a delicate regular expression like the following: \d{1,2} (jan|feb|mar|may|jun|jul|a ...

Understanding the time complexity of Object.entries()

Is the complexity of Object.entries() in JavaScript known? According to information from this question, it seems like it could possibly be O(n) if implemented by collecting keys and values as arrays and then combining them together? ...

ALERT: the SweeperThread task with process ID <pid> has been stalled for over two minutes

Encountering a peculiar issue when running a simple node process in a container, causing it to become defunct. Here is what shows up in the kernel log: Mar 21 19:07:08 ip-10-0-2-233 kernel: [26336450.745710] INFO: task v8:SweeperThrea:2569 blocked for mor ...

``Eclipse: Mastering the Ins and Outs of Running and Trou

I am having an issue running a node.js project locally and setting up a debugging session. Typically, I would use the "debug as" feature in Eclipse to run a node project with debugging enabled. However, after starting the debugging session, nothing seems t ...