[v8-users] Repeated module evaluation.

2019-02-12 Thread Jane Chen
Embedding v8 6.7. I found the following test in test-modules.cc: CHECK(module->Evaluate(env.local()) .ToLocalChecked() ->StrictEquals(v8_str("gaga"))); CHECK_EQ(Module::kEvaluated, module->GetStatus()); CHECK(module->Evaluate(env.local()).ToLocalChecked()->

[v8-users] Anyway to plug in embedder's version of ICU?

2019-01-29 Thread Jane Chen
Embedding v8 6.7. Would like to use the ICU library built with custom flags and run v8 unit tests. What is the best way to do that? Thanks in advance. -- -- v8-users mailing list v8-users@googlegroups.com http://groups.google.com/group/v8-users --- You received this message because you are

[v8-users] Static icu libraries?

2019-01-09 Thread Jane Chen
Is there a way to build static libraries of icu from v6.7 version of v8? If so, how? -- -- v8-users mailing list v8-users@googlegroups.com http://groups.google.com/group/v8-users --- You received this message because you are subscribed to the Google Groups "v8-users" group. To unsubscribe fr

Re: [v8-users] Any way to reset global object for context after context is created?

2019-01-03 Thread Jane Chen
w the embedder to set properties on the module namespace object, so that each module has its own isolated variable bindings. Is that possible? On Wednesday, January 2, 2019 at 9:55:26 PM UTC-8, Jane Chen wrote: > > Hi Ben, > > I checked out Module API on v8 6.7 and it was working great, e

[v8-users] Module::ResolveCallback specifier parameter.

2019-01-03 Thread Jane Chen
Referring to test-modules.cc in v8 6.7, is the following part of the module standard? import {a, b} from 'export var a = 1; export let b = 2'; If so, how do I differentiate a module definition from a module name/path? -- -- v8-users mailing list v8-users@googlegroups.com http://groups.google.

Re: [v8-users] Any way to reset global object for context after context is created?

2019-01-02 Thread Jane Chen
anyway to do that? Thanks a lot! On Saturday, May 12, 2018 at 4:38:15 AM UTC-7, Ben Noordhuis wrote: > > On Sat, May 12, 2018 at 6:42 AM, Jane Chen > wrote: > > Thanks Ben. > > > > I want to re-use my context for performance reasons, but some JavaScript > > p

[v8-users] Re: How to build x64.release without debug info?

2018-12-29 Thread Jane Chen
alse) } With symbol_level=1, the size for libv8.so is only slightly higher than no symbols: 24910336 Thanks again! On Thursday, December 27, 2018 at 4:39:19 PM UTC-8, Jane Chen wrote: > > Embedding v8 6.7 using gcc 4.8.5 on RedHat 7. > > Building v8 optimized build with gn and ninj

[v8-users] Re: How to build x64.release without debug info?

2018-12-29 Thread Jane Chen
That worked! Thanks! The size difference is big. For example: libv8.so, version 6.7, with debug info, 565773459, without debug info, 15134520. On Thursday, December 27, 2018 at 4:39:19 PM UTC-8, Jane Chen wrote: > > Embedding v8 6.7 using gcc 4.8.5 on RedHat 7. > > Building

[v8-users] Re: How to handle module not found in v8::Module::ResolveCallback to avoid v8 crashes.

2018-12-28 Thread Jane Chen
Please disregard. Both cases work fine for me now. On Friday, December 28, 2018 at 12:15:48 PM UTC-8, Jane Chen wrote: > > Embedding v8 6.7, open to upgrade if necessary. > > I modified v8 shell.cc to experiment with the new Module API and am trying > to figure out how

[v8-users] Re: How to handle module not found in v8::Module::ResolveCallback to avoid v8 crashes.

2018-12-28 Thread Jane Chen
Attached patches to shell.cc. On Friday, December 28, 2018 at 12:15:48 PM UTC-8, Jane Chen wrote: > > Embedding v8 6.7, open to upgrade if necessary. > > I modified v8 shell.cc to experiment with the new Module API and am trying > to figure out how to handle error conditions wh

[v8-users] How to handle module not found in v8::Module::ResolveCallback to avoid v8 crashes.

2018-12-28 Thread Jane Chen
Embedding v8 6.7, open to upgrade if necessary. I modified v8 shell.cc to experiment with the new Module API and am trying to figure out how to handle error conditions while resolving a module. If the resolve callback calls v8::Isolate::throwException, I get: # # Fatal error in ../../src/api.

[v8-users] How to build x64.release without debug info?

2018-12-27 Thread Jane Chen
Embedding v8 6.7 using gcc 4.8.5 on RedHat 7. Building v8 optimized build with gn and ninja with the following arguments: gn gen out.gn/x64.release --args='is_debug=false is_official_build=true is_component_build=true is_cfi=false is_clang=false use_custom_libcxx=false use_sysroot=false treat_w

[v8-users] Anyway to specify the gcc location in gn configuration?

2018-12-20 Thread Jane Chen
When I build v8 with gn and ninja on RedHat7, I'd like to specify the location of gcc so that it doesn't use the default one. Is it something specifiable through the gn configuration? Thanks! -- -- v8-users mailing list v8-users@googlegroups.com http://groups.google.com/group/v8-users --- Y

