Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wasm debug crash in lldb on MacOSX #2817

Closed
hardfist opened this issue Jul 2, 2020 · 17 comments
Closed

wasm debug crash in lldb on MacOSX #2817

hardfist opened this issue Jul 2, 2020 · 17 comments
Labels

Comments

@hardfist
Copy link

hardfist commented Jul 2, 2020

  • Version: 14.5.0
  • Platform: Darwin C02CTBPHMD6M 19.4.0 Darwin Kernel Version 19.4.0: Wed Mar 4 22:28:40 PST 2020; root:xnu-6153.101.6~15/RELEASE_X86_64 x86_64
  • Subsystem:

What steps will reproduce the bug?

you can reproduce it in https://github.com/hardfist/wasm-demo,

image

How often does it reproduce? Is there a required condition?

What is the expected behavior?

What do you see instead?

Additional information

@bnoordhuis
Copy link
Member

Your bug report is not very clear, I'm afraid. What does "debug crash" mean? I see "process exited with status -1", is that what you mean? Can you elaborate how that constitutes a crash?

@devsnek
Copy link
Member

devsnek commented Jul 2, 2020

More generally, I can't get lldb -- node to not exit -1 on macOS (10.15.5)

@hardfist
Copy link
Author

hardfist commented Jul 3, 2020

Your bug report is not very clear, I'm afraid. What does "debug crash" mean? I see "process exited with status -1", is that what you mean? Can you elaborate how that constitutes a crash?

yeah, I mean process exited with status -1 and the program not working as expected

@bnoordhuis
Copy link
Member

I can't reproduce on macos 10.14.6 with lldb 1001.0.13.3. The process exited with status -1 thing is probably something specific to macos 10.15 or the version of lldb you and @devsnek are using.

the program not working as expected

What do you mean? Is "the program" node or lldb and what specifically isn't working as expected?

@hardfist
Copy link
Author

hardfist commented Jul 3, 2020

I can't reproduce on macos 10.14.6 with lldb 1001.0.13.3. The process exited with status -1 thing is probably something specific to macos 10.15 or the version of lldb you and @devsnek are using.

the program not working as expected

What do you mean? Is "the program" node or lldb and what specifically isn't working as expected?

it should print "res: 5", but as you see in the screenshot, it just exit with exitcode -1 ,and print nothing

@devsnek
Copy link
Member

devsnek commented Jul 3, 2020

@hardfist can you try running sudo DevToolsSecurity -enable and then testing this again?

@hardfist
Copy link
Author

hardfist commented Jul 3, 2020

sudo DevToolsSecurity -enable

failed again
image

@devsnek
Copy link
Member

devsnek commented Jul 3, 2020

I can't repro anymore after enabling developer mode.

@hardfist
Copy link
Author

hardfist commented Jul 3, 2020

I can't repro anymore after enabling developer mode.

it works when using the latest node I build with source now , but the dwarf debug seems not working

image

@bnoordhuis bnoordhuis transferred this issue from nodejs/node Jul 3, 2020
@bnoordhuis
Copy link
Member

I've moved this to nodejs/help because it's likely a toolchain issue, almost certainly not an issue with node itself.

@ggreif
Copy link

ggreif commented Jul 7, 2020

did you

(lldb) settings set plugin.jit-loader.gdb.enable on

?

@hardfist
Copy link
Author

hardfist commented Jul 8, 2020

did you

(lldb) settings set plugin.jit-loader.gdb.enable on

?

yes, I set it on .lldbinit

@ggreif
Copy link

ggreif commented Jul 8, 2020

I am asking because that made breakpoints of lldb-10 work for me, under wasmtime-0.17.

@hardfist
Copy link
Author

hardfist commented Jul 8, 2020

I am asking because that made breakpoints of lldb-10 work for me, under wasmtime-0.17.

yes , it works well for wasmtime but not nodejs

@hardfist
Copy link
Author

@bnoordhuis I can debug node using lldb my built node(nodejs/node#34340) , but it seems that
node still doesn't not support wasm debug
image

@github-actions
Copy link

There has been no activity on this issue for 3 years and it may no longer be relevant. It will be closed 1 month after the last non-automated comment.

@github-actions github-actions bot added the stale label Jul 31, 2023
@github-actions
Copy link

There has been no activity on this issue and it is being closed. If you feel closing this issue is not the right thing to do, please leave a comment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants