Re: [v8-users] V8 Issue Tracker migration completed

2024-04-19 Thread Jakob Kummerow
...and if you're reading this mailing list, you probably prefer the URL that doesn't redirect you to Google's internal login page: https://issues.chromium.org/issues/new?component=1456824=0 If you ever come upon a "g-issues.chromium.org/somethingsomething" link, just edit out the "g-" prefix.

[v8-users] PSA: Posting now requires joining the list

2023-12-11 Thread Jakob Kummerow
Dear v8-users participants, In an attempt to mitigate this list's recent spam problem, we're going to restrict posting to members of the list, effective immediately. Please do feel encouraged to join the list (if you haven't already) if you'd like to continue to participate in conversations.

Re: [v8-users] Error in gsutil.py config while building V8

2023-10-20 Thread Jakob Kummerow
The linked instructions say: For Googlers - If you see Failed to fetch file or Login required errors > when running the hooks, try authenticating with Google Storage first by > running: gsutil.py config So if you're not a Googler, and/or if you're not seeing "Login required" errors when running

Re: [v8-users] Why is it not supported to cross-compile v8 for Android platform on Windows platform?

2023-10-09 Thread Jakob Kummerow
See: https://stackoverflow.com/questions/77253090/why-is-it-not-supported-to-cross-compile-v8-for-android-platform-on-windows-plat On Sun, Oct 8, 2023 at 11:19 AM Sakura Endo wrote: > "Android builds are only supported on Linux and Mac hosts." > There is such a sentence in the file

Re: [v8-users] Re: v8 build issue

2023-04-24 Thread Jakob Kummerow
Have you run `gclient sync` after updating your git branch? On Sat, Apr 22, 2023 at 7:27 AM ji qiu wrote: > It seems an issue related to RISC-V. > But, would you pls give a bit more detail about how to reproduce this > error? > For example, how did you get the code ? What's the commit id of

Re: [v8-users] why is this code running time different?

2023-03-23 Thread Jakob Kummerow
`longString[1]` is loop-independent and can hence be hoisted out of the loop. `longString[i]` actually has to be loaded from memory in each iteration. (I haven't spent the time to check whether that's really what's happening. Using `--print-opt-code`, or `--trace-turbo` and Turbolizer, you can

Re: [v8-users] changelog between V8 versions?

2023-01-26 Thread Jakob Kummerow
Here you go: https://chromium.googlesource.com/v8/v8/+log/branch-heads/10.7..branch-heads/10.8/?n=1000 Or you can use `git log` in a local checkout. On Thu, Jan 26, 2023 at 3:33 PM crdu...@gmail.com wrote: > I'm trying to figure out the easiest way to get a summary or detailed list > of

Re: [v8-users] Tracing object properties from HiddenClass

2022-11-14 Thread Jakob Kummerow
keys that ever come in but third one never > enters for some reason. I also hooked into SetProperty hoping it will go in > there but it never does. Is there any other function I can hook where I can > have a guarantee all property sets will go through? > > On Friday, November 11, 2022 at 2:49

Re: [v8-users] Tracing object properties from HiddenClass

2022-11-11 Thread Jakob Kummerow
onStringify() and printf()s the result to stdout. > On Fri, Nov 11, 2022 at 12:26 PM Jakob Kummerow > wrote: > >> Thanks! I found this StoreIC::Store() function just yesterday while >>> debugging in D8 and it works even without (--nouse-ic flag), even though I >>> hav

Re: [v8-users] Tracing object properties from HiddenClass

2022-11-11 Thread Jakob Kummerow
; would be appreciated. > Appending `.ToHandleChecked()` may be of use here (if the stringification doesn't throw), but yeah, invoking such functions in GDB tends to not work. > On Friday, November 11, 2022 at 11:47:33 AM UTC+1 Jakob Kummerow wrote: > >> Maps don't keep lists of the objects tha

Re: [v8-users] Tracing object properties from HiddenClass

2022-11-11 Thread Jakob Kummerow
Maps don't keep lists of the objects that use them. To find all objects that use a given map, you'd have to walk the entire heap to find all objects, and filter them by map. Considering your previous question, I'm not sure finding all objects that use a given map will actually be helpful. A

Re: [v8-users] V8 compile for cocos2dx android

2022-10-04 Thread Jakob Kummerow
Per crbug.com/v8/9665, which sounds vaguely related, try linking against libcompiler_rt, or provide your own implementation (similar to comment #14 on that bug, just for a different function). Android/x86 is not a combination we're regularly testing, so it's not surprising that there may be

Re: [v8-users] Options to disable specific optimizations in TurboFan?

2022-08-30 Thread Jakob Kummerow
format to a high-level IR graph at the beginning, and translating from a low-level IR graph to machine code at the very end. > > Thanks! Regards > > On Fri, Aug 26, 2022 at 1:58 AM Jakob Kummerow > wrote: > >> No, some Turbofan passes cannot be disabled, because they

Re: [v8-users] Options to disable specific optimizations in TurboFan?

2022-08-26 Thread Jakob Kummerow
No, some Turbofan passes cannot be disabled, because they are required. SimplifiedLowering is a great example -- it changes ("lowers") the graph to the format that subsequent passes require. On Fri, Aug 26, 2022 at 4:18 AM TL wrote: > I am curious whether there are any options for the 'd8' to

Re: [v8-users] test_call_v8

2022-08-10 Thread Jakob Kummerow
It appears that you're talking about an external project. V8 itself does not define "v8pp::call_v8". Maybe reading the comments in the source will help: https://github.com/pmed/v8pp/blob/master/v8pp/call_v8.hpp On Wed, Aug 10, 2022 at 10:28 AM jk_alan wrote: > There are sample codes in

Re: [v8-users] How to contribute a patch to V8

2022-08-01 Thread Jakob Kummerow
See https://v8.dev/docs/contribute. On Mon, Aug 1, 2022 at 2:36 PM Ivan Pizhenko < ivan.pizhenko.gene...@gmail.com> wrote: > Hi, > I want to contribute a small fix (like couple lines of code) to the V8 > build scripts for Windows. How can I do it? (Note that I am not a Google > employee or

Re: [v8-users] V8 crashing in Embeded application during creating v8 isolated object.

2022-06-27 Thread Jakob Kummerow
o initialize isolate object? > > Thank you > Siam > > On Fri, Jun 24, 2022 at 6:58 AM Jakob Kummerow > wrote: > >> AllocateRawOrFail(int size=-2133860350 <(213)%20386-0350>, ...) looks >> bad. Apparently that request is coming out of the snapshot... >

Re: [v8-users] V8 crashing in Embeded application during creating v8 isolated object.

2022-06-24 Thread Jakob Kummerow
AllocateRawOrFail(int size=-2133860350 <(213)%20386-0350>, ...) looks bad. Apparently that request is coming out of the snapshot... On Fri, Jun 24, 2022 at 2:41 AM Saad Al Abdullah wrote: > Hello, > I have aspnet core application and I create V8 isolate object for each > request and dispose

Re: [v8-users] [10.0.139.9] Compile error "C2280" with MSVC

2022-05-03 Thread Jakob Kummerow
Minor correction: `gm.py` is a powerful tool, but GN args must be set using `gn args out/` (for your , of course). On Tue, May 3, 2022 at 6:21 AM Ben Noordhuis wrote: > On Sun, May 1, 2022 at 3:46 PM Kazuya Hiruma wrote: > > > > I'm guessing what is wrong is /WX flag. I'm not sure how to turn

Re: [v8-users] Comment Removal

2022-05-01 Thread Jakob Kummerow
I'm not sure why this would reduce memory consumption in V8 -- naturally, V8's parser already disregards comments and whitespace, like any JS engine would. So I would say the right place for such functionality is a minifier/"uglifier" script that developers can run over their code before shipping

Re: [v8-users] Specify toolchain when use_custom_libcxx=false?

2022-02-14 Thread Jakob Kummerow
There are two related GN args: clang_base_path = "/usr" clang_use_chrome_plugins = false which I've successfully used to use the system-installed Clang on an arm64 device for which we have no prebuilt toolchain. I haven't seen the specific error you're reporting before though, so I'm not sure

Re: [v8-users] Context creation overhead

2021-11-29 Thread Jakob Kummerow
On Mon, Nov 29, 2021 at 5:07 PM Maik Riechert wrote: > Hi all, > > The CCF project (https://github.com/microsoft/CCF) is evaluating to use > V8 as JavaScript engine (currently QuickJS) for handling HTTP requests. > > One of the requirements we have is that each request should get a fresh >

Re: [v8-users] Cross-context object usage

2021-10-25 Thread Jakob Kummerow
See here: https://docs.google.com/document/d/1ux2XfRtiMhIl4Cjok6YLhE6Yh5Q20u84ai61PHFMggE/edit Also, why don't contexts within the same isolate share built-ins such as > Math et al? > So that one can do delete Math.max and any other s aren't bothered by that. (And also because functions have

Re: [v8-users] Re: Check failed: GetProcessWidePtrComprCage()->IsReserved() (9.4.146.13, Debian 11)

2021-10-19 Thread Jakob Kummerow
Most people on the team (as well as our build bots) build x64.debug builds on Debian regularly, so the fact that you're seeing failures there is surprising. You may have to investigate a bit. Looks like line 115 in isolate-allocator.cc should have created the reservation that the CHECK in line 137

Re: [v8-users] Smaller build: removing snapshot

2021-09-27 Thread Jakob Kummerow
Removing the snapshot is not possible. It contains many of the JavaScript built-in functions (e.g. Array.prototype.*), so V8 couldn't work without it. On Sun, Sep 26, 2021 at 2:20 PM MG wrote: > I am part of the Nativescript community. > There we use v8 to run all

Re: [v8-users] Compile 9.4 under Debian 11

2021-09-08 Thread Jakob Kummerow
Looks like something's messed up in your checkout. The 9.4.146.13 tag has no src/init/vm-cage.cc, and its BUILD.gn files don't refer to it, so I don't know why your ninja thinks it needs it. I'd try git checkout -f 9.4.146.13; gclient sync; gm x64.release. If that doesn't help, rm -rf

Re: [v8-users] Preliminary RFC: Stabilizing the V8 script compiler cached data format

2021-07-21 Thread Jakob Kummerow
In addition to the excellent technical points that Leszek explained, I just wanted to clarify additionally that we don't have a concept of "major releases 8 -> 9" etc. V8's version numbers are assigned by adding 0.1 every six weeks, rolling from x.9 to (x+1).0. There are *zero* technical or

Re: [v8-users] HandleScope / learning basic concepts.

2021-07-15 Thread Jakob Kummerow
A v8::HandleScope manages the lifetime of the backing store used by any handles/v8::Locals you create. It doesn't have anything to do with JavaScript variable scoping. A v8::Context::Scope is a convenience tool for making it easy to ensure your code has matching pairs of Context::Enter() and

Re: [v8-users] Function Call to JSON::Stringify is returning empty handle

2021-02-09 Thread Jakob Kummerow
The general pattern is that returned MaybeHandles (from any function, not just JSON::Stringify) are empty when an exception has been thrown by the operation. You can use a v8::TryCatch to catch this exception and inspect it, it'll include a helpful error message. On Tue, Feb 9, 2021 at 1:21 PM

Re: [v8-users] v8 arm64 crash

2020-12-16 Thread Jakob Kummerow
Wild guess: try searching for -DV8_COMPRESS_POINTERS in the archives of this list. On Sat, Dec 12, 2020 at 9:10 PM ibon wrote: > Hi folks. > > I have been trying to upgrade my app from v8 7.3 to 8.x. > The app is an android app, where an embedded v8 runs several different > games. >

Re: [v8-users] A list of optcodes for each bytecode

2020-08-17 Thread Jakob Kummerow
bytecodes.h is the right place; the list of bytecodes is generated by the following macro: // Enumeration of interpreter bytecodes. enum class Bytecode : uint8_t { #define DECLARE_BYTECODE(Name, ...) k##Name, BYTECODE_LIST(DECLARE_BYTECODE) #undef DECLARE_BYTECODE On Mon, Aug 17, 2020 at 5:03

Re: [v8-users] Re: CpuProfiler sampling and multiple threads

2020-08-03 Thread Jakob Kummerow
Yes, a (small?) CL to get sampling on Windows to parity with how it's already working on Linux sounds good. (I'm not familiar with the specifics of how sampling works or should work.) On Mon, Aug 3, 2020 at 1:58 PM Alex Kodat wrote: > OK, now I'm replying to myself a second time. Really

Re: [v8-users] Minimum gcc version to build v8 8.3

2020-06-30 Thread Jakob Kummerow
Probably 5.x. There is a recent commit that mentions "GCC versions older than 6 are still used by the CQ bots". We definitely don't support GCC 4.x any more. Most of our buildbots use Ubuntu Xenial (16.04 LTS) currently, so whatever GCC version is in there should definitely work -- looks like

Re: [v8-users] Date.now & new Date performance

2020-06-09 Thread Jakob Kummerow
; > On Monday, 8 June 2020 16:18:10 UTC+1, Jakob Kummerow wrote: >> >> Due to how complicated <https://tc39.es/ecma262/#sec-date-constructor> >> the Date constructor is, it is expected to be much slower than >> allocating an object. Beyond the sheer amount of st

Re: [v8-users] Date.now & new Date performance

2020-06-08 Thread Jakob Kummerow
(2019, 1, 1, 12, 0, 1, 1) x 2,636,300 ops/sec ±0.83% (65 runs > sampled) > > Date.UTC(2019, 1, 1, 12, 0, 1, 1) x 11,741,842 ops/sec ±0.79% (65 runs > sampled) > > > Source: https://stackblitz.com/edit/js-dvq8ri > > On Friday, 5 June 2020 20:14:02 UTC+1, Jakob Kummerow wrote:

Re: [v8-users] Date.now & new Date performance

2020-06-05 Thread Jakob Kummerow
Yes, getting the current time from the operating system is significantly slower than allocating a simple JS object like [1, 2, 3]. That's not going to change. As you can see, Date.now() is significantly faster than new Date(), so that's preferable when performance/overhead matters. Other than

Re: [v8-users] Official community?

2020-04-24 Thread Jakob Kummerow
You found it. On Fri, Apr 24, 2020 at 12:33 PM chopeace wrote: > Wondering if there's any official community for giving or receiving > technical support for v8 engine? > > -- > -- > v8-users mailing list > v8-users@googlegroups.com > http://groups.google.com/group/v8-users > --- > You received

Re: [v8-users] V8_31BIT_SMIS_ON_64BIT_ARCH

2020-04-15 Thread Jakob Kummerow
> > Is there any reason to use V8_31BIT_SMIS_ON_64BIT_ARCH or not when not > using compressed pointers? Smis are faster than any alternative, so 32-bit Smis potentially allow more code to benefit from the Smi advantage than 31-bit Smis. We separated the build flags mostly to be able to track the

Re: [v8-users] How to read and write local files?

2020-03-30 Thread Jakob Kummerow
> Am Sonntag, 29. März 2020 18:26:54 UTC+2 schrieb Jakob Kummerow: >> >> The "Read" and "Load" functions in the sample shell provide simple >> examples of how to interact with files. >> >> >> On Sat, Mar 28, 2020 at 6:50 PM Elangovan S w

Re: [v8-users] How to read and write local files?

2020-03-29 Thread Jakob Kummerow
The "Read" and "Load" functions in the sample shell provide simple examples of how to interact with files. On Sat, Mar 28, 2020 at 6:50 PM Elangovan S wrote: > You can write your own wrapper and expose it to JavaScript. That's the way > we do in our application. You can write class/function

Re: [v8-users] JS Optimizations - how much does the code generator assume?

2020-03-25 Thread Jakob Kummerow
Yes, V8's optimizing compiler performs "Common Subexpression Elimination". The number of available registers does matter a lot. We've seen cases where recomputing values when they are needed (somewhat counter-intuitively) yielded better performance than computing them once and keeping them

Re: [v8-users] Fast printing from WebAssembly in embedded V8

2020-03-23 Thread Jakob Kummerow
No, there is no way to write to stdout directly, and that's intentional. WebAssembly code can only use imported functions to communicate with the environment. The lowest-hanging fruit here is to move the HandleScope out of the loop. HandleScope creation/destruction is somewhat expensive, and you

Re: [v8-users] Segment fault when update v8..

2020-02-28 Thread Jakob Kummerow
6.8 is a year and a half before pointer compression though. Which also means that 6.8 is obsolete and unsupported. On Fri, Feb 28, 2020 at 12:14 PM Ben Noordhuis wrote: > On Fri, Feb 28, 2020 at 4:05 AM YQ Tian wrote: > > > > v8 version 6.8.275.32 > > > > Hi all! > > > > > > When I upgrade the

Re: [v8-users] Seg Fault Checking If a Value is a String

2020-02-26 Thread Jakob Kummerow
V8_31BIT_SMIS_ON_64BIT_ARCH is a dependency of V8_COMPRESS_POINTERS, but you don't need to set it separately, as it is implied by the latter. (They are split because we wanted to be able to test the former without the latter.) On Wed, Feb 26, 2020 at 4:13 AM Joel Scarfone wrote: > Looks like it

Re: [v8-users] Can V8 snapshots be turned off at run-time?

2020-02-04 Thread Jakob Kummerow
In snapshot-enabled builds of V8 (or Chromium), it is not possible to disable usage of that snapshot, because the data in the snapshot is required for operation, and the functionality required to create a snapshot (or, equivalently, to start up without a snapshot) is not a part of those binaries.

Re: [v8-users] Re: Segmentation fault when disposing of an isolate.

2019-12-20 Thread Jakob Kummerow
Does this happen outside of Valgrind too? Looks like the address in question was mmap'ed, so yeah, it's "not stack'd, malloc'd or (recently) free'd", but that doesn't mean it's invalid. On Fri, Dec 20, 2019 at 2:32 PM Tom Hanks wrote: > Some extra context, here is how the test program is being

Re: [v8-users] Is it possible to create multiple isolates in one thread?

2019-12-19 Thread Jakob Kummerow
Sure, a single thread can use as many Isolates as it wants. Most V8 API functions take an Isolate or a Context (which implies an Isolate) parameter to facilitate this. Things to keep in mind: - creating an Isolate is somewhat expensive, so creating millions of short-lived Isolates is not great

Re: [v8-users] V8 build error on the CentOS 7

2019-12-09 Thread Jakob Kummerow
On Fri, Dec 6, 2019 at 10:22 PM Ivan Pizhenko wrote: > Doesn't work. Seems like newer clang is required due to some options in > the command line. > > *error: unknown warning option '-Wno-implicit-int-float-conversion'; did > you mean '-Wno-float-overflow-conversion'? >

Re: [v8-users] V8 build error on the CentOS 7

2019-12-06 Thread Jakob Kummerow
e of them will fit instead of > clang. > > On Friday, December 6, 2019 at 2:50:53 PM UTC+2, Jakob Kummerow wrote: >> >> You can try adding: >> >> is_clang = false >> use_sysroot = false >> >> to args.gn, but do note that this configuration is not officially >

Re: [v8-users] V8 build error on the CentOS 7

2019-12-06 Thread Jakob Kummerow
You can try adding: is_clang = false use_sysroot = false to args.gn, but do note that this configuration is not officially supported. If it works, you're in luck; if it doesn't, then CentOS 7 is simply too old. (Side note: the recommended flow is to use "gn args " to edit the args, instead of

Re: [v8-users] Is "is_component_build" expected to work at all in v8 7.8?

2019-11-01 Thread Jakob Kummerow
Yes, the component build is expected to work for every version, and our buildbot thinks it does: https://ci.chromium.org/p/v8/builders/ci/V8%20Linux64%20-%20shared The component build is also the default in Debug mode, which most V8 developers compile/use every day. On Fri, Nov 1, 2019 at 1:00

Re: [v8-users] How can I resolve or workaround this undefined symbol, building V8 on Windows 10, MSVC++2017?

2019-10-30 Thread Jakob Kummerow
If I had to guess: unibrow::ToUppercase::Convert in src/strings/unicode.h needs a V8_EXPORT_PRIVATE annotation in order to support the specific combination of building (1) cctests (2) on Windows (3) with is_component_build = true and (4) with v8_enable_i18n_support = false. If that theory is

Re: [v8-users] Tips for SIMD optimization of code

2019-09-26 Thread Jakob Kummerow
V8 does not currently do any auto-vectorization of JavaScript code. SIMD support is coming to WebAssembly: https://github.com/WebAssembly/simd On Wed, Sep 25, 2019 at 11:15 PM Piyush Katariya wrote: > How aggressively V8 optimizes the JS code to translate into SIMD > instructions (AVX, SSE,

Re: [v8-users] How to opt V8 using build or runtime flags for maximum computation ?

2019-09-26 Thread Jakob Kummerow
We generally recommend the default configuration. The default settings are carefully calibrated for maximum performance in a wide variety of usage scenarios. If you're observing a specific issue, you can ask specifically (and with details!) about that; there may or may not be a way to address it

Re: [v8-users] V8 build failing

2019-09-26 Thread Jakob Kummerow
[0m [91m+ cp /go/src/github.com/Runscope/script-processor/v8.h > /go/v8-7.7/include/v8.h > [0m/go/v8-7.7 /go /go/src/github.com/Runscope/script-processor > [91m+ CXXFLAGS=-Wno-unused-function > + make i18nsupport=off native > [0m [91mmake: *** No rule to make target `native'. Stop. > [

Re: [v8-users] IsFunction() on v8::Name returns false

2019-09-26 Thread Jakob Kummerow
In addition to what Simon said: from a V8 API point of view, we have a strict type system and class hierarchy (this is C++ after all, not JavaScript). A v8::Name is a name, not a function. For a v8::Local key, it will and must always be the case that key->IsName() returns true, and

Re: [v8-users] V8 build failing

2019-09-25 Thread Jakob Kummerow
nk > /go/v8.tmp/v8/build/_gclient_gyp_EePdtR' returned non-zero exit status 128 in > /go/v8.tmp > > Traceback (most recent call last): > File "/go/depot_tools/metrics.py", line 267, in print_notice_and_exit > [0m [91myi

Re: [v8-users] V8 build failing

2019-09-25 Thread Jakob Kummerow
First off, version 3.28.71 is *very outdated*. It hasn't been touched in five years. If it suddenly stopped working for you, then that's certainly not due to a change in V8. Also, 3.28.71 is not a good version to pick. If you must use a five-year-old version, then you should at least pick

Re: [v8-users] NewDefaultPlatform() unresolved external symbol

2019-09-23 Thread Jakob Kummerow
Does it help if you follow the instructions ? Specifically the part where it suggests to build v8_monolith and then link against exactly that one library. Does #pragma comment(lib, "v8_libplatform.dll.lib") mean that you're actually linking against v8_libplatform? On

Re: [v8-users] Calling js functions in jitless (iOS)

2019-09-12 Thread Jakob Kummerow
CC author of that commit. Darin, do you have a full repro you can share? That would be useful for debugging. On Thu, Sep 12, 2019 at 4:36 PM Darin Dimitrov wrote: > I am embedding v8 in my iOS application and calling some js function: > > Local callback = ... > > std::vector> v8Args = ... > >

[v8-users] Re: [chromium-dev] How can i hook object creation in ignition interpreter?

2019-09-09 Thread Jakob Kummerow
[+v8-users, chromium-dev to BCC] There is no single bottleneck for JS object allocation; objects are created all over the place. As a starting point, you can look at all CodeStubAssembler::AllocateJS* and Factory::NewJS* functions. I don't know whether that set spans all JS object allocations,

Re: [v8-users] Snapshot blob includes java script code with comments

2019-09-03 Thread Jakob Kummerow
The snapshot will typically contain both the original JavaScript source and the bytecode for functions. Function.prototype.toString needs the source, so not including that in the snapshot would be a spec violation. On Tue, Sep 3, 2019 at 1:23 PM Oleg Beletski wrote: > I viewed content of the

Re: [v8-users] d8.exe crashed when running a script

2019-08-22 Thread Jakob Kummerow
Bug has already been filed: https://bugs.chromium.org/p/v8/issues/detail?id=9570 (not sure why it was closed and redirected to v8-users?) On Thu, Aug 22, 2019 at 10:49 AM Jakob Gruber wrote: > Sounds like a stack overflow in the regexp compiler while compiling a huge > pattern. Feel free to

Re: [v8-users] Does v8 preserve locality of objects that were pushed from new space to old space?

2019-08-20 Thread Jakob Kummerow
There is no guarantee that locality will be preserved. It depends on where there is available space in old-space. You might get lucky :-) (This is well known to be one of the drawbacks of generational moving GCs, but as far as I'm aware our experiments indicate that the benefits more than make up

Re: [v8-users] Installing plv8 in CENTOS

2019-08-08 Thread Jakob Kummerow
g 2019, at 6:29 PM, Jakob Kummerow wrote: > > I don't see an error. Why do you think there's an error? > > On Thu, Aug 8, 2019 at 11:42 AM Chong Kw wrote: > >> The line that i high lighted is an error ? >> >> >> >> On Thursday, 8 August 2019 17:37:23 UTC+8,

Re: [v8-users] Installing plv8 in CENTOS

2019-08-08 Thread Jakob Kummerow
I don't see an error. Why do you think there's an error? On Thu, Aug 8, 2019 at 11:42 AM Chong Kw wrote: > The line that i high lighted is an error ? > > > > On Thursday, 8 August 2019 17:37:23 UTC+8, Jakob Kummerow wrote: >> >> I see no error in that screenshot, only

Re: [v8-users] Installing plv8 in CENTOS

2019-08-08 Thread Jakob Kummerow
I see no error in that screenshot, only compiler output. Pro tip: you can copy-paste from terminals, no need to take screenshots. All that said, chances are nobody on this list knows what plv8 is or how it needs to be set up, so you'll probably find more help in that project's

Re: [v8-users] How to trace JavaScript function enter/exit event?

2019-08-07 Thread Jakob Kummerow
V8 already has a --trace flag that does precisely this. On Wed, Aug 7, 2019 at 4:06 PM Cong Zuo wrote: > Hey guys, I want to trace JavaScript function enter and exit events to > generate function calling graphs just like DTrace/SystemTap could do. > > e.g. > > 0 <- rl_getc > 0 <-

Re: [v8-users] Crash (v8::base::Abort()) if a script contains errors.

2019-08-05 Thread Jakob Kummerow
While you haven't posted the stack trace, I'm pretty sure it's not V8 that's crashing, but your code, specifically: v8::Local v = (...).ToLocalChecked(); > if (v.IsEmpty()) { A v8::Local is never empty (unless it's uninitialized). The v8::MaybeLocal that you get back from script->Run() can be

Re: [v8-users] Build for Android with libstdc++

2019-07-15 Thread Jakob Kummerow
On Mon, Jul 15, 2019 at 10:05 AM Jaemin Park wrote: > I built it with these settings: > # Build arguments go here. > # See "gn args --list" for available build arguments. > is_debug = true > android_full_debug = is_debug > is_component_build = false > target_os = "android" > target_cpu =

Re: [v8-users] What is IsolateAddressId::kCEntryFPAddress for?

2019-07-09 Thread Jakob Kummerow
e V8 code directly, for example, stack walk > in postmortem dump file and ETW? > I don't know. > On Tuesday, July 9, 2019 at 8:52:34 AM UTC-7, Jakob Kummerow wrote: >> >> On Tue, Jul 9, 2019 at 5:20 PM Thomson Tan wrote: >> >>> The stack iterator

Re: [v8-users] V8 garbage collector doesnt collect deleted Mat instances using OpenCV.js

2019-07-09 Thread Jakob Kummerow
The fiddle is broken ("createFrames" is not defined, "frames.push" is not a function, "deleteFrames" is never called; that's when I gave up); please fix it such that it actually reproduces the issue. On Tue, Jul 9, 2019 at 5:52 PM Zigmas Slušnys wrote: > I am reading a video and storing the Mat

Re: [v8-users] What is IsolateAddressId::kCEntryFPAddress for?

2019-07-09 Thread Jakob Kummerow
is one). > How to usually handle the frame for JS entry function if a full stackwalk > is needed? > See class EntryFrame in frames.h, in particular EntryFrame::GetCallerState, and compare it with what Generate_JSEntryVariant in builtins-x64.cc does. > On Tuesday, July 9, 2019 at

Re: [v8-users] What is IsolateAddressId::kCEntryFPAddress for?

2019-07-09 Thread Jakob Kummerow
The stack iterator needs to be able to skip over C++ frames on the stack. Information about the topmost C++ section is stored on the isolate (where else would you store it?), information about additional sections further down needs to be saved elsewhere. Storing it on the stack makes it easy for

Re: [v8-users] Building v8 without PIC

2019-07-03 Thread Jakob Kummerow
I'm afraid those flags are not configurable. You'll have to edit build/config/compiler/BUILD.gn (for -fPIC) and build/config/gcc/BUILD.gn and gni/v8.gni (for -pie) -- but none of the BUILD.gn files under src :-) Note that this is entirely independent of how you build V8; gm.py has nothing to do

Re: [v8-users] V8 Crash

2019-07-01 Thread Jakob Kummerow
The crash means you called .ToLocalChecked() on an empty MaybeLocal. If you run a Debug build, you should get line numbers, so you can find out where in your source code that is. That said, https://webrtc.github.io/adapter/adapter-latest.js looks like it's designed to run in a browser; if that's

Re: [v8-users] Keep v8 context alive for future reference

2019-06-27 Thread Jakob Kummerow
Could be a bug in valgrind, or a bug in V8. Getting a line number would be helpful, along with the exact version of V8. At a quick glance, I don't see any uninitialized variables in DeclarationScope::CheckConflictingVarDeclarations. On Thu, Jun 27, 2019 at 2:27 PM Austin Einter wrote: > I

Re: [v8-users] Override Global Date Object

2019-06-17 Thread Jakob Kummerow
How about deleting the default Date object before replacing it? On Mon, Jun 17, 2019 at 8:33 PM Joel Scarfone wrote: > Hi all! I want to customize a context to forge a different Date object > when running a script. I tried setting a function template on an object > template that would be used

Re: [v8-users] Question about build mode: release/debug/optdebug

2019-05-29 Thread Jakob Kummerow
It's complicated and for the details, you'll have to look at build configuration files (start with BUILD.gn and gni/v8.gni, if needed continue with generated .ninja files in the output directory), but the short answer is that the three build modes affect C++ compilation as follows: release: -O3

Re: [v8-users] gc and threading

2019-05-15 Thread Jakob Kummerow
> > I'm trying to improve some serialization code in NodeJS and was wondering > if this could be achieved by going down to the native code and using > multiple threads to parallelize the serialization of multiple objects. For > example, imagine we need to serialize 1K objects to JSON/OtherFormat -

Re: [v8-users] Microoptimizing message handling

2019-04-23 Thread Jakob Kummerow
Optimized compilation happens on a per-function basis. A large function with many branches (if/else or switch), some of which are only executed rarely, tends to cause repeated deoptimizations (some branches have been executed enough to make the function hot, it gets optimized, then one of the

Re: [v8-users] Re: Does 'eval' has the same performance as an explicit Script->Compile->Run pipeline?

2019-04-15 Thread Jakob Kummerow
For eval, two cases need to be distinguished: functions containing an eval statement, and functions defined inside eval'ed code. Consider: function foo() { /* lots of stuff... */ eval("function bar() { /* lots of stuff... */ }"); /* more stuff... */ } foo(); bar(); In this case, function

Re: [v8-users] About v8's closure( the [scope] )

2019-04-05 Thread Jakob Kummerow
Correct. On Fri, Apr 5, 2019 at 10:56 AM wrote: > Wow, its cool! So it means those variables in the same function may not > stored in the same place and we got those information before generate the > byteCode right? > > On Friday, April 5, 2019 at 4:24:56 PM UTC+8, Jakob

Re: [v8-users] About v8's closure( the [scope] )

2019-04-05 Thread Jakob Kummerow
So it seems that I guess right. But in which moment we do > that? Is that when the outer function finished or when we pre-parsing the > function itself ? > > On Thursday, April 4, 2019 at 5:55:43 PM UTC+8, Jakob Kummerow wrote: >> >> Yes, a closure's "context"

Re: [v8-users] Debug check failed when building x64.debug as static libraries on windows

2019-04-04 Thread Jakob Kummerow
w have a 2,1 giga bytes v8_monolith.lib! > > I now have to tell VS2017 to not compile iterator debugging in Debug mode, > but that's another story. > Do you think that not being able to set enable_iterator_debugging to true > is a "bug"? > > Le jeudi 4 avril 2019 1

Re: [v8-users] Debug check failed when building x64.debug as static libraries on windows

2019-04-04 Thread Jakob Kummerow
ks = true > v8_optimized_debug = false > is_component_build = false > v8_static_library = true > v8_enable_i18n_support = true > v8_use_external_startup_data = false > enable_iterator_debugging = true > > Le jeudi 4 avril 2019 13:07:50 UTC+2, Jakob Kummerow a écrit : >> >&g

Re: [v8-users] Debug check failed when building x64.debug as static libraries on windows

2019-04-04 Thread Jakob Kummerow
Which version of V8 is this? The x64.debug build on Windows works fine on our infrastructure . On Thu, Apr 4, 2019 at 12:33 PM DaManuell wrote: > D:\V8\v8>ninja -C out.gn\x64.debug v8 > ninja: Entering directory

Re: [v8-users] About v8's closure( the [scope] )

2019-04-04 Thread Jakob Kummerow
Yes, a closure's "context" (i.e. variables from its outer scope) is stored on the heap. On Thu, Apr 4, 2019 at 8:37 AM wrote: > I have a problem about v8's closure. The problem is that when the > caller function finished, it's stack frame shall dismissed, then how could > the callee

Re: [v8-users] about v8's Machine code

2019-04-01 Thread Jakob Kummerow
t 9:08:42 PM UTC+8, Jakob Kummerow wrote: >> >> Ignition does not produce executable machine code. It produces bytecode, >> which is then interpreted. Under certain circumstances, the bytecode is >> cached in Chrome to speed up repeated page loads. >> >> Does t

Re: [v8-users] about v8's Machine code

2019-04-01 Thread Jakob Kummerow
Ignition does not produce executable machine code. It produces bytecode, which is then interpreted. Under certain circumstances, the bytecode is cached in Chrome to speed up repeated page loads. Does that answer your question? On Mon, Apr 1, 2019 at 2:58 PM wrote: > I am wonder is that

Re: [v8-users] Possible reasons of Runtime_StackGuard

2019-03-13 Thread Jakob Kummerow
0736b7fffb4 > Builtins_CEntry_Return1_DontSaveFPRegs_ArgvOnStack_NoBuiltinExit > 0x00736b91d16c > 0x00735aea743c > Builtins_InterpreterEntryTrampoline 0x00736b870794 > And so on "Trampolines" > ... > > Any suggestion appreciated very much > Thank you > >

Re: [v8-users] Possible reasons of Runtime_StackGuard

2019-03-04 Thread Jakob Kummerow
Runtime_StackGuard is the mechanism by which execution of (interpreted or optimized) JavaScript code is interrupted by C++ code. From the next few stack frames you can deduce the reason an interruption was requested: generated code had performed enough allocations that it was time to do a round of

Re: [v8-users] Re: v8 console.log() help please

2019-02-05 Thread Jakob Kummerow
You can look at d8's console implementation for an example of how the built-in console.log can be hooked up. The ConsoleDelegate implementation is in src/d8-console .{h,cc}, and it's hooked up like so

Re: [v8-users] V8 optimizations causing spikes in execution times

2019-01-18 Thread Jakob Kummerow
Answering what I can: I changed my code from using a "while(true)" loop to calling "setImmediate" > every once in a while so that it would yield to the event loop, that way > the GC shouldn't interrupt a turn while it's executing. I didn't notice a > difference doing this. Not seeing a

Re: [v8-users] Compiling V8 with GCC 8.2

2019-01-18 Thread Jakob Kummerow
Please feel free to submit patches to fix things that are causing warnings in GCC. V8 is not being continuously tested on all GCC versions; I've made it warning-free on GCC 8 a couple of months ago, but it may well have regressed since then. On Fri, Jan 18, 2019 at 7:53 AM Wilfried Gösgens

Re: [v8-users] Python error when running gm.py: No module named termios

2018-12-18 Thread Jakob Kummerow
I finally got around to creating and landing this CL: https://chromium-review.googlesource.com/c/v8/v8/+/1382738 gm.py should now work on Windows. On Tue, Dec 4, 2018 at 8:42 PM Jakob Kummerow wrote: > If some third-party article or blog post has instructions that don't work, > you

Re: [v8-users] Re: bitwise OR overflowing in mips build

2018-12-10 Thread Jakob Kummerow
783383221 doesn't look like an overflowed integer, and in any case, I don't see how bitwise-OR can overflow. If I had to guess, I'd guess that's a heap pointer, and the reason you're seeing it is that something is off in the JS-to-C++ call, and presumably the wrong stack slot ends up being read

Re: [v8-users] Python error when running gm.py: No module named termios

2018-12-04 Thread Jakob Kummerow
If some third-party article or blog post has instructions that don't work, you should probably contact the author of that post. That said, building V8 on Windows is easy, just follow the instructions on v8.dev. In short: get depot_tools and put them in the path; fetch v8; cd v8; gclient sync; gn

Re: [v8-users] Python error when running gm.py: No module named termios

2018-11-28 Thread Jakob Kummerow
...and gm.py is careful to only use pty on Linux. On other platforms it has the "import" statement but doesn't do anything with it. What platform (operating system, Python version) is this happening on? In my experience, gm.py works fine with the default Python installations on recent-ish Linux,

Re: [v8-users] Cannot build V8 with gclient/gn

2018-11-26 Thread Jakob Kummerow
Yes, the official V8 build instructions don't work on FreeBSD. That's because nobody cared enough to make it work. Do you? You can look at whatever Node is doing to build V8 on FreeBSD -- I believe they have a solution. Feel free to submit a patch to the documentation (via GitHub PR to v8.dev

  1   2   3   4   5   6   >