Re: [v8-users] v8 version to upgrade to.

2018-06-04 Thread Jane Chen
Thanks Ben! Last time when we upgraded to 5.3, we used gcc 4.8 on Linux, VS 2015 on Windows to compile v8 and our own product. Do we need to use a higher version of compiler this time? On Monday, June 4, 2018 at 1:09:33 AM UTC-7, Ben Noordhuis wrote: > > On Mon, Jun 4, 2018 at 2:36 AM

[v8-users] v8 version to upgrade to.

2018-06-03 Thread Jane Chen
I am making plans to upgrade v8 for our next major release. We are currently running 5.3. It looks like that the current stable release is 6.7. Is this a good version to upgrade to? Is the module API ready to be used? Any significant incompatibilities from version 5.3 that we should be awa

Re: [v8-users] Any way to reset global object for context after context is created?

2018-05-11 Thread Jane Chen
enclosing the script with {}. Do you see any issue with doing it? Is there any better way to do so? On Friday, May 11, 2018 at 5:50:07 AM UTC-7, Ben Noordhuis wrote: > > On Thu, May 10, 2018 at 10:24 PM, Jane Chen > wrote: > > Embedding v8 v5.3. > > > > Is there any

[v8-users] Any way to reset global object for context after context is created?

2018-05-10 Thread Jane Chen
Embedding v8 v5.3. Is there any way to reset global object for a context so that the context can be re-used? How is Context::DetachGlobal() is meant to be used? Thanks, Jane -- -- v8-users mailing list v8-users@googlegroups.com http://groups.google.com/group/v8-users --- You received this

Re: [v8-users] v8 crash with weak handles.

2017-07-17 Thread Jane Chen
emory corruption when leaving a weak handle un-reset. Why is that? On Monday, July 17, 2017 at 1:18:29 AM UTC-7, Ben Noordhuis wrote: > > On Mon, Jul 17, 2017 at 3:15 AM, Jane Chen > wrote: > > Ben, > > > > Can PersistentBase::Reset() be called from a different thread f

Re: [v8-users] v8 crash with weak handles.

2017-07-16 Thread Jane Chen
My question is if one thread is calling PersistentBase::Reset() on a weak handle while another thread is running garbage collection, is it possible to cause memory corruption? On Sunday, July 16, 2017 at 6:15:16 PM UTC-7, Jane Chen wrote: > > Ben, > > Can PersistentBase::Reset() be

Re: [v8-users] v8 crash with weak handles.

2017-07-16 Thread Jane Chen
Ben, Can PersistentBase::Reset() be called from a different thread from which the isolate is attached to? Is PersistentBase::Reset() thread-safe? Jane On Thursday, July 13, 2017 at 12:59:13 PM UTC-7, Ben Noordhuis wrote: > > On Thu, Jul 13, 2017 at 12:40 AM, Jane Chen > wrote: >

Re: [v8-users] v8 crash with weak handles.

