Closed
Description
Looks like in Node.js v8.3.0 (with v8 6.0) thin strings are enabled by default, since they are not recognized by llnode, when inspecting those strings the output is broken. e.g. when viewing the backtrace of test/inspect-scenario.js
, script names that are thin strings will be displayed as "no script" (since llnode cannot do String::ToString()
on them) and frames with functions containing thin string arguments would be empty:
* thread #1: tid = 0x5bac78, 0x0000000100bc8412 node`v8::base::OS::Abort() at platform-posix.cc:261, queue = 'com.apple.main-thread', stop reason = EXC_BAD_INSTRUCTION (code=EXC_I386_INVOP, subcode=0x0)
* frame #0: 0x0000000100bc8412 node`v8::base::OS::Abort() at platform-posix.cc:261 [opt]
frame #1: 0x00000001008a777b node`v8::internal::Runtime_Throw(int, v8::internal::Object**, v8::internal::Isolate*) [inlined] v8::internal::__RT_impl_Runtime_Throw(v8::internal::Arguments, v8::internal::Isolate*) at runtime-internal.cc:74 [opt]
frame #2: 0x00000001008a775a node`v8::internal::Runtime_Throw(args_length=<unavailable>, args_object=<unavailable>, isolate=0x00000001030492e0) at runtime-internal.cc:71 [opt]
frame #3: 0x000038d5094040dd <exit>
frame #4: 0x000038d50950523a
frame #5: 0x000038d509412f12 method(this=0x000012a70245bda1:<Object: Class>) at (no script):20:43 fn=0x00001a7c7fb0dbe1
frame #6: 0x000038d5094f35e9
frame #7: 0x000038d509412f12 closure(this=0x00001fb4b3602241:<undefined>) at (no script):11:17 fn=0x000012a702405879
frame #8: 0x000038d5094f3fa1
frame #9: 0x000038d509412f12
frame #10: 0x000038d5094f2cc8
frame #11: 0x000038d509412f12
frame #12: 0x000038d5094f38aa
frame #13: 0x000038d509412f12
frame #14: 0x000038d5094f38aa
frame #15: 0x000038d509412f12
frame #16: 0x000038d5094f373c
frame #17: 0x000038d509412f12
frame #18: 0x000038d5094f4242
frame #19: 0x000038d509412f12 Module._load(this=0x00003d76f5bbb379:<function: Module at module.js:55:16>, 0x00003d76f5bc7039:<String: "/Users/joyee/pro...">, 0x00001fb4b3602211:<null>, 0x00001fb4b36022c1:<true>) at module.js:434:24 fn=0x000011003aec1319
frame #20: 0x000038d5094f2cc8
frame #21: 0x000038d509412f12 Module.runMain(this=0x00003d76f5bbb379:<function: Module at module.js:55:16>) at module.js:607:26 fn=0x000011003aec1589
frame #22: 0x000038d509513c29
frame #23: 0x000038d509412f12 startup(this=0x00001fb4b3602241:<undefined>) at bootstrap_node.js:1:10 fn=0x0000278695a7df51
frame #24: 0x000038d5094f3fa1
frame #25: 0x000038d509412f12 (anonymous)(this=0x00001fb4b3602211:<null>, 0x0000278695a7dfd1:<Object: process>) at bootstrap_node.js:1:10 fn=0x0000278695a7e021
frame #26: 0x000038d509410650 <internal>
frame #27: 0x000038d5094e4ead <entry>
frame #28: 0x00000001005dbe21 node`v8::internal::(anonymous namespace)::Invoke(isolate=0x0000000000000049, is_construct=<unavailable>, target=<unavailable>, receiver=<unavailable>, argc=1, args=<unavailable>, new_target=<unavailable>, message_handling=<unavailable>) at execution.cc:145 [opt]
frame #29: 0x00000001005dbb09 node`v8::internal::Execution::Call(v8::internal::Isolate*, v8::internal::Handle<v8::internal::Object>, v8::internal::Handle<v8::internal::Object>, int, v8::internal::Handle<v8::internal::Object>*) [inlined] v8::internal::(anonymous namespace)::CallInternal(message_handling=kReport) at execution.cc:181 [opt]
frame #30: 0x00000001005dba80 node`v8::internal::Execution::Call(isolate=0x0000000103000c00, callable=Handle<v8::internal::Object> @ r12, receiver=<unavailable>, argc=1, argv=<unavailable>) at execution.cc:191 [opt]
frame #31: 0x0000000100205158 node`v8::Function::Call(this=0x0000000103049238, context=<unavailable>, recv=<unavailable>, argc=1, argv=0x00007fff5fbfe190) at api.cc:5287 [opt]
frame #32: 0x0000000100a523e3 node`node::LoadEnvironment(env=0x00007fff5fbfe240) at node.cc:3628 [opt]
frame #33: 0x0000000100a59231 node`node::Start(isolate=0x0000000103000c00, isolate_data=<unavailable>, argc=2, argv=<unavailable>, exec_argc=1, exec_argv=0x0000000102703c80) at node.cc:4553 [opt]
frame #34: 0x0000000100a53d6e node`node::Start(event_loop=0x0000000101763818, argc=2, argv=0x00000001027043b0, exec_argc=<unavailable>, exec_argv=<unavailable>) at node.cc:4639 [opt]
frame #35: 0x0000000100a539fb node`node::Start(argc=<unavailable>, argv=0x00000001027043b0) at node.cc:4701 [opt]
frame #36: 0x0000000100001534 node`start + 52
Before (output in v8.2.1)
* thread #1: tid = 0x5b416b, 0x0000000100bf7e32 node`v8::base::OS::Abort() + 18, queue = 'com.apple.main-thread', stop reason = EXC_BAD_INSTRUCTION (code=EXC_I386_INVOP, subcode=0x0)
* frame #0: 0x0000000100bf7e32 node`v8::base::OS::Abort() + 18
frame #1: 0x000000010068579a node`v8::internal::Isolate::Throw(v8::internal::Object*, v8::internal::MessageLocation*) + 842
frame #2: 0x000000010083a50b node`v8::internal::Runtime_Throw(int, v8::internal::Object**, v8::internal::Isolate*) + 59
frame #3: 0x000026abe7b040bd <exit>
frame #4: 0x000026abe7c874b4 method(this=0x000002fc27a4f989:<Object: Class>) at /Users/joyee/projects/llnode/test/fixtures/inspect-scenario.js:20:43 fn=0x0000368fab67ed41
frame #5: 0x000026abe7c7c9ef closure(this=0x00003b8295902241:<undefined>) at /Users/joyee/projects/llnode/test/fixtures/inspect-scenario.js:11:17 fn=0x0000019a5b7f5589
frame #6: 0x000026abe7c6a585 (anonymous)(this=0x0000019a5b7f3419:<Object: Object>, 0x0000019a5b7f3419:<Object: Object>, 0x0000019a5b7f5141:<function: require at internal/module.js:8:19>, 0x0000019a5b7f3359:<Object: Module>, 0x0000019a5b7f2769:<String: "/Users/joyee/pro...">, 0x0000019a5b7f50d9:<String: "/Users/joyee/pro...">) at /Users/joyee/projects/llnode/test/fixtures/inspect-scenario.js:1:10 fn=0x0000019a5b7f5091
frame #7: 0x000026abe7c69b90 Module._compile(this=0x0000019a5b7f3359:<Object: Module>, 0x0000019a5b7f4279:<String: "'use strict';
c...">, 0x0000019a5b7f2769:<String: "/Users/joyee/pro...">) at module.js:526:37 fn=0x0000368fab636f19
frame #8: 0x000026abe7c639a3 Module._extensions..js(this=0x0000019a5b7ef779:<Object: Object>, 0x0000019a5b7f3359:<Object: Module>, 0x0000019a5b7f2769:<String: "/Users/joyee/pro...">) at module.js:578:37 fn=0x0000368fab636f61
frame #9: 0x000026abe7c6242a Module.load(this=0x0000019a5b7f3359:<Object: Module>, 0x0000019a5b7f2769:<String: "/Users/joyee/pro...">) at module.js:494:33 fn=0x0000368fab636e89
frame #10: 0x000026abe7be014b
frame #11: 0x000026abe7b12759 tryModuleLoad(this=0x00003b8295902241:<undefined>, 0x0000019a5b7f3359:<Object: Module>, 0x0000019a5b7f2769:<String: "/Users/joyee/pro...">) at module.js:463:23 fn=0x0000019a5b7be7b1
frame #12: 0x000026abe7c5b7f6 Module._load(this=0x0000019a5b7be601:<function: Module at module.js:50:16>, 0x0000019a5b7c9e89:<String: "/Users/joyee/pro...">, 0x00003b8295902211:<null>, 0x00003b82959022c1:<true>) at module.js:432:24 fn=0x0000368fab636dc9
frame #13: 0x000026abe7c5b27e Module.runMain(this=0x0000019a5b7be601:<function: Module at module.js:50:16>) at module.js:603:26 fn=0x0000368fab637039
frame #14: 0x000026abe7c303b8 startup(this=0x00003b8295902241:<undefined>) at bootstrap_node.js:1:10 fn=0x00002b4165c07b31
frame #15: 0x000026abe7c2e5cb (anonymous)(this=0x00003b8295902211:<null>, 0x00002b4165c07859:<Object: process>) at bootstrap_node.js:1:10 fn=0x00002b4165c07be9
frame #16: 0x000026abe7b10290 <internal>
frame #17: 0x000026abe7bd646d <entry>
frame #18: 0x0000000100559626 node`v8::internal::(anonymous namespace)::Invoke(v8::internal::Isolate*, bool, v8::internal::Handle<v8::internal::Object>, v8::internal::Handle<v8::internal::Object>, int, v8::internal::Handle<v8::internal::Object>*, v8::internal::Handle<v8::internal::Object>, v8::internal::Execution::MessageHandling) + 742
frame #19: 0x0000000100559283 node`v8::internal::Execution::Call(v8::internal::Isolate*, v8::internal::Handle<v8::internal::Object>, v8::internal::Handle<v8::internal::Object>, int, v8::internal::Handle<v8::internal::Object>*) + 179
frame #20: 0x00000001001619ef node`v8::Function::Call(v8::Local<v8::Context>, v8::Local<v8::Value>, int, v8::Local<v8::Value>*) + 559
frame #21: 0x0000000100a7d703 node`node::LoadEnvironment(node::Environment*) + 591
frame #22: 0x0000000100a846e6 node`node::Start(v8::Isolate*, node::IsolateData*, int, char const* const*, int, char const* const*) + 426
frame #23: 0x0000000100a7f7c1 node`node::Start(uv_loop_s*, int, char const* const*, int, char const* const*) + 462
frame #24: 0x0000000100a7edb5 node`node::Start(int, char**) + 331
frame #25: 0x0000000100000e34 node`start + 52
Metadata
Assignees
Labels
No labels