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

An unset KOMPUTE_ENV_DEBUG_LAYERS leads KP_LOG_DEBUG to pass envLayerNamesVal==nullptr along to fmt, which rejects that due to "string pointer is null". #245

Closed
ItsBasi opened this issue Sep 15, 2021 · 1 comment · Fixed by #246

Comments

@ItsBasi
Copy link
Contributor

ItsBasi commented Sep 15, 2021

An unset KOMPUTE_ENV_DEBUG_LAYERS leads KP_LOG_DEBUG to pass envLayerNamesVal==nullptr along to fmt, which rejects that due to "string pointer is null".

I used kompute/0.8.0 and fmt/8.0.1.
The relevant entries of the stack trace are level 19 line 182 in Manager.cpp (KP_LOG_DEBUG) and level 10 line 1926 in format.h (FMT_THROW).

1  __report_gsfailure                                                                                                            gs_report.c      220  0x7ff7e863f32d 
2  __GSHandlerCheckCommon                                                                                                        gshandler.cpp    188  0x7ff7e863df73 
3  __GSHandlerCheck_EH4                                                                                                          gshandlereh4.cpp 68   0x7ff7e863dffe 
4  _chkstk                                                                                                                       ntdll                 0x7ff849a520cf 
5  RtlRaiseException                                                                                                             ntdll                 0x7ff849a01454 
6  KiUserExceptionDispatcher                                                                                                     ntdll                 0x7ff849a50bfe 
7  RaiseException                                                                                                                KERNELBASE            0x7ff847424f99 
8  CxxThrowException                                                                                                             VCRUNTIME140D         0x7ff825d7b460 
9  fmt::v8::detail::do_throw<fmt::v8::format_error>                                                                              format.h         88   0x7ff7e85687eb 
10 fmt::v8::detail::write<char,fmt::v8::appender>                                                                                format.h         1926 0x7ff7e856d08d 
11 fmt::v8::detail::default_arg_formatter<char>::operator()<const char * __ptr64>                                                kompute_example       0x7ff7e858f64f 
12 fmt::v8::visit_format_arg<fmt::v8::detail::default_arg_formatter<char>,fmt::v8::basic_format_context<fmt::v8::appender,char>> kompute_example       0x7ff7e85a03cd 
13 `fmt::v8::detail::vformat_to<char>'::`2'::format_handler::on_replacement_field                                                kompute_example       0x7ff7e85be6b8 
14 fmt::v8::detail::parse_replacement_field<char,`fmt::v8::detail::vformat_to<char>'::`2'::format_handler & __ptr64>             kompute_example       0x7ff7e859b836 
15 fmt::v8::detail::parse_format_string<0,char,`fmt::v8::detail::vformat_to<char>'::`2'::format_handler>                         kompute_example       0x7ff7e859b31e 
16 fmt::v8::detail::vformat_to<char>                                                                                             kompute_example       0x7ff7e859f6a8 
17 fmt::v8::vformat                                                                                                              kompute_example       0x7ff7e858d6b5 
18 fmt::v8::format<const char * &>                                                                                               core.h           2886 0x7ff7e8569e0b 
19 kp::Manager::createInstance                                                                                                   Manager.cpp      182  0x7ff7e855986a 
20 kp::Manager::Manager                                                                                                          Manager.cpp      43   0x7ff7e85577fa 
21 main                                                                                                                          Main.cpp         60   0x7ff7e8509fc9 
@axsaucedo
Copy link
Member

Thank you for reporting this @ItsBasi , I was able to confirm with 7.x fmt library with KOMPUTE_OPT_ENABLE_SPDLOG=0 is set. I have now added #246 as fix.

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

Successfully merging a pull request may close this issue.

2 participants