2017-07-13 Thread Jane Chen
3 PM UTC-7, Ben Noordhuis wrote: > > On Thu, Jul 13, 2017 at 12:40 AM, Jane Chen > wrote: > > Embedding v8 5.3. > > > > Seeing a crash if I have weak handles in many isolates: > > > > Thread [51] 27257 [core: 6] (Suspended : Signal : SIGILL:Illegal

[v8-users] v8 crash with weak handles.

2017-07-12 Thread Jane Chen
Embedding v8 5.3. Seeing a crash if I have weak handles in many isolates: Thread [51] 27257 [core: 6] (Suspended : Signal : SIGILL:Illegal instruction) v8::base::OS::Abort() at platform-posix.cc:240 0x75f078a1 V8_Fatal() at logging.cc:116 0x75f02d88 v8::internal::GlobalHandles::Nod

Re: [v8-users] ICU data file missing?

2017-03-13 Thread Jane Chen
I used to do it without specifying the file path for icudtl.dat. Now I realize it's required. So passing in the file path fixed it. Thanks a lot! On Sunday, March 12, 2017 at 12:55:51 AM UTC-8, Ben Noordhuis wrote: > > On Sun, Mar 12, 2017 at 4:03 AM, Jane Chen > wrote: &g

[v8-users] ICU data file missing?

2017-03-11 Thread Jane Chen
Embedding v8 5.3. This causes v8 to crash: ().toLocaleString(); 2017-03-07 08:24:07.362 Critical: # Fatal error in , line 0 2017-03-07 08:24:07.362 Critical: # Failed to create ICU number format, are ICU data files missing?2017-03-07 08:24:07.362 Critical: #2017-03-07 08:24:07.362 Cri

[v8-users] Implication of the context parameter in v8::Object::Set().

2017-01-17 Thread Jane Chen
Why does v8::Object::Set() takes a context parameter now? Does it mean that if an object is created in one context, it can only be used in that context? Thanks. -- -- v8-users mailing list v8-users@googlegroups.com http://groups.google.com/group/v8-users --- You received this message becaus

Re: [v8-users] Memory leak from disposed isolates?

2016-12-15 Thread Jane Chen
I found the memory leak is caused by the following two flags: gdbjit_full and harmony rest parameters. Removing them fixed the problem. Thanks Ben for your help. On Wednesday, December 14, 2016 at 11:36:06 PM UTC-8, Jane Chen wrote: > > I did. I didn't find anything related to isola

Re: [v8-users] Memory leak from disposed isolates?

2016-12-14 Thread Jane Chen
> > On Wed, Dec 14, 2016 at 2:47 AM, Jane Chen > wrote: > > For experiment, I just changed my implementation to always dispose and > > recreate isolates after each JavaScript execution. I can easily > reproduce a > > memory leak and my server process runs out

Re: [v8-users] Memory leak from disposed isolates?

2016-12-13 Thread Jane Chen
of requests. On Tuesday, December 13, 2016 at 10:35:40 AM UTC-8, Jane Chen wrote: > > Thanks Ben. I'm testing this on Linux. RH7 VM and Fedora 20. It's good > to know that you haven't seen this yourself. > I am seeing it when I dispose the isolate only when

Re: [v8-users] Memory leak from disposed isolates?

2016-12-13 Thread Jane Chen
02:00:02 PM 29851432 2929984 8.94 13224 696908 15415752 37.44 1416408 386944 0 I'll try with a different test to dispose and recreate isolates that don't have issues with GC. I'll report back. On Tuesday, December 13, 2016 at 4:34:39 AM UTC-8, Ben Noordhuis wrote: > > On Tue, De

[v8-users] Memory leak from disposed isolates?

2016-12-12 Thread Jane Chen
Related to this thread: https://groups.google.com/forum/#!topic/v8-users/deYE9pzK9b8 I am having some difficulty with garbage collection in v8 5.3. As a result, I do the following after running a JavaScript request: 1) ContextDisposedNotification 2) IdleNotificationDeadline 3) If uncollected

Re: [v8-users] Garbage collections.

2016-12-08 Thread Jane Chen
environment, and I haven't been able to reproduce with a debug build. On Thursday, December 8, 2016 at 2:14:32 AM UTC-8, Ben Noordhuis wrote: > > On Thu, Dec 8, 2016 at 12:35 AM, Jane Chen > wrote: > > Just upgraded v8 from 4.6 to 5.3 and found a new behavior: garbage > >

[v8-users] Garbage collections.

2016-12-07 Thread Jane Chen
Just upgraded v8 from 4.6 to 5.3 and found a new behavior: garbage collection can happen in a background thread after ContextDisposedNotification and IdleNotificationDeadline return. My idleNotificationDeadline runs in a loop with 1sec increments, and it typically comes out after 1 or 2 itera

[v8-users] Segfault calling v8::Persistent::Reset.

2016-12-01 Thread Jane Chen
Embedding v8 5.3. Seeing a segfault in our stress test: Critical: #6 0x7fbf3f6c0173 in v8::internal::GlobalHandles::Node::Release() () from lib/libv8.so This happens when v8::Persistent::Reset is called. Has anyone else seen this? Any clues on what might be wrong? Thanks. -- -- v8-u

[v8-users] Segmentation fault in v8 GC.

2016-11-19 Thread Jane Chen
Embedding v8 4.6.88. Got a segfault during stress test of my app: 2016-11-19 20:54:26.933 Critical: Segmentation fault in thread 0x7efbf9400700 2016-11-19 20:54:26.933 Critical: Thread 68 (Thread 0x7efbf9400700 (LWP 6602)): 2016-11-19 20:54:26.933 Critical: #0 0x00311ca0f279 in waitpid

[v8-users] CPU profiling result contains frames from outer context.

2016-11-19 Thread Jane Chen
Embedding v8 5.3. I have a JavaScript function prof.eval which is implemented through a callback function that creates a fresh v8 context, starts CPU profiling, evaluates the inner script, stops profiling and returns profiling result. The profiling result contains frames calling prof.eval in t

Re: [v8-users] libstdc++ from gcc4.6 used to build ICU and v8?

2016-11-15 Thread Jane Chen
I'm facing a similar issue on Mac. Any pointers to the mac build script which includes any incompatible dependency? Thanks! On Saturday, November 12, 2016 at 9:21:32 PM UTC-8, Jane Chen wrote: > > Thanks Jochen. This did it for me: > > diff --git a/gypfiles/standalon

Re: [v8-users] libstdc++ from gcc4.6 used to build ICU and v8?

2016-11-12 Thread Jane Chen
rch%': '<(target_arch)', On Saturday, November 12, 2016 at 2:36:12 PM UTC-8, Jochen Eisinger wrote: > > We're working on upgrading the sysroot, however, I'm not aware of any > documentation on how to do that, sorry > > On Fri, Nov 11, 2016 at 3:16 PM J

Re: [v8-users] libstdc++ from gcc4.6 used to build ICU and v8?

2016-11-11 Thread Jane Chen
: > > This is because the sysroot (in build/linux/) is outdated. I filed > crbug.com/661506 to track this > > On Tue, Nov 1, 2016 at 4:41 PM Jane Chen > > wrote: > >> I'm investigating a crash in a debug build of our app embedding v8 >> 5.3-lkgr and not

Re: [v8-users] v8 bootstrap error when creating a context.

2016-11-11 Thread Jane Chen
Thanks Ben. You were exactly right. Fixing it now... On Friday, November 11, 2016 at 12:35:56 AM UTC-8, Ben Noordhuis wrote: > > On Fri, Nov 11, 2016 at 5:40 AM, Jane Chen > wrote: > > Embedding v8 5.3. Running code to create a context and execute the same > > Java

[v8-users] v8 bootstrap error when creating a context.

2016-11-10 Thread Jane Chen
Embedding v8 5.3. Running code to create a context and execute the same JavaScript code in a loop. After thousands of iterations, I get "Exception thrown during bootstrapping". Here's the stack: 51 v8::internal::ReportBootstrappingException() /space/projects/v8-git/v8/src/isolate.cc:960 0x7

Re: [v8-users] libstdc++ from gcc4.6 used to build ICU and v8?

2016-11-10 Thread Jane Chen
his > > On Tue, Nov 1, 2016 at 4:41 PM Jane Chen > > wrote: > >> I'm investigating a crash in a debug build of our app embedding v8 >> 5.3-lkgr and notice libstdc++ from gcc4.6 is included and referenced from >> some of the makefiles to build ICU and v8, althoug

[v8-users] Re: Different stack between strict and sloppy mode.

2016-11-09 Thread Jane Chen
t... we indeed also > changed the implementation of stack traces a bit between 4.6 and 5.3. A > (preferably reduced) repro would be great to find out what exactly is going > on. > > Cheers, > > Yang > > > > On Tuesday, November 1, 2016 at 4:19:35 PM UTC+1, Jan

[v8-users] libstdc++ from gcc4.6 used to build ICU and v8?

2016-11-01 Thread Jane Chen
I'm investigating a crash in a debug build of our app embedding v8 5.3-lkgr and notice libstdc++ from gcc4.6 is included and referenced from some of the makefiles to build ICU and v8, although v8 5.3-lkgr requires gcc 4.8 or above to build on Linux. Am I missing something while building v8?

[v8-users] Different stack between strict and sloppy mode.

2016-11-01 Thread Jane Chen
Embedding v8 5.3. The embedding application allows JavaScript programs to import other library modules similar to Node.js require. I noticed a change of behavior after upgrading from v8 4.6.88 to 5.3. That is, if the imported library module is in strict mode, the stack trace of a function ca

[v8-users] Try-Catch block scope and callback.

2016-10-24 Thread Jane Chen
Embedding v8 5.3. In my embedding application, the user can make some updates and the updates are committed as one transaction when the script exits. When one statement throws an error which is caught by a try-catch block, the scope of the try-catch block determines the aborted changes. Here

[v8-users] Re: LNK2038: mismatch detected for '_MSC_VER': value

2016-10-06 Thread Jane Chen
Never mind. It looks like that gyp generated project files need upgrade. It links fine once upgraded. On Wednesday, October 5, 2016 at 10:25:03 PM UTC-7, Jane Chen wrote: > > Trying to embed v8 5.3-lkgr on Windows. > > v8 build was successful. While linking my applic

[v8-users] LNK2038: mismatch detected for '_MSC_VER': value

2016-10-05 Thread Jane Chen
Trying to embed v8 5.3-lkgr on Windows. v8 build was successful. While linking my application, I get: v8_base_0.lib(instruction-scheduler-x64.obj) : error LNK2038: mismatch detected for '_MSC_VER': value '1800' doesn't match value '1900' in test.o I'm building v8 and my app on the same machine

Re: [v8-users] Building v8 with gn.

2016-10-02 Thread Jane Chen
I figured out how to build with gyp now. Would still be nice to know how to link libv8_libplatform.lib and libv8_libbase.lib with the gn approach. Thanks. On Sunday, October 2, 2016 at 3:12:02 PM UTC-7, Jane Chen wrote: > > I specified "is_component_build=true" on 5.3-lkgr. I

Re: [v8-users] Building v8 with gn.

2016-10-02 Thread Jane Chen
way to generate the .lib files out of the .obj files under v8_base etc. Any suggestions? On Thursday, September 22, 2016 at 1:04:48 AM UTC-7, Jochen Eisinger wrote: > > > > On Thu, Sep 22, 2016 at 1:22 AM Jane Chen > > wrote: > >> Trying to build v8 5.3-lkgr with gn

[v8-users] Re: How to link when building my own Hello-World sample, embedding V8, with VS2015

2016-09-30 Thread Jane Chen
I also built v8 5.3-lkgr using gn, and I also needed to build v8_libbase.lib and v8_libplatform.lib for embedding purpose. The problem is I don't find samples.sln anywhere. How do I generate samples.sln? Or more directly, how am I supposed to generate the .lib files from the .obj files? On

Re: [v8-users] Any build flag to maintain regular v8 stack trace?

2016-09-28 Thread Jane Chen
It does. --gdbjit_full gives me the complete stack. Thanks again! On Wednesday, September 28, 2016 at 12:09:52 AM UTC-7, Ben Noordhuis wrote: > > On Sat, Sep 24, 2016 at 2:40 AM, Jane Chen > wrote: > > Thanks, Ben! > > > > I added that flag to my v8 init code. N

Re: [v8-users] Any build flag to maintain regular v8 stack trace?

2016-09-23 Thread Jane Chen
LazyCompile:~isPrime :1() 0x332193c6b884 I suppose that's as good as it gets, right? Any performance penalties to leave it on always? On Friday, September 23, 2016 at 11:42:08 AM UTC-7, Ben Noordhuis wrote: > > On Fri, Sep 23, 2016 at 1:10 AM, Jane Chen > wrote: > > Th

Re: [v8-users] Any build flag to maintain regular v8 stack trace?

2016-09-22 Thread Jane Chen
UTC-7, Ben Noordhuis wrote: > > On Thu, Sep 22, 2016 at 2:41 AM, Jane Chen > wrote: > > Embedding v8. Currently on 4.6.88, and in the process of upgrading to > > 5.3.lkgr. > > > > When I do a pstack of my program embedding v8, some of the v8 frames > show up

[v8-users] Any build flag to maintain regular v8 stack trace?

2016-09-21 Thread Jane Chen
Embedding v8. Currently on 4.6.88, and in the process of upgrading to 5.3.lkgr. When I do a pstack of my program embedding v8, some of the v8 frames show up as ???. I wonder whether there's a build flag I could use to enable the full stack trace of v8 frames. Please advise. Thanks. --

[v8-users] Building v8 with gn.

2016-09-21 Thread Jane Chen
Trying to build v8 5.3-lkgr with gn for embedding use. When I build with GYP, I need to set "-Dv8_use_external_startup_data=0". Is there an equivalent setting flag for gn? Also if I build with gn and I need to link with libv8_libplatform.a, libv8_libbase.a etc, is there a flag to generate thos

[v8-users] v8 libraries.

2016-09-21 Thread Jane Chen
I'm embedding v8 and trying to upgrade to v8 5.3-lkgr. After I built v8 using GYP with GYPFLAGS="-Dv8_use_external_startup_data=0 -Dcomponent=shared_library", I got the following files under out/x64.release/obj.target/src/: js2c.stamp libv8_nosnapshot.a libv8_base.a

Re: [v8-users] v8 crashes in garbage collection.

2016-09-14 Thread Jane Chen
Hi Ben, What's a good low value to set for gc_interval for debugging purpose? 1? 10? Thanks! On Friday, September 2, 2016 at 3:57:20 PM UTC-7, Ben Noordhuis wrote: > > On Fri, Sep 2, 2016 at 1:17 AM, Jane Chen > > wrote: > > Embedding v8 4.6.88. > > > >

[v8-users] v8 crashes in garbage collection.

2016-09-01 Thread Jane Chen
Embedding v8 4.6.88. Running a memory-consuming script. Sometimes I get a fatal error callback due to "process out of memory" which I now handle. Other times v8 just crashes in CollectGarbage: 2016-08-25 17:25:49.649 Critical: #5 2016-08-25 17:25:49.649 Critical: #6 0x7f71f69d67fd in voi

Re: [v8-users] PrintF calls in i::V8::FatalProcessOutOfMemory().

2016-08-24 Thread Jane Chen
I have. The PrintF calls happen before the user callback is called. With the embedded scenario, it would be desirable to have some API to suppress or redirect stdout output. On Tuesday, August 23, 2016 at 9:27:37 PM UTC-7, Ben Noordhuis wrote: > > On Wed, Aug 24, 2016 at 2:17 AM, Jan

[v8-users] PrintF calls in i::V8::FatalProcessOutOfMemory().

2016-08-23 Thread Jane Chen
Embedding v8 4.6.88. When a JavaScript program executes and runs out of memory, I get some stdout output from the subject function logging the last few GC and stack frames. Is there anyway to either suppress or redirect the output? Thanks in advance. -- -- v8-users mailing list v8-users@go

Re: [v8-users] CPU profiling hangs on Windows.

2016-08-22 Thread Jane Chen
er to reproduce. Are we supposed to always turn on profiling before compiling the script to be profiled? On Monday, August 22, 2016 at 2:29:55 PM UTC-7, Jane Chen wrote: > > Ben, > > Thanks for the tip. I'll look into that option. > > In general we are open to upgrade to a

Re: [v8-users] CPU profiling hangs on Windows.

2016-08-22 Thread Jane Chen
4 AM UTC-7, Ben Noordhuis wrote: > > On Sat, Aug 20, 2016 at 2:23 AM, Jane Chen > wrote: > > Embedding v8 4.6.88. > > > > Seeing a hang on Windows during cpu profiling. The hang happens in any > > random place calling v8, such as Isolate::New, Context::New etc.

[v8-users] CPU profiling hangs on Windows.

2016-08-19 Thread Jane Chen
Embedding v8 4.6.88. Seeing a hang on Windows during cpu profiling. The hang happens in any random place calling v8, such as Isolate::New, Context::New etc. Running optimized build, my stack doesn't show v8 frames. Not sure whether it's relevant, I captured this stack once during a hang bu

Re: [v8-users] Function line and column numbers with accessor callbacks in CpuProfileNode.

2016-06-05 Thread Jane Chen
> I suspect that profiling wasn't enabled at the time the function was > compiled. In that case, the information required for mapping code positions > back to line numbers isn't available. > > Jane Chen > schrieb am Do., 2. Juni 2016, > 20:40: > >> Testin

Re: [v8-users] Function line and column numbers with accessor callbacks in CpuProfileNode.

2016-06-03 Thread Jane Chen
to line numbers isn't available. > > Jane Chen > schrieb am Do., 2. Juni 2016, > 20:40: > >> Testing profiling against v8 4.6.88. >> >> I have functions that are exposed through accessor callbacks. In the >> CpuProfileNode, the line and column n

[v8-users] Function line and column numbers with accessor callbacks in CpuProfileNode.

2016-06-02 Thread Jane Chen
Testing profiling against v8 4.6.88. I have functions that are exposed through accessor callbacks. In the CpuProfileNode, the line and column numbers are 0 for these functions. Is that expected? Is there anything I can do to get the real line and column numbers? Is this something fixed in a

Re: [v8-users] Fatal error in , line 0 Failed to create ICU collator, are ICU data files missing?

2016-03-01 Thread Jane Chen
) > attempts to LoadLibraryA() that DLL. > > On Sat, Feb 27, 2016 at 8:30 PM Jane Chen > > wrote: > >> Embedding v8 4.6.88. >> >> On windows, I get a crash when I run the following: >> >> new Intl.Collator().compare('a','c') >>

[v8-users] Fatal error in , line 0 Failed to create ICU collator, are ICU data files missing?

2016-02-27 Thread Jane Chen
Embedding v8 4.6.88. On windows, I get a crash when I run the following: new Intl.Collator().compare('a','c') # # Fatal error in , line 0 # Failed to create ICU collator, are ICU data files missing? # In my server startup code, I have: v8::V8::InitializeICU(); I didn't specify an ICU data fil

[v8-users] When will v8::Object::Set return false?

2016-02-19 Thread Jane Chen
I'm getting warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result] obj->Set(isolate->GetCurrentContext(), ^~~~ ~ Presumably I should get the return result of Object::Set. But what shall I do if it retu

Re: [v8-users] Object.ForceSet to bypass accessors.

2016-02-01 Thread Jane Chen
> properties like you suggest can just call "set" on themselves and they'll > be transformed to data properties. > > Does that work? > Toon > > On Fri, Oct 30, 2015 at 10:36 PM Jane Chen > wrote: > >> If it was only a performance concern to always go

Re: [v8-users] How to handle out-of-memory type of errors.

2016-01-26 Thread Jane Chen
nate the thread depends on the threading > library you use. Note that you'll also have to free up all C++ memory > you've allocated, because exiting the Isolate won't invoke weak callbacks > etc.. > > On Tue, Jan 26, 2016 at 3:13 AM Jane Chen > > wrote: &g

