Skip to content

When RUST_THREADS is bad, "fatal runtime error: runtime tls key not initialized" #8979

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

Closed
jorendorff opened this issue Sep 4, 2013 · 6 comments

Comments

@jorendorff
Copy link
Contributor

$ RUST_THREADS=x ./a.out

You've met with a terrible fate, haven't you?

fatal runtime error: runtime tls key not initialized
Abort trap: 6

The abort message is meant to be more informative...

rtabort!("`RUST_THREADS` is `%s`, should be a positive integer", nstr)

Maybe this happens to early for fmt! to be used.

@jorendorff
Copy link
Contributor Author

Program received signal SIGABRT, Aborted.
0x00007fff90707d46 in __kill ()
(gdb) bt
#0  0x00007fff90707d46 in __kill ()
#1  0x00007fff89d96df0 in abort ()
#2  0x00000001001495a6 in rt::util::abort::abort::_7c12263797ed078::_0$x2e8$x2dpre ()
#3  0x0000000100076af6 in rt::util::abort::_f2c3fded91cbadbb::_0$x2e8$x2dpre ()
#4  0x00000001000d871c in sys::begin_unwind_::_89e154cd0915671::_0$x2e8$x2dpre ()
#5  0x00000001000d8d22 in sys::__extensions__::fail_with::anon::anon::expr_fn_26302 ()
#6  0x00000001000d8558 in c_str::ToCStr::with_c_str_26291::_c6798931b183a7::_0$x2e8$x2dpre ()
#7  0x00000001000d8cd1 in sys::__extensions__::fail_with::anon::expr_fn_26300 ()
#8  0x00000001000d8558 in c_str::ToCStr::with_c_str_26291::_c6798931b183a7::_0$x2e8$x2dpre ()
#9  0x000000010005ab4c in sys::__extensions__::meth_14197::fail_with::_db4c44d01ce4116::_0$x2e8$x2dpre ()
#10 0x0000000100149541 in rt::util::default_sched_threads::_806083deb827ec::_0$x2e8$x2dpre ()
#11 0x000000010014b16f in rt::run_::_82e8c355ab8d949f::_0$x2e8$x2dpre ()
#12 0x00000001000eef7b in unstable::lang::start::_76d6c774aa357c7a::_0$x2e8$x2dpre ()
#13 0x000000010000147b in main ()

@huonw
Copy link
Member

huonw commented Sep 4, 2013

Hi, thanks for the report; however I believe I made the error message nicer in #8854; how recent is your rustc?

@huonw
Copy link
Member

huonw commented Sep 4, 2013

Or, are you saying that the runtime tls key not initialized message appears despite the code saying that it is supposed to be the nicer one?

@jorendorff
Copy link
Contributor Author

Rebuilding now, we'll see...

@jorendorff
Copy link
Contributor Author

Sorry for the delay; 6c13b0f didn't build for me, but I'll try again tomorrow. I'm going to close as I think this is fixed.

@jorendorff
Copy link
Contributor Author

Confirmed.

flip1995 pushed a commit to flip1995/rust that referenced this issue Jun 16, 2022
Correct some `#[clippy::version]`s

Some were a bit off

changelog: none
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

2 participants