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

DHAT hangs #33

Open
pacak opened this issue Feb 16, 2024 · 0 comments
Open

DHAT hangs #33

pacak opened this issue Feb 16, 2024 · 0 comments

Comments

@pacak
Copy link

pacak commented Feb 16, 2024

I noticed that the program I'm trying to monitor with dhat hangs when it is about to exit in some cases.
Program prints stuff to stderr to report progress and around the exit - this might be important.

I attached to the process with the debugger and found this in a backtrace when it was hanging.

#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x000055e311833c64 in std::sys::unix::futex::futex_wait () at library/std/src/sys/unix/futex.rs:62
#2  std::sys::unix::locks::futex_mutex::Mutex::lock_contended () at library/std/src/sys/unix/locks/futex_mutex.rs:56
#3  0x000055e31185abff in std::sys::unix::locks::futex_mutex::Mutex::lock () at library/std/src/sys/unix/locks/futex_mutex.rs:28
#4  std::sync::remutex::ReentrantMutex::lock<core::cell::RefCell<std::io::stdio::StderrRaw>> () at library/std/src/sync/remutex.rs:103
#5  std::io::stdio::Stderr::lock () at library/std/src/io/stdio.rs:888
#6  std::io::stdio::{impl#19}::write_fmt () at library/std/src/io/stdio.rs:947
#7  0x000055e31185b859 in std::io::stdio::{impl#18}::write_fmt () at library/std/src/io/stdio.rs:921
#8  std::io::stdio::print_to<std::io::stdio::Stderr> () at library/std/src/io/stdio.rs:1020
#9  std::io::stdio::_eprint () at library/std/src/io/stdio.rs:1108
#10 0x000055e31113df01 in dhat::Globals::finish (self=..., memory_output=<error reading variable: Cannot access memory at address 0x0>) at src/lib.rs:762
#11 0x000055e311094a2c in dhat::Profiler::drop_inner (memory_output=<error reading variable: Cannot access memory at address 0x0>, self=<optimized out>)

Not sure what to make of it. I'm using a local fork of dhat with eprintln! removed as a workaround - seem to work.

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

No branches or pull requests

1 participant