Re: [v8-users] How to handle out-of-memory type of errors.

2016-01-25 Thread Jane Chen
s. > > On Thu, Jan 21, 2016 at 11:59 PM Jane Chen > wrote: > >> Yes, I do get fatal errors like these from v8, but my fatal error >> callback is never invoked. I register my callback after I create the >> isolate like this: >> >> isolate->

Re: [v8-users] LowMemoryNotification in for...of loop.

2016-01-23 Thread Jane Chen
Now that we are on this, can I ask more questions about GC: Is calling LowMemoryNotification() expensive? Should I only do it when I absolutely need more memory to continue, or should I do it proactively and in small batches? On Friday, January 22, 2016 at 11:41:08 PM UTC-8, Jane Chen wrote

Re: [v8-users] LowMemoryNotification in for...of loop.

2016-01-22 Thread Jane Chen
Friday, January 22, 2016 at 12:54:25 AM UTC-8, Jochen Eisinger wrote: > > would you mind filing a bug for this? Ideally, with a self-contained repro > case! > > thanks > -jochen > > On Fri, Jan 22, 2016 at 12:23 AM Jane Chen > wrote: > >> Embedding v8 4.6.88. >&

[v8-users] LowMemoryNotification in for...of loop.

2016-01-21 Thread Jane Chen
Embedding v8 4.6.88. Suppose my native function sequence() returns a JavaScript iterable wrapping a long sequence of internal objects; function gc() invokes v8::Isolate::LowMemoryNotification(). To reduce memory consumption of the iterable, gc() needs to be called periodically to release the o

Re: [v8-users] How to handle out-of-memory type of errors.

2016-01-21 Thread Jane Chen
> 11: 0x5d4554 > 12: 0x5d42e8 > 13: 0x5a98a5 > 14: 0x685bea > 15: 0x6836df > 16: 0x6a5f82 > 17: 0x59017f > 18: 0x91a56a > 19: 0x919c7d > 20: 0x5bf3e806458 > Illegal instruction (core dumped) > > > On Tue, Jan 19, 2016 at 1:05 AM Jane Chen > > wrote: >

Re: [v8-users] How to handle out-of-memory type of errors.

2016-01-18 Thread Jane Chen
ght be better than > crashing, although I'm not sure whether you won't run into other problems... > > > > On Thu, Jan 14, 2016 at 6:49 AM Jane Chen > > wrote: > >> Unfortunately, the following link is no longer valid: >> >> https://code.google.

Re: [v8-users] How to handle out-of-memory type of errors.

2016-01-13 Thread Jane Chen
"last resort gc". However using kGCCallbackFlagForced seems too eager. Any suggestions on a set of heuristics? Thanks a lot in advance. On Sunday, January 18, 2015 at 3:36:13 AM UTC-8, Jakob Kummerow wrote: > > On Sun, Jan 18, 2015 at 5:59 AM, Jane Chen > wrote: > >> J

[v8-users] List of ES6 features that are not tracked by flags.

2016-01-05 Thread Jane Chen
We embed v8 version 4.6.88. Looking at flag-definitions.h, I know some ES6 features are tracked by a flag and can be turned on/off. How do I get a list of features that are always turned on and not tracked by a flag, such as Iterator, Generator and Symbols, for example? Is there a documentati

[v8-users] Recreate solution files on Windows.

2015-12-29 Thread Jane Chen
Once the .sln and .vcxproj files are generated through python, how is one supposed to re-generate them with different gyp flags? When I run: python build/gyp_v8 -Dtarget_arch=x64 -Dv8_use_external_startup_data=0 for example, I get "updating project files...", but then only to find out nothing

[v8-users] Re: How to set _ITERATOR_DEBUG_LEVEL to 0 on Windows while building v8.

2015-12-28 Thread Jane Chen
I added it to toolchain.gypi and that seems to do it. On Monday, December 28, 2015 at 2:45:46 PM UTC-8, Jane Chen wrote: > > v8 on Windows has the default _ITERATOR_DEBUG_LEVEL value, which conflicts > with another Windows library I'm embedding. So I'd like to set the >

[v8-users] How to set _ITERATOR_DEBUG_LEVEL to 0 on Windows while building v8.

2015-12-28 Thread Jane Chen
v8 on Windows has the default _ITERATOR_DEBUG_LEVEL value, which conflicts with another Windows library I'm embedding. So I'd like to set the _ITERATOR_DEBUG_LEVEL to 0 while building v8. I haven't quite figured out how to do it either by editing v8.gyp or the generated VS solution files. If

Re: [v8-users] v8_libbase.lib(time.obj) : error LNK2001: unresolved external symbol __imp_timeGetTime

2015-12-22 Thread Jane Chen
Ben, Manually adding WinMM.lib to my project did it for me. Thanks a lot. Jane On Tuesday, December 22, 2015 at 3:09:48 AM UTC-8, Ben Noordhuis wrote: > > On Tue, Dec 22, 2015 at 6:20 AM, Jane Chen > wrote: > > I was able to build v8 4.6.88 successfully with Visual Studio 2

Re: [v8-users] Re: depot_tools fails to fetch V8 on Windows

2015-12-22 Thread Jane Chen
It's intermittent for me somehow in cygwin. Even after I set DEPOT_TOOLS_WIN_TOOLCHAIN=0. But what worked for me is to run "fetch v8" in Windows PowerShell. Still a mystery... On Tuesday, December 22, 2015 at 5:43:22 AM UTC-8, Maxime Marousez wrote: > > set DEPOT_TOOLS_WIN_TOOLCHAIN=0 before f

[v8-users] v8_libbase.lib(time.obj) : error LNK2001: unresolved external symbol __imp_timeGetTime

2015-12-21 Thread Jane Chen
I was able to build v8 4.6.88 successfully with Visual Studio 2013 with the following flags: -Dtarget_arch=x64 -Dv8_use_external_startup_data=0 I got the following libraries: $ ls -l build/Release/lib total 353468 -rwxr-xr-x 1 jchen Domain Users 3140002 Dec 21 17:20 gmock.lib -rwxr-xr-x 1 jc

Re: [v8-users] Profiler: Application crash in HandleProfilerSignal

2015-12-11 Thread Jane Chen
This seems only a problem with debug build. Optimized build works fine. On Friday, December 11, 2015 at 2:05:20 PM UTC-8, Jane Chen wrote: > > 3.24 crashes too. Same JavaScript query, but different stack: > > C stack trace === > > 1: V8_Fatal

Re: [v8-users] Profiler: Application crash in HandleProfilerSignal

2015-12-11 Thread Jane Chen
internal::FunctionCallbackArguments::Call(void (*)(v8::FunctionCallbackInfo const&)) On Friday, December 11, 2015 at 1:46:16 PM UTC-8, Jane Chen wrote: > > I am seeing a SIGILL crash too with my embedding app during profiling. > Here's the stack: > > Thread [134] (Sus

Re: [v8-users] Profiler: Application crash in HandleProfilerSignal

2015-12-11 Thread Jane Chen
I am seeing a SIGILL crash too with my embedding app during profiling. Here's the stack: Thread [134] (Suspended: Signal 'SIGILL' received. Description: Illegal instruction.) 40 v8::base::OS::Abort() /space/projects/v8-git/v8/src/base/platform/platform-posix.cc:229 0x764bcd11

Re: [v8-users] CpuProfile ->.cpuprofile.

2015-12-10 Thread Jane Chen
> On Thu, Dec 10, 2015 at 1:08 AM, Jane Chen > wrote: > > Thanks a lot! It sure helps. > > > > I found CpuProfileNode.GetNodeId(). Maybe that's the pre-computed id > which > > is the same as what you show here? > > Yes, you're right. Now t

Re: [v8-users] CpuProfile ->.cpuprofile.

2015-12-09 Thread Jane Chen
Thanks a lot! It sure helps. I found CpuProfileNode.GetNodeId(). Maybe that's the pre-computed id which is the same as what you show here? On Wednesday, December 9, 2015 at 2:09:49 PM UTC-8, Ben Noordhuis wrote: > > On Wed, Dec 9, 2015 at 8:55 PM, Jane Chen > > wrote: &g

Re: [v8-users] CpuProfile ->.cpuprofile.

2015-12-09 Thread Jane Chen
t 2:32 AM, Jane Chen > > wrote: > > I'm trying to serialize the CpuProfile object to a JSON serialization > > compatible to Chrome's .cpuprofile file. The part I'm not clear about > is > > the samples array in the .cpuprofile file: > > >

[v8-users] CpuProfile ->.cpuprofile.

2015-12-08 Thread Jane Chen
I'm trying to serialize the CpuProfile object to a JSON serialization compatible to Chrome's .cpuprofile file. The part I'm not clear about is the samples array in the .cpuprofile file: "head": {} , "startTime": 1611259.054962, "endTime": 1611262.312964, "samples": [ 2, 3, 3, 3, So it

[v8-users] v8 debug API.

2015-11-24 Thread Jane Chen
Is my understanding correct that turning on v8 debugging is global for all isolates? Is there a way to turn on v8 debug for just one isolate? What is the performance implication to turn on v8 debug? Thanks in advance. -- -- v8-users mailing list v8-users@googlegroups.com http://groups.goog

Re: [v8-users] Help about javaScript debug on v8

2015-11-12 Thread Jane Chen
Ben, In v8 4.6.88, I can no longer find src/debug-debugger.js, nor src/{liveedit,mirror}-debugger.js. Does it mean that the function-based API is also deprecated and removed? Jane On Saturday, March 14, 2015 at 3:53:55 AM UTC-7, Ben Noordhuis wrote: > > On Sat, Mar 14, 2015 at 8:30 AM, Deguo

Re: [v8-users] Is there any up-to-date documentation on how to use v8::Debug

2015-11-12 Thread Jane Chen
Hi Ben, Thanks for the info! Is the function-based debug API still supported? Is there any reference or code examples for using that? Jane On Thursday, November 12, 2015 at 4:13:31 AM UTC-8, Ben Noordhuis wrote: > > On Thu, Nov 12, 2015 at 2:22 AM, Jane Chen > wrote: > >

Re: [v8-users] Is there any up-to-date documentation on how to use v8::Debug

2015-11-11 Thread Jane Chen
gt; debugger is specific to the embedder so it is easier to do "spot > consulting'. > > What are you planning to do? > > On Monday, November 9, 2015 at 11:58:14 PM UTC+1, Jane Chen wrote: >> >> Just went to this link: >> >> https://chromium.googlesour

Re: [v8-users] Is there any up-to-date documentation on how to use v8::Debug

2015-11-09 Thread Jane Chen
Just went to this link: https://chromium.googlesource.com/v8/v8/+/master/docs/debugger_protocol.md and found that "*The message based API is no longer maintained.*" Does that mean that users (or embedders) should no longer use the message based API since it is no longer supported? On Thursday,

Re: [v8-users] How to advance an iterator.

2015-11-03 Thread Jane Chen
: > http://tc39.github.io/ecma262/#sec-getiterator > > On Tue, Nov 3, 2015 at 5:45 PM, Jane Chen > > wrote: > >> 4.6.88. Just tried it in v8 shell. myIterable[Symbol.iterator].next is >> undefined. >> >> On Tuesday, November 3, 2015 at 3:40:07 PM UTC-

Re: [v8-users] How to advance an iterator.

2015-11-03 Thread Jane Chen
4.6.88. Just tried it in v8 shell. myIterable[Symbol.iterator].next is undefined. On Tuesday, November 3, 2015 at 3:40:07 PM UTC-8, Ben Noordhuis wrote: > > On Wed, Nov 4, 2015 at 12:17 AM, Jane Chen > wrote: > > With the change of behavior in Iterator discussed here:

[v8-users] How to advance an iterator.

2015-11-03 Thread Jane Chen
With the change of behavior in Iterator discussed here: https://groups.google.com/forum/#!topic/v8-users/8LkrofVr0aA If I have an iterator (natively defined) which supports for ... of loop, what is the equivalent of calling next to advance it? I hope the following js example demonstrates what I

  1   2   3   >