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

Format on save with clang-format takes too long #6809

Closed
xolom opened this issue Jan 19, 2021 · 65 comments
Closed

Format on save with clang-format takes too long #6809

xolom opened this issue Jan 19, 2021 · 65 comments
Labels
bug Feature: Code Formatting fixed Check the Milestone for the release in which the fix is or will be available. performance
Milestone

Comments

@xolom
Copy link

xolom commented Jan 19, 2021

Describe the bug

  • OS and Version: MacOS 11.1 (ubuntu docker)
  • VS Code Version: 1.52.1
  • C/C++ Extension Version: 1.1.3
  • Other extensions you installed (and if the issue persists after disabling them):
eamodio.gitlens
ms-azuretools.vscode-docker
ms-vscode.cpptools
gitlab.gitlab-workflow
renesackers.angelscript
ms-python.python
ms-python.vscode-pylance

Sometimes format on save with clang-format takes really long. I need to cancel the task to save the file. What is the cause for that, how can i debug that further? I see this popup for like forever
Screenshot 2021-01-19 at 10 09 26

@sean-mcmanus
Copy link
Collaborator

When this occurs can you check which process is using CPU? If it's cpptools, then the formatting might be blocked on another operation (or possibly processing the formatting result), in which case, if you set C_Cpp.loggingLevel to "Debug" and check the formatting-related logging that can help determine where it's getting stuck (or attaching a debugger and getting a call stack: https://github.com/microsoft/vscode-cpptools/wiki/Attaching-debugger-to-cpptools-or-cpptools%E2%80%90srv). If it's clang-format, then it would be a clang-format bug.

@sean-mcmanus sean-mcmanus self-assigned this Jan 20, 2021
@sean-mcmanus sean-mcmanus added bug Feature: Code Formatting more info needed The issue report is not actionable in its current state performance labels Jan 20, 2021
@xolom
Copy link
Author

xolom commented Jan 22, 2021

Unfortunately i can't attach to the cpptool process. Running on mac and lldb gives me following error:

❯ sudo lldb -p 72381
(lldb) process attach --pid 72381
error: attach failed: attach failed (Not allowed to attach to process.  Look in the console messages (Console.app), near the debugserver entries when the attached failed.  The subsystem that denied the attach permission will likely have logged an informative message about why it was denied.)

Everything i can say right now is that the extension stucks completely somehow. The log output doesn't print anything anymore and this little message where it says Updating IntelliSense... won't go away.
image

@Colengms
Copy link
Collaborator

Hi @xolom . When this happens, can you check whether or not clang-format is still executing (based on the Activity Monitor) ? Also, I noticed that you repro'ed this with 1.1.3. Could you try upgrading to 1.2.0-insiders2 ? We recently upgraded the bundled version of clang-format to 11.x.

@xolom
Copy link
Author

xolom commented Jan 25, 2021

Hi @xolom . When this happens, can you check whether or not clang-format is still executing (based on the Activity Monitor) ? Also, I noticed that you repro'ed this with 1.1.3. Could you try upgrading to 1.2.0-insiders2 ? We recently upgraded the bundled version of clang-format to 11.x.

Hi.

I was already @ 1.2.0-insiders2, when i made the post above. I just checked if clang-format is executed at all and it seems like it's not.

❯ ps -ax | grep clang-format
 4470 ttys000    0:00.00 grep --color clang-format

On the other hand there are many running cpptools processes:

❯ ps -ax | grep cpptools
 3876 ??         0:16.33 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 98674 {D1ADD6A9-6917-484C-A2A3-5934EFE2C1FC}
 4068 ??         0:17.72 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 98674 {BA1E20A6-7AFC-46D2-9B4A-31A4ADDF0A3B}
34106 ??         2:34.51 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools
35050 ??         3:53.48 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 34106 {05C81682-4426-4663-B3BC-487DAB1E8DAA}
35548 ??         0:36.44 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 34106 {CDF5E910-5117-447D-BFBA-C46FD774F803}
42871 ??         3:49.08 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools
43088 ??         3:44.94 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 42871 {F2181B3C-89A9-4BD9-B26F-C12143A0106A}
43093 ??         1:04.20 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 42871 {5C1E7AF8-B2C8-4629-9EE8-B682226105BD}
52121 ??         3:01.85 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools
52445 ??         3:43.38 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 52121 {B2D7787E-7396-4262-82DA-DED399FFA01C}
53415 ??         1:13.78 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 52121 {5C360CEC-FDD1-487C-ACD0-4737A150942A}
53742 ??         1:30.25 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 52121 {95655A9A-1F92-43E6-872D-95AFF42165DA}
53855 ??         1:30.17 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 52121 {39D44902-D12E-4A89-823C-DFC0A9606B20}
55101 ??         0:27.71 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools
55469 ??         1:09.67 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 55101 {C98B2C4E-7F4A-4AC3-88BC-B6C269C2BD1D}
72381 ??         4:24.26 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools
73757 ??         1:11.39 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 72381 {36271D50-EB4D-4BB7-B538-96BF1D1038ED}
74113 ??         0:08.92 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 72381 {5222506C-49DF-4FCF-B008-34A5F4A91528}
74555 ??         0:30.64 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 72381 {E327868E-68F6-4B29-A64F-6E4448A0EC63}
74829 ??         0:15.68 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 72381 {4B625ED8-0758-43DF-BF86-1BDEF98A4000}
75083 ??         0:16.99 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools-srv 72381 {BB461531-82A6-499D-807C-3F327FD0F7BC}
98674 ??        10:30.70 /Users/.../.vscode/extensions/ms-vscode.cpptools-1.2.0-insiders2/bin/cpptools

@xolom
Copy link
Author

xolom commented Jan 25, 2021

What i also noticed is following message in the log:
Shutting down IntelliSense server: /some/path/foo.cpp. Memory usage is 4386 MB and has exceeded the 4096 MB limit.

Today i mostly worked mostly only in one .cpp file. The IntelliSense parsing flame icon came up like every few seconds and my MacBook also needs to "breathe". I don't know, but it feels like the parsing is overwhelmed in some way and I'm pretty sure that this blocks the execution of clang-format.

I already tried to speedup the parsing as much as possible by only include the necessary folders, setting limitSymbolsToIncludedHeaders to true and exclude system includes (we're cross compiling for a microcontroller).
Unfortunately the debug log doesn't help me in this case.

@Colengms
Copy link
Collaborator

Hi @xolom . Is the code involved rather complex? With debug logging enabled with "C_Cpp.loggingLevel": "Debug", an Update IntelliSense time (sec): x.xx message should occasionally be output to the C/C++ output channel when working with the file, as IntelliSense passes complete. The duration may vary a bit. Does it roughly match the delay in your scenario?

I suspect the cause of the issue is an operation prior to formatting that is trying to synchronize with the results of an IntelliSense pass. We have a known issue in which certain combinations of operations might result in a delay for this reason. We have some ongoing work that should lead to addressing the issue.

Can you identify the combination of operations prior to formatting that lead to the delay? It's likely due to making an edit, hovering, then closing the file before the hover operation is complete). Depending on your specific repro, there may be something we can do to address it sooner.

@xolom
Copy link
Author

xolom commented Jan 26, 2021

Hi @Colengms.
To the code complexity: There is one part that is generated and has 480,496 loc across 28 files and the actual code has 52,881 loc across 449 files. The path to the generated code is set without ** in c_cpp_properties.json, because we're using precompiled headers and we need to have them available globally. Means that we always parse all generated files.

From what I have seen in the log these are the values coming up over the day:
Update IntelliSense time (sec): 0.282
Update IntelliSense time (sec): 0.271
Update IntelliSense time (sec): 0.281
Update IntelliSense time (sec): 0.285
Update IntelliSense time (sec): 0.277
Update IntelliSense time (sec): 0.283
Update IntelliSense time (sec): 0.289
Update IntelliSense time (sec): 6.022
Update IntelliSense time (sec): 0.274
Update IntelliSense time (sec): 0.274
Update IntelliSense time (sec): 0.27
Update IntelliSense time (sec): 0.278
Update IntelliSense time (sec): 0.273
Update IntelliSense time (sec): 0.477
Update IntelliSense time (sec): 0.279
Update IntelliSense time (sec): 0.276
Update IntelliSense time (sec): 2.276
Update IntelliSense time (sec): 3.605
Update IntelliSense time (sec): 3.238
Update IntelliSense time (sec): 33.036
Update IntelliSense time (sec): 0.273
Update IntelliSense time (sec): 0.284
Update IntelliSense time (sec): 0.269
Update IntelliSense time (sec): 0.56
Update IntelliSense time (sec): 0.274
Update IntelliSense time (sec): 0.285
Update IntelliSense time (sec): 0.275
Update IntelliSense time (sec): 11.737
Update IntelliSense time (sec): 7.917
Update IntelliSense time (sec): 0.274
Update IntelliSense time (sec): 0.276
Update IntelliSense time (sec): 0.545
Update IntelliSense time (sec): 0.561
Update IntelliSense time (sec): 0.351
Update IntelliSense time (sec): 0.287
Update IntelliSense time (sec): 0.573
Update IntelliSense time (sec): 0.273
Update IntelliSense time (sec): 0.279
Update IntelliSense time (sec): 0.331
Update IntelliSense time (sec): 0.322
Update IntelliSense time (sec): 0.522
Update IntelliSense time (sec): 3.61
Update IntelliSense time (sec): 17.964
Update IntelliSense time (sec): 0.457
Update IntelliSense time (sec): 2.27
Update IntelliSense time (sec): 0.33
Update IntelliSense time (sec): 0.271
Update IntelliSense time (sec): 0.279
Update IntelliSense time (sec): 0.274
Update IntelliSense time (sec): 0.28
Update IntelliSense time (sec): 0.275
Update IntelliSense time (sec): 0.28
Update IntelliSense time (sec): 0.276
Update IntelliSense time (sec): 0.275
Update IntelliSense time (sec): 0.276
Update IntelliSense time (sec): 0.563
Update IntelliSense time (sec): 0.271
Update IntelliSense time (sec): 3.981
Update IntelliSense time (sec): 1.02
Update IntelliSense time (sec): 2.2
Update IntelliSense time (sec): 6.913
Update IntelliSense time (sec): 0.27
Update IntelliSense time (sec): 0.271
Update IntelliSense time (sec): 0.539
Update IntelliSense time (sec): 0.275
Update IntelliSense time (sec): 0.27
Update IntelliSense time (sec): 0.394
Update IntelliSense time (sec): 0.278
Update IntelliSense time (sec): 0.818
Update IntelliSense time (sec): 1.276
Update IntelliSense time (sec): 0.271
Update IntelliSense time (sec): 0.681
Update IntelliSense time (sec): 20.329
Update IntelliSense time (sec): 0.537
Update IntelliSense time (sec): 0.275
Update IntelliSense time (sec): 0.272
Update IntelliSense time (sec): 12.57
Update IntelliSense time (sec): 0.275
Update IntelliSense time (sec): 0.548
Update IntelliSense time (sec): 0.837
Update IntelliSense time (sec): 0.272
Update IntelliSense time (sec): 2.708
Update IntelliSense time (sec): 8.534
Update IntelliSense time (sec): 0.28
Update IntelliSense time (sec): 0.54
Update IntelliSense time (sec): 0.279
Update IntelliSense time (sec): 0.278
Update IntelliSense time (sec): 0.419
Update IntelliSense time (sec): 0.302

I'll try to find out, if there is any specific action happening before i save the file and clang-format (or cpptools) gets stuck

@xolom
Copy link
Author

xolom commented Feb 2, 2021

I'm pretty sure that cpptools or cpptools-srv (don't really know which does what) gets stuck. That's why i had so many processes running like shown in #6809 (comment)
I always need to kill the processes and restart vscode. After that everything starts to work again.

Unfortunately i can't attach lldb on my MacOS machine to give you the call stack (see: #6809 (comment))

@Dakror
Copy link

Dakror commented Feb 2, 2021

I'm experiencing the same issue on Windows and the issue disappears when downgrading the plugin to i think 0.29, but then again much of the functionality gets lost too.

@xolom
Copy link
Author

xolom commented Feb 2, 2021

Hi @Dakror

Are you able to attach a debugger to cpptools when this happens and check the call-stack (see: this link) ?

@Dakror
Copy link

Dakror commented Feb 2, 2021

I'll try once I'm able to reproduce the issue again. I've kept the format on save feature disabled for a few days due to this bug and now after re-enabling it im having trouble recreating it.

@Dakror
Copy link

Dakror commented Feb 2, 2021

Call Stack for the main thread of cpptools.
The issue is i can't actually start attaching from the same VSCode instance, so i had to open up a second workspace to attach.

ntdll.dll!_NtReadFile@36�() (Unknown Source:0)
KernelBase.dll!_ReadFile@20�() (Unknown Source:0)
kernel32.dll!_ReadFileImplementation@20�() (Unknown Source:0)
cpptools.exe!__read_nolock�() (Unknown Source:0)
cpptools.exe!__read�() (Unknown Source:0)
cpptools.exe!common_refill_and_read_nolock() (Unknown Source:0)
cpptools.exe!__fgetc_nolock�() (Unknown Source:0)
cpptools.exe!_fgetc�() (Unknown Source:0)
cpptools.exe!std::_Fgetc(char &,struct _iobuf *) (Unknown Source:0)
cpptools.exe!std::basic_filebuf<char,struct std::char_traits >::uflow(void) (Unknown Source:0)
cpptools.exe!std::basic_filebuf<char,struct std::char_traits >::underflow(void) (Unknown Source:0)
cpptools.exe!___crtInitializeSRWLock�() (Unknown Source:0)

@Dakror
Copy link

Dakror commented Feb 2, 2021

the cpptools-srv are all here:

ntdll.dll!_NtWaitForSingleObject@12�() (Unknown Source:0)
KernelBase.dll!_WaitForSingleObjectEx@12�() (Unknown Source:0)
KernelBase.dll!_WaitForSingleObject@8�() (Unknown Source:0)
KernelBase.dll!_GetOverlappedResult@16�() (Unknown Source:0)
cpptools-srv.exe!read_pipe_sync(void *,unsigned long,void *) (Unknown Source:0)
cpptools-srv.exe!comm_pipe_win32::read(class std::basic_string<char,struct std::char_traits,class std::allocator > &) (Unknown Source:0)
cpptools-srv.exe!comm_server::wait_for_requests(void) (Unknown Source:0)
cpptools-srv.exe!_main�() (Unknown Source:0)
cpptools-srv.exe!__scrt_common_main_seh() (Unknown Source:0)
kernel32.dll!@BaseThreadInitThunk@12�() (Unknown Source:0)
ntdll.dll!___RtlUserThreadStart@8�() (Unknown Source:0)
ntdll.dll!__RtlUserThreadStart@8�() (Unknown Source:0)

@bobbrow
Copy link
Member

bobbrow commented Feb 2, 2021

@Dakror can you share the stacks from all threads?

@Dakror
Copy link

Dakror commented Feb 2, 2021

@Dakror can you share the stacks from all threads?

From what i could see, all other threads appeared as worker threads all waiting on some lock.

@bobbrow
Copy link
Member

bobbrow commented Feb 2, 2021

I would expect there to be one thread waiting for clang-format. It would be in the cpptools process, not cpptools-srv.

@Dakror
Copy link

Dakror commented Feb 2, 2021

one thread looks like this:

ntdll.dll!_NtWaitForSingleObject@12�() (Unknown Source:0)
KernelBase.dll!_WaitForSingleObjectEx@12�() (Unknown Source:0)
KernelBase.dll!_WaitForSingleObject@8�() (Unknown Source:0)
KernelBase.dll!_GetOverlappedResult@16�() (Unknown Source:0)
cpptools.exe!read_pipe_sync(void *,unsigned long,void *) (Unknown Source:0)
cpptools.exe!comm_pipe_win32::read(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > &) (Unknown Source:0)
cpptools.exe!comm_server::wait_for_requests(void) (Unknown Source:0)
cpptools.exe!std::thread::_Invoke<class std::tuple<class <lambda_b50f426d9147729548ce44430f01adab> >,0>(void *) (Unknown Source:0)
cpptools.exe!thread_start<unsigned int (__stdcall*)(void *),1>() (Unknown Source:0)
kernel32.dll!@BaseThreadInitThunk@12�() (Unknown Source:0)
ntdll.dll!___RtlUserThreadStart@8�() (Unknown Source:0)
ntdll.dll!__RtlUserThreadStart@8�() (Unknown Source:0)

another one like this:

cpptools.exe!std::_Cmp_chrange<char const *,char const *,struct std::_Cmp_cs<class std::regex_traits<char> > >(char const *,char const *,char const *,char const *,struct std::_Cmp_cs<class std::regex_traits<char> >) (Unknown Source:0)
cpptools.exe!std::_Compare<char const *,char const *,class std::regex_traits<char> >(char const *,char const *,char const *,char const *,class std::regex_traits<char> const &,enum std::regex_constants::syntax_option_type) (Unknown Source:0)
cpptools.exe!std::_Matcher<char const *,char,class std::regex_traits<char>,char const *>::_Skip(char const *,char const *,class std::_Node_base *) (Unknown Source:0)
cpptools.exe!std::_Matcher<char const *,char,class std::regex_traits<char>,char const *>::_Skip(char const *,char const *,class std::_Node_base *) (Unknown Source:0)
cpptools.exe!std::_Matcher<char const *,char,class std::regex_traits<char>,char const *>::_Skip(char const *,char const *,class std::_Node_base *) (Unknown Source:0)
cpptools.exe!std::_Regex_search2<char const *,class std::allocator<class std::sub_match<char const *> >,char,class std::regex_traits<char>,char const *>(char const *,char const *,class std::match_results<char const *,class std::allocator<class std::sub_match<char const *> > > *,class std::basic_regex<char,class std::regex_traits<char> > const &,enum std::regex_constants::match_flag_type,char const *) (Unknown Source:0)
cpptools.exe!std::regex_iterator<char const *,char,class std::regex_traits<char> >::operator++(void) (Unknown Source:0)
cpptools.exe!msvc::split_string<char,class std::back_insert_iterator<class std::vector<struct msvc::sized_string<char>,class std::allocator<struct msvc::sized_string<char> > > > >(char const *,char const *,class std::basic_regex<char,class std::regex_traits<char> > const &,class std::back_insert_iterator<class std::vector<struct msvc::sized_string<char>,class std::allocator<struct msvc::sized_string<char> > > >,bool) (Unknown Source:0)
cpptools.exe!msvc::split_string<char,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > >(class std::basic_string_view<char,struct std::char_traits<char> >,class std::basic_regex<char,class std::regex_traits<char> > const &,class std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > &,bool) (Unknown Source:0)
cpptools.exe!msvc::split_string<char,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > >(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::basic_regex<char,class std::regex_traits<char> > const &,class std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > &,bool) (Unknown Source:0)
cpptools.exe!parse_defines(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > &) (Unknown Source:0)
cpptools.exe!gcc_info::get_system_defaults(struct gcc_info::compiler_defaults const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,bool,struct compilation_args &) (Unknown Source:0)
cpptools.exe!gcc_info::gcc_info(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class vscode::ext::optional<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,bool,class vscode::ext::optional<enum IntelliSenseMode> const &) (Unknown Source:0)
cpptools.exe!std::_Construct_in_place<class gcc_info,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class vscode::ext::optional<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,bool &,class vscode::ext::optional<enum IntelliSenseMode> const &>(class gcc_info &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::basic_string<char,struct std::char_traits<char>,class std::al (Unknown Source:0)
cpptools.exe!std::_Ref_count_obj2<class gcc_info>::_Ref_count_obj2<class gcc_info><class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class vscode::ext::optional<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,bool &,class vscode::ext::optional<enum IntelliSenseMode> const &>(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::basic_string<char,struct std::char_traits<char>, (Unknown Source:0)
cpptools.exe!std::make_shared<class gcc_info,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class vscode::ext::optional<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,bool &,class vscode::ext::optional<enum IntelliSenseMode> const &>(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,c (Unknown Source:0)
cpptools.exe!compiler_info::find_or_create(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class vscode::ext::optional<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,bool,class vscode::ext::optional<enum IntelliSenseMode> const &,bool &) (Unknown Source:0)
cpptools.exe!compiler_info::get(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class vscode::ext::optional<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > const &,bool,class vscode::ext::optional<class std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class vscode::ext::optional<enum IntelliSenseMode> const &,bool,class vscode::ext::optional<class std (Unknown Source:0)
cpptools.exe!cpp_properties::add_custom_config(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,struct vscode::SourceFileConfiguration const &) (Unknown Source:0)
cpptools.exe!vscode::message_handler::cpptools_didChangeCustomConfigurations(struct vscode::CustomConfigurationParams) (Unknown Source:0)
cpptools.exe!vscode::message_handler::dispatch(class vscode::vscode_client_message &&,struct vscode::vscode_server_message &,struct vscode::message_handler::msg_proc_thread_token) (Unknown Source:0)
cpptools.exe!vscode::message_handler::handle_message(class vscode::vscode_client_message &&,struct vscode::message_handler::msg_proc_thread_token) (Unknown Source:0)
cpptools.exe!<lambda>(void)() (Unknown Source:0)
cpptools.exe!std::thread::_Invoke<class std::tuple<class <lambda_d26d5df9c9b9a9741891376c056f615c> >,0>(void *) (Unknown Source:0)
cpptools.exe!thread_start<unsigned int (__stdcall*)(void *),1>() (Unknown Source:0)
kernel32.dll!@BaseThreadInitThunk@12�() (Unknown Source:0)
ntdll.dll!___RtlUserThreadStart@8�() (Unknown Source:0)
ntdll.dll!__RtlUserThreadStart@8�() (Unknown Source:0)

the others are all the same with:

ntdll.dll!_NtWaitForKeyedEvent@16�() (Unknown Source:0)
ntdll.dll!_RtlSleepConditionVariableSRW@16�() (Unknown Source:0)
kernel32.dll!_SleepConditionVariableSRW@16�() (Unknown Source:0)
cpptools.exe!___crtSleepConditionVariableSRW�() (Unknown Source:0)
cpptools.exe!Concurrency::details::stl_condition_variable_win7::wait_for(class Concurrency::details::stl_critical_section_interface *,unsigned int) (Unknown Source:0)
cpptools.exe!do_wait() (Unknown Source:0)
cpptools.exe!std::condition_variable::wait_until(class std::unique_lock<class std::mutex> &,struct xtime const *) (Unknown Source:0)
cpptools.exe!std::condition_variable::_Wait_until1<struct std::chrono::steady_clock,class std::chrono::duration<__int64,struct std::ratio<1,1000000000> >,class <lambda_5b3201cb33e96a73edaa7af5dadd49bd> >(class std::unique_lock<class std::mutex> &,class std::chrono::time_point<struct std::chrono::steady_clock,class std::chrono::duration<__int64,struct std::ratio<1,1000000000> > > const &,class <lambda_5b3201cb33e96a73edaa7af5dadd49bd> &) (Unknown Source:0)
cpptools.exe!std::condition_variable::wait_for<__int64,struct std::ratio<1,1000>,class <lambda_5b3201cb33e96a73edaa7af5dadd49bd> >(class std::unique_lock<class std::mutex> &,class std::chrono::duration<__int64,struct std::ratio<1,1000> > const &,class <lambda_5b3201cb33e96a73edaa7af5dadd49bd>) (Unknown Source:0)
cpptools.exe!msvc::bitset_event_t::wait_for_any_set<__int64,struct std::ratio<1,1000> >(class std::chrono::duration<__int64,struct std::ratio<1,1000> > const &,unsigned int) (Unknown Source:0)
cpptools.exe!<lambda>(void)() (Unknown Source:0)
cpptools.exe!std::thread::_Invoke<class std::tuple<class <lambda_6f614bd7e9c91969769d2d5046dccb28> >,0>(void *) (Unknown Source:0)
cpptools.exe!thread_start<unsigned int (__stdcall*)(void *),1>() (Unknown Source:0)
kernel32.dll!@BaseThreadInitThunk@12�() (Unknown Source:0)
ntdll.dll!___RtlUserThreadStart@8�() (Unknown Source:0)
ntdll.dll!__RtlUserThreadStart@8�() (Unknown Source:0)

@sean-mcmanus
Copy link
Collaborator

I don't see any call stack that shows any work being stuck. The only one with work shows it's parsing defines from querying the compiler -- if you let the program run, does it show a different call stack for that thread?

@Dakror
Copy link

Dakror commented Feb 2, 2021

stepping up seemed to fail at the level of the regex iterator operator++. the program seems to be stuck there and repeat everything below it infinitely

@sean-mcmanus
Copy link
Collaborator

Oh, that is odd -- the regex is just being used to split the input into multiple lines. Not sure yet what could cause that to fail...

@Dakror
Copy link

Dakror commented Feb 2, 2021

Actually correction, the frame above it is the one running forever, the msvc::split_string

@sean-mcmanus
Copy link
Collaborator

sean-mcmanus commented Feb 2, 2021

Yeah, split_string uses the regex iterator in a loop. What compiler and version are you using?

What do you get when you use <compilerName> -Wp,-v -E -dD -x c++ nul? Some unexpected output might be causing the issue, such as non-English characters.

@Dakror
Copy link

Dakror commented Feb 3, 2021

clang -cc1 version 11.0.0 based upon LLVM 11.0.0 default target x86_64-pc-windows-msvc
ignoring nonexistent directory "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\atlmfc\include"
#include "..." search starts here:
#include <...> search starts here:
 C:\Program Files\LLVM\lib\clang\11.0.0\include
 C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\include
 C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt
 C:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\shared
 C:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\um
 C:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\winrt
End of search list.
# 1 "nul"
# 1 "<built-in>" 1
# 1 "<built-in>" 3
#define __llvm__ 1
#define __clang__ 1
#define __clang_major__ 11
#define __clang_minor__ 0
#define __clang_patchlevel__ 0
#define __clang_version__ "11.0.0 "
#define __ATOMIC_RELAXED 0
#define __ATOMIC_CONSUME 1
#define __ATOMIC_ACQUIRE 2
#define __ATOMIC_RELEASE 3
#define __ATOMIC_ACQ_REL 4
#define __ATOMIC_SEQ_CST 5
#define __OPENCL_MEMORY_SCOPE_WORK_ITEM 0
#define __OPENCL_MEMORY_SCOPE_WORK_GROUP 1
#define __OPENCL_MEMORY_SCOPE_DEVICE 2
#define __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES 3
#define __OPENCL_MEMORY_SCOPE_SUB_GROUP 4
#define __PRAGMA_REDEFINE_EXTNAME 1
#define __VERSION__ "Clang 11.0.0"
#define __OBJC_BOOL_IS_BOOL 0
#define __cpp_rtti 199711L
#define __cpp_exceptions 199711L
#define __cpp_unicode_characters 200704L
#define __cpp_raw_strings 200710L
#define __cpp_unicode_literals 200710L
#define __cpp_user_defined_literals 200809L
#define __cpp_lambdas 200907L
#define __cpp_constexpr 201304L
#define __cpp_constexpr_in_decltype 201711L
#define __cpp_range_based_for 200907
#define __cpp_static_assert 200410
#define __cpp_decltype 200707L
#define __cpp_attributes 200809L
#define __cpp_rvalue_references 200610L
#define __cpp_variadic_templates 200704L
#define __cpp_initializer_lists 200806L
#define __cpp_delegating_constructors 200604L
#define __cpp_nsdmi 200809L
#define __cpp_inheriting_constructors 201511L
#define __cpp_ref_qualifiers 200710L
#define __cpp_alias_templates 200704L
#define __cpp_threadsafe_static_init 200806L
#define __cpp_binary_literals 201304L
#define __cpp_digit_separators 201309L
#define __cpp_init_captures 201304L
#define __cpp_generic_lambdas 201304L
#define __cpp_decltype_auto 201304L
#define __cpp_return_type_deduction 201304L
#define __cpp_aggregate_nsdmi 201304L
#define __cpp_variable_templates 201304L
#define __cpp_impl_destroying_delete 201806L
#define __CONSTANT_CFSTRINGS__ 1
#define __DEPRECATED 1
#define _WCHAR_T_DEFINED 1
#define _NATIVE_WCHAR_T_DEFINED 1
#define __ORDER_LITTLE_ENDIAN__ 1234
#define __ORDER_BIG_ENDIAN__ 4321
#define __ORDER_PDP_ENDIAN__ 3412
#define __BYTE_ORDER__ __ORDER_LITTLE_ENDIAN__
#define __LITTLE_ENDIAN__ 1
#define __CHAR_BIT__ 8
#define __SCHAR_MAX__ 127
#define __SHRT_MAX__ 32767
#define __INT_MAX__ 2147483647
#define __LONG_MAX__ 2147483647L
#define __LONG_LONG_MAX__ 9223372036854775807LL
#define __WCHAR_MAX__ 65535
#define __WINT_MAX__ 65535
#define __INTMAX_MAX__ 9223372036854775807LL
#define __SIZE_MAX__ 18446744073709551615ULL
#define __UINTMAX_MAX__ 18446744073709551615ULL
#define __PTRDIFF_MAX__ 9223372036854775807LL
#define __INTPTR_MAX__ 9223372036854775807LL
#define __UINTPTR_MAX__ 18446744073709551615ULL
#define __SIZEOF_DOUBLE__ 8
#define __SIZEOF_FLOAT__ 4
#define __SIZEOF_INT__ 4
#define __SIZEOF_LONG__ 4
#define __SIZEOF_LONG_DOUBLE__ 8
#define __SIZEOF_LONG_LONG__ 8
#define __SIZEOF_POINTER__ 8
#define __SIZEOF_SHORT__ 2
#define __SIZEOF_PTRDIFF_T__ 8
#define __SIZEOF_SIZE_T__ 8
#define __SIZEOF_WCHAR_T__ 2
#define __SIZEOF_WINT_T__ 2
#define __SIZEOF_INT128__ 16
#define __INTMAX_TYPE__ long long int
#define __INTMAX_FMTd__ "lld"
#define __INTMAX_FMTi__ "lli"
#define __INTMAX_C_SUFFIX__ LL
#define __UINTMAX_TYPE__ long long unsigned int
#define __UINTMAX_FMTo__ "llo"
#define __UINTMAX_FMTu__ "llu"
#define __UINTMAX_FMTx__ "llx"
#define __UINTMAX_FMTX__ "llX"
#define __UINTMAX_C_SUFFIX__ ULL
#define __INTMAX_WIDTH__ 64
#define __PTRDIFF_TYPE__ long long int
#define __PTRDIFF_FMTd__ "lld"
#define __PTRDIFF_FMTi__ "lli"
#define __PTRDIFF_WIDTH__ 64
#define __INTPTR_TYPE__ long long int
#define __INTPTR_FMTd__ "lld"
#define __INTPTR_FMTi__ "lli"
#define __INTPTR_WIDTH__ 64
#define __SIZE_TYPE__ long long unsigned int
#define __SIZE_FMTo__ "llo"
#define __SIZE_FMTu__ "llu"
#define __SIZE_FMTx__ "llx"
#define __SIZE_FMTX__ "llX"
#define __SIZE_WIDTH__ 64
#define __WCHAR_TYPE__ unsigned short
#define __WCHAR_WIDTH__ 16
#define __WINT_TYPE__ unsigned short
#define __WINT_WIDTH__ 16
#define __SIG_ATOMIC_WIDTH__ 32
#define __SIG_ATOMIC_MAX__ 2147483647
#define __CHAR16_TYPE__ unsigned short
#define __CHAR32_TYPE__ unsigned int
#define __UINTMAX_WIDTH__ 64
#define __UINTPTR_TYPE__ long long unsigned int
#define __UINTPTR_FMTo__ "llo"
#define __UINTPTR_FMTu__ "llu"
#define __UINTPTR_FMTx__ "llx"
#define __UINTPTR_FMTX__ "llX"
#define __UINTPTR_WIDTH__ 64
#define __FLT_DENORM_MIN__ 1.40129846e-45F
#define __FLT_HAS_DENORM__ 1
#define __FLT_DIG__ 6
#define __FLT_DECIMAL_DIG__ 9
#define __FLT_EPSILON__ 1.19209290e-7F
#define __FLT_HAS_INFINITY__ 1
#define __FLT_HAS_QUIET_NAN__ 1
#define __FLT_MANT_DIG__ 24
#define __FLT_MAX_10_EXP__ 38
#define __FLT_MAX_EXP__ 128
#define __FLT_MAX__ 3.40282347e+38F
#define __FLT_MIN_10_EXP__ (-37)
#define __FLT_MIN_EXP__ (-125)
#define __FLT_MIN__ 1.17549435e-38F
#define __DBL_DENORM_MIN__ 4.9406564584124654e-324
#define __DBL_HAS_DENORM__ 1
#define __DBL_DIG__ 15
#define __DBL_DECIMAL_DIG__ 17
#define __DBL_EPSILON__ 2.2204460492503131e-16
#define __DBL_HAS_INFINITY__ 1
#define __DBL_HAS_QUIET_NAN__ 1
#define __DBL_MANT_DIG__ 53
#define __DBL_MAX_10_EXP__ 308
#define __DBL_MAX_EXP__ 1024
#define __DBL_MAX__ 1.7976931348623157e+308
#define __DBL_MIN_10_EXP__ (-307)
#define __DBL_MIN_EXP__ (-1021)
#define __DBL_MIN__ 2.2250738585072014e-308
#define __LDBL_DENORM_MIN__ 4.9406564584124654e-324L
#define __LDBL_HAS_DENORM__ 1
#define __LDBL_DIG__ 15
#define __LDBL_DECIMAL_DIG__ 17
#define __LDBL_EPSILON__ 2.2204460492503131e-16L
#define __LDBL_HAS_INFINITY__ 1
#define __LDBL_HAS_QUIET_NAN__ 1
#define __LDBL_MANT_DIG__ 53
#define __LDBL_MAX_10_EXP__ 308
#define __LDBL_MAX_EXP__ 1024
#define __LDBL_MAX__ 1.7976931348623157e+308L
#define __LDBL_MIN_10_EXP__ (-307)
#define __LDBL_MIN_EXP__ (-1021)
#define __LDBL_MIN__ 2.2250738585072014e-308L
#define __POINTER_WIDTH__ 64
#define __BIGGEST_ALIGNMENT__ 16
#define __WCHAR_UNSIGNED__ 1
#define __WINT_UNSIGNED__ 1
#define __INT8_TYPE__ signed char
#define __INT8_FMTd__ "hhd"
#define __INT8_FMTi__ "hhi"
#define __INT8_C_SUFFIX__
#define __INT16_TYPE__ short
#define __INT16_FMTd__ "hd"
#define __INT16_FMTi__ "hi"
#define __INT16_C_SUFFIX__
#define __INT32_TYPE__ int
#define __INT32_FMTd__ "d"
#define __INT32_FMTi__ "i"
#define __INT32_C_SUFFIX__
#define __INT64_TYPE__ long long int
#define __INT64_FMTd__ "lld"
#define __INT64_FMTi__ "lli"
#define __INT64_C_SUFFIX__ LL
#define __UINT8_TYPE__ unsigned char
#define __UINT8_FMTo__ "hho"
#define __UINT8_FMTu__ "hhu"
#define __UINT8_FMTx__ "hhx"
#define __UINT8_FMTX__ "hhX"
#define __UINT8_C_SUFFIX__
#define __UINT8_MAX__ 255
#define __INT8_MAX__ 127
#define __UINT16_TYPE__ unsigned short
#define __UINT16_FMTo__ "ho"
#define __UINT16_FMTu__ "hu"
#define __UINT16_FMTx__ "hx"
#define __UINT16_FMTX__ "hX"
#define __UINT16_C_SUFFIX__
#define __UINT16_MAX__ 65535
#define __INT16_MAX__ 32767
#define __UINT32_TYPE__ unsigned int
#define __UINT32_FMTo__ "o"
#define __UINT32_FMTu__ "u"
#define __UINT32_FMTx__ "x"
#define __UINT32_FMTX__ "X"
#define __UINT32_C_SUFFIX__ U
#define __UINT32_MAX__ 4294967295U
#define __INT32_MAX__ 2147483647
#define __UINT64_TYPE__ long long unsigned int
#define __UINT64_FMTo__ "llo"
#define __UINT64_FMTu__ "llu"
#define __UINT64_FMTx__ "llx"
#define __UINT64_FMTX__ "llX"
#define __UINT64_C_SUFFIX__ ULL
#define __UINT64_MAX__ 18446744073709551615ULL
#define __INT64_MAX__ 9223372036854775807LL
#define __INT_LEAST8_TYPE__ signed char
#define __INT_LEAST8_MAX__ 127
#define __INT_LEAST8_FMTd__ "hhd"
#define __INT_LEAST8_FMTi__ "hhi"
#define __UINT_LEAST8_TYPE__ unsigned char
#define __UINT_LEAST8_MAX__ 255
#define __UINT_LEAST8_FMTo__ "hho"
#define __UINT_LEAST8_FMTu__ "hhu"
#define __UINT_LEAST8_FMTx__ "hhx"
#define __UINT_LEAST8_FMTX__ "hhX"
#define __INT_LEAST16_TYPE__ short
#define __INT_LEAST16_MAX__ 32767
#define __INT_LEAST16_FMTd__ "hd"
#define __INT_LEAST16_FMTi__ "hi"
#define __UINT_LEAST16_TYPE__ unsigned short
#define __UINT_LEAST16_MAX__ 65535
#define __UINT_LEAST16_FMTo__ "ho"
#define __UINT_LEAST16_FMTu__ "hu"
#define __UINT_LEAST16_FMTx__ "hx"
#define __UINT_LEAST16_FMTX__ "hX"
#define __INT_LEAST32_TYPE__ int
#define __INT_LEAST32_MAX__ 2147483647
#define __INT_LEAST32_FMTd__ "d"
#define __INT_LEAST32_FMTi__ "i"
#define __UINT_LEAST32_TYPE__ unsigned int
#define __UINT_LEAST32_MAX__ 4294967295U
#define __UINT_LEAST32_FMTo__ "o"
#define __UINT_LEAST32_FMTu__ "u"
#define __UINT_LEAST32_FMTx__ "x"
#define __UINT_LEAST32_FMTX__ "X"
#define __INT_LEAST64_TYPE__ long long int
#define __INT_LEAST64_MAX__ 9223372036854775807LL
#define __INT_LEAST64_FMTd__ "lld"
#define __INT_LEAST64_FMTi__ "lli"
#define __UINT_LEAST64_TYPE__ long long unsigned int
#define __UINT_LEAST64_MAX__ 18446744073709551615ULL
#define __UINT_LEAST64_FMTo__ "llo"
#define __UINT_LEAST64_FMTu__ "llu"
#define __UINT_LEAST64_FMTx__ "llx"
#define __UINT_LEAST64_FMTX__ "llX"
#define __INT_FAST8_TYPE__ signed char
#define __INT_FAST8_MAX__ 127
#define __INT_FAST8_FMTd__ "hhd"
#define __INT_FAST8_FMTi__ "hhi"
#define __UINT_FAST8_TYPE__ unsigned char
#define __UINT_FAST8_MAX__ 255
#define __UINT_FAST8_FMTo__ "hho"
#define __UINT_FAST8_FMTu__ "hhu"
#define __UINT_FAST8_FMTx__ "hhx"
#define __UINT_FAST8_FMTX__ "hhX"
#define __INT_FAST16_TYPE__ short
#define __INT_FAST16_MAX__ 32767
#define __INT_FAST16_FMTd__ "hd"
#define __INT_FAST16_FMTi__ "hi"
#define __UINT_FAST16_TYPE__ unsigned short
#define __UINT_FAST16_MAX__ 65535
#define __UINT_FAST16_FMTo__ "ho"
#define __UINT_FAST16_FMTu__ "hu"
#define __UINT_FAST16_FMTx__ "hx"
#define __UINT_FAST16_FMTX__ "hX"
#define __INT_FAST32_TYPE__ int
#define __INT_FAST32_MAX__ 2147483647
#define __INT_FAST32_FMTd__ "d"
#define __INT_FAST32_FMTi__ "i"
#define __UINT_FAST32_TYPE__ unsigned int
#define __UINT_FAST32_MAX__ 4294967295U
#define __UINT_FAST32_FMTo__ "o"
#define __UINT_FAST32_FMTu__ "u"
#define __UINT_FAST32_FMTx__ "x"
#define __UINT_FAST32_FMTX__ "X"
#define __INT_FAST64_TYPE__ long long int
#define __INT_FAST64_MAX__ 9223372036854775807LL
#define __INT_FAST64_FMTd__ "lld"
#define __INT_FAST64_FMTi__ "lli"
#define __UINT_FAST64_TYPE__ long long unsigned int
#define __UINT_FAST64_MAX__ 18446744073709551615ULL
#define __UINT_FAST64_FMTo__ "llo"
#define __UINT_FAST64_FMTu__ "llu"
#define __UINT_FAST64_FMTx__ "llx"
#define __UINT_FAST64_FMTX__ "llX"
#define __USER_LABEL_PREFIX__
#define __FINITE_MATH_ONLY__ 0
#define __CLANG_ATOMIC_BOOL_LOCK_FREE 2
#define __CLANG_ATOMIC_CHAR_LOCK_FREE 2
#define __CLANG_ATOMIC_CHAR16_T_LOCK_FREE 2
#define __CLANG_ATOMIC_CHAR32_T_LOCK_FREE 2
#define __CLANG_ATOMIC_WCHAR_T_LOCK_FREE 2
#define __CLANG_ATOMIC_SHORT_LOCK_FREE 2
#define __CLANG_ATOMIC_INT_LOCK_FREE 2
#define __CLANG_ATOMIC_LONG_LOCK_FREE 2
#define __CLANG_ATOMIC_LLONG_LOCK_FREE 2
#define __CLANG_ATOMIC_POINTER_LOCK_FREE 2
#define __NO_INLINE__ 1
#define __PIC__ 2
#define __pic__ 2
#define __FLT_EVAL_METHOD__ 0
#define __FLT_RADIX__ 2
#define __DECIMAL_DIG__ __LDBL_DECIMAL_DIG__
#define __GCC_ASM_FLAG_OUTPUTS__ 1
#define __code_model_small__ 1
#define __amd64__ 1
#define __amd64 1
#define __x86_64 1
#define __x86_64__ 1
#define __SEG_GS 1
#define __SEG_FS 1
#define __seg_gs __attribute__((address_space(256)))
#define __seg_fs __attribute__((address_space(257)))
#define __k8 1
#define __k8__ 1
#define __tune_k8__ 1
#define __REGISTER_PREFIX__
#define __NO_MATH_INLINES 1
#define __FXSR__ 1
#define __SSE2__ 1
#define __SSE2_MATH__ 1
#define __SSE__ 1
#define __SSE_MATH__ 1
#define __MMX__ 1
#define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1 1
#define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_2 1
#define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 1
#define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8 1
#define _WIN32 1
#define _WIN64 1
#define _CPPRTTI 1
#define _CPPUNWIND 1
#define __BOOL_DEFINED 1
#define _MSC_VER 1928
#define _MSC_FULL_VER 192829336
#define _MSC_BUILD 1
#define _HAS_CHAR16_T_LANGUAGE_SUPPORT 1
#define _MSVC_LANG 201402L
#define _MSC_EXTENSIONS 1
#define _RVALUE_REFERENCES_V2_SUPPORTED 1
#define _RVALUE_REFERENCES_SUPPORTED 1
#define _NATIVE_NULLPTR_SUPPORTED 1
#define _INTEGRAL_MAX_BITS 64
#define _M_X64 100
#define _M_AMD64 100
#define __STDC_HOSTED__ 1
#define __cplusplus 201402L
#define __STDCPP_DEFAULT_NEW_ALIGNMENT__ 16ULL
#define __STDC_UTF_16__ 1
#define __STDC_UTF_32__ 1

# 1 "<command line>" 1
# 1 "<built-in>" 2
# 1 "nul" 2

@xolom
Copy link
Author

xolom commented Feb 3, 2021

I now finnally could manage to get lldb running with running csrutil enable --without debug on my MacBook!

Call stacks of cpptools:
(lldb) bt all
* thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGSTOP
  * frame #0: 0x00007fff202f370e libsystem_kernel.dylib`__read_nocancel + 10
    frame #1: 0x00007fff20239f0f libsystem_c.dylib`_sread + 16
    frame #2: 0x00007fff2023958a libsystem_c.dylib`__srefill1 + 24
    frame #3: 0x00007fff202396ac libsystem_c.dylib`__srget + 14
    frame #4: 0x00007fff20235567 libsystem_c.dylib`getc + 52
    frame #5: 0x00007fff2029a3a9 libc++.1.dylib`std::__1::__stdinbuf<char>::__getchar(bool) + 109
    frame #6: 0x0000000103ffb096 cpptools`std::__1::basic_istream<char, std::__1::char_traits<char> >& std::__1::getline<char, std::__1::char_traits<char>, std::__1::allocator<char> >(std::__1::basic_istream<char, std::__1::char_traits<char> >&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&, char) + 150
    frame #7: 0x0000000103fbabab cpptools`vscode::message_handler::main_loop() + 1739
    frame #8: 0x0000000103fb736e cpptools`main + 206
    frame #9: 0x00007fff20341621 libdyld.dylib`start + 1
    frame #10: 0x00007fff20341621 libdyld.dylib`start + 1
  thread #2
    frame #0: 0x00007fff202f67e2 libsystem_kernel.dylib`kevent + 10
    frame #1: 0x000000010467634a cpptools`uv__io_poll + 874
    frame #2: 0x000000010466f881 cpptools`uv_run + 465
    frame #3: 0x00000001045e6e69 cpptools`msvc::channel_manager_t::thread_proc() + 121
    frame #4: 0x00000001045e9b4e cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void (msvc::channel_manager_t::*)(), msvc::channel_manager_t*> >(void*) + 62
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #3
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #4
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #5
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #6
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #7
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #8
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #9
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #10
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #11
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #12
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #13
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #14
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #15
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #16
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #17
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #18
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010405cc0b cpptools`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x000000010405e681 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #19
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dd83 libc++.1.dylib`std::__1::condition_variable::__do_timed_wait(std::__1::unique_lock<std::__1::mutex>&, std::__1::chrono::time_point<std::__1::chrono::system_clock, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000000000l> > >) + 93
    frame #3: 0x000000010402b5ab cpptools`std::__1::cv_status std::__1::condition_variable::wait_until<std::__1::chrono::steady_clock, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000000000l> > >(std::__1::unique_lock<std::__1::mutex>&, std::__1::chrono::time_point<std::__1::chrono::steady_clock, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000000000l> > > const&) + 171
    frame #4: 0x000000010405e5f7 cpptools`unsigned int msvc::bitset_event_t::wait_for_any_set<long long, std::__1::ratio<1l, 1000l> >(std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000l> > const&, unsigned int) + 103
    frame #5: 0x000000010405e4f2 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::thread_pool()::$_0> >(void*) + 306
    frame #6: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #7: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #20
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dd83 libc++.1.dylib`std::__1::condition_variable::__do_timed_wait(std::__1::unique_lock<std::__1::mutex>&, std::__1::chrono::time_point<std::__1::chrono::system_clock, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000000000l> > >) + 93
    frame #3: 0x000000010402b5ab cpptools`std::__1::cv_status std::__1::condition_variable::wait_until<std::__1::chrono::steady_clock, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000000000l> > >(std::__1::unique_lock<std::__1::mutex>&, std::__1::chrono::time_point<std::__1::chrono::steady_clock, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000000000l> > > const&) + 171
    frame #4: 0x000000010402ad76 cpptools`vscode::message_deque<vscode::vscode_client_message, false>::try_pop_front(vscode::vscode_client_message&, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000l> >) + 118
    frame #5: 0x0000000104029cae cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, vscode::message_handler::main_loop()::$_3> >(void*) + 398
    frame #6: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #7: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #21
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010402b742 cpptools`vscode::message_deque<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, false>::pop_impl(bool) + 82
    frame #4: 0x000000010402b61d cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, vscode::message_handler::main_loop()::$_4> >(void*) + 77
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #22
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010402cff2 cpptools`vscode::message_deque<vscode::folding_ranges_params, false>::pop_impl(bool) + 82
    frame #4: 0x000000010402ce6d cpptools`std::__1::__function::__func<vscode::message_handler::main_loop()::$_6, std::__1::allocator<vscode::message_handler::main_loop()::$_6>, void ()>::operator()() + 61
    frame #5: 0x000000010402d5c3 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, std::__1::function<void ()> > >(void*) + 51
    frame #6: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #7: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #23
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010402c3a2 cpptools`vscode::message_deque<vscode::browse_engine_update_action, false>::pop_impl(bool) + 82
    frame #4: 0x000000010402bace cpptools`std::__1::__function::__func<vscode::message_handler::main_loop()::$_5, std::__1::allocator<vscode::message_handler::main_loop()::$_5>, void ()>::operator()() + 110
    frame #5: 0x000000010402d5c3 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, std::__1::function<void ()> > >(void*) + 51
    frame #6: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #7: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #24
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010402d832 cpptools`vscode::message_deque<vscode::vscode_client_message, false>::pop_impl(bool) + 98
    frame #4: 0x000000010402d70d cpptools`std::__1::__function::__func<vscode::message_handler::main_loop()::$_7, std::__1::allocator<vscode::message_handler::main_loop()::$_7>, void ()>::operator()() + 61
    frame #5: 0x000000010402d5c3 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, std::__1::function<void ()> > >(void*) + 51
    frame #6: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #7: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #25
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010402d832 cpptools`vscode::message_deque<vscode::vscode_client_message, false>::pop_impl(bool) + 98
    frame #4: 0x000000010402da3d cpptools`std::__1::__function::__func<vscode::message_handler::main_loop()::$_8, std::__1::allocator<vscode::message_handler::main_loop()::$_8>, void ()>::operator()() + 61
    frame #5: 0x000000010402d5c3 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, std::__1::function<void ()> > >(void*) + 51
    frame #6: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #7: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #26
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010402e0f2 cpptools`vscode::message_deque<vscode::message_handler::parse_file_entry, true>::pop_impl(bool) + 98
    frame #4: 0x000000010402dbf1 cpptools`std::__1::__function::__func<vscode::message_handler::main_loop()::$_9, std::__1::allocator<vscode::message_handler::main_loop()::$_9>, void ()>::operator()() + 97
    frame #5: 0x000000010402d5c3 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, std::__1::function<void ()> > >(void*) + 51
    frame #6: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #7: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #27
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010402d832 cpptools`vscode::message_deque<vscode::vscode_client_message, false>::pop_impl(bool) + 98
    frame #4: 0x000000010402e73c cpptools`std::__1::__function::__func<vscode::message_handler::main_loop()::$_10, std::__1::allocator<vscode::message_handler::main_loop()::$_10>, void ()>::operator()() + 76
    frame #5: 0x000000010402d5c3 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, std::__1::function<void ()> > >(void*) + 51
    frame #6: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #7: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #28
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010402e962 cpptools`vscode::message_deque<int, false>::pop_impl(bool) + 82
    frame #4: 0x000000010402e8bd cpptools`std::__1::__function::__func<vscode::message_handler::main_loop()::$_11, std::__1::allocator<vscode::message_handler::main_loop()::$_11>, void ()>::operator()() + 45
    frame #5: 0x000000010402d5c3 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, std::__1::function<void ()> > >(void*) + 51
    frame #6: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #7: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #29
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010402ec27 cpptools`std::__1::__function::__func<vscode::message_handler::main_loop()::$_12, std::__1::allocator<vscode::message_handler::main_loop()::$_12>, void ()>::operator()() + 183
    frame #4: 0x000000010402d5c3 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, std::__1::function<void ()> > >(void*) + 51
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #30
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x000000010467d3f9 cpptools`uv_cond_wait + 9
    frame #3: 0x000000010466b819 cpptools`worker + 89
    frame #4: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #5: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #31
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x000000010467d3f9 cpptools`uv_cond_wait + 9
    frame #3: 0x000000010466b819 cpptools`worker + 89
    frame #4: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #5: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #32
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x000000010467d3f9 cpptools`uv_cond_wait + 9
    frame #3: 0x000000010466b819 cpptools`worker + 89
    frame #4: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #5: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #33
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x000000010467d3f9 cpptools`uv_cond_wait + 9
    frame #3: 0x000000010466b819 cpptools`worker + 89
    frame #4: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #5: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
Call stacks of cpptools-srv:
(lldb) bt all
* thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGSTOP
  * frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dd83 libc++.1.dylib`std::__1::condition_variable::__do_timed_wait(std::__1::unique_lock<std::__1::mutex>&, std::__1::chrono::time_point<std::__1::chrono::system_clock, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000000000l> > >) + 93
    frame #3: 0x0000000100036d8b cpptools-srv`std::__1::cv_status std::__1::condition_variable::wait_until<std::__1::chrono::steady_clock, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000000000l> > >(std::__1::unique_lock<std::__1::mutex>&, std::__1::chrono::time_point<std::__1::chrono::steady_clock, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000000000l> > > const&) + 171
    frame #4: 0x000000010002dc86 cpptools-srv`bool msvc::event_t::wait_for<long long, std::__1::ratio<1l, 1l> >(std::__1::chrono::duration<long long, std::__1::ratio<1l, 1l> > const&) + 102
    frame #5: 0x000000010002d8a3 cpptools-srv`RunServer(unsigned int, char const*) + 787
    frame #6: 0x000000010002e0c4 cpptools-srv`main + 116
    frame #7: 0x00007fff20341621 libdyld.dylib`start + 1
  thread #2
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #3
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #4
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #5
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #6
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #7
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #8
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #9
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #10
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #11
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #12
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #13
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #14
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #15
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #16
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #17
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x00000001004262cb cpptools-srv`msvc::thread_pool::do_work(unsigned long) + 363
    frame #4: 0x0000000100427d41 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::add_threads()::$_1> >(void*) + 49
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #18
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dd83 libc++.1.dylib`std::__1::condition_variable::__do_timed_wait(std::__1::unique_lock<std::__1::mutex>&, std::__1::chrono::time_point<std::__1::chrono::system_clock, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000000000l> > >) + 93
    frame #3: 0x0000000100036d8b cpptools-srv`std::__1::cv_status std::__1::condition_variable::wait_until<std::__1::chrono::steady_clock, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000000000l> > >(std::__1::unique_lock<std::__1::mutex>&, std::__1::chrono::time_point<std::__1::chrono::steady_clock, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000000000l> > > const&) + 171
    frame #4: 0x0000000100427cb7 cpptools-srv`unsigned int msvc::bitset_event_t::wait_for_any_set<long long, std::__1::ratio<1l, 1000l> >(std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000l> > const&, unsigned int) + 103
    frame #5: 0x0000000100427bb2 cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, msvc::thread_pool::thread_pool()::$_0> >(void*) + 306
    frame #6: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #7: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #19
    frame #0: 0x00007fff202f67e2 libsystem_kernel.dylib`kevent + 10
    frame #1: 0x000000010049858a cpptools-srv`uv__io_poll + 874
    frame #2: 0x0000000100491ac1 cpptools-srv`uv_run + 465
    frame #3: 0x0000000100441719 cpptools-srv`msvc::channel_manager_t::thread_proc() + 121
    frame #4: 0x00000001004443fe cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void (msvc::channel_manager_t::*)(), msvc::channel_manager_t*> >(void*) + 62
    frame #5: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #6: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #20
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x000000010049f639 cpptools-srv`uv_cond_wait + 9
    frame #3: 0x000000010048da59 cpptools-srv`worker + 89
    frame #4: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #5: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #21
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x000000010049f639 cpptools-srv`uv_cond_wait + 9
    frame #3: 0x000000010048da59 cpptools-srv`worker + 89
    frame #4: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #5: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #22
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x000000010049f639 cpptools-srv`uv_cond_wait + 9
    frame #3: 0x000000010048da59 cpptools-srv`worker + 89
    frame #4: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #5: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #23
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x000000010049f639 cpptools-srv`uv_cond_wait + 9
    frame #3: 0x000000010048da59 cpptools-srv`worker + 89
    frame #4: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #5: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15
  thread #24
    frame #0: 0x00007fff202f48e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff20326e6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff2028dcf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010038ced8 cpptools-srv`a_compiler_thread::fetch_fragment() + 136
    frame #4: 0x00000001003b47dc cpptools-srv`before_tu_wrapup() + 348
    frame #5: 0x0000000100345f6e cpptools-srv`process_translation_unit(char const*, int, an_exported_template_file*) + 958
    frame #6: 0x0000000100042279 cpptools-srv`cfe_main(int, char**) + 121
    frame #7: 0x000000010036ecd9 cpptools-srv`cfe_main_exception_handler(int, char**) + 9
    frame #8: 0x0000000100042369 cpptools-srv`edg_main(int, char**) + 9
    frame #9: 0x00000001003619e4 cpptools-srv`edge_compiler_main(int, char const**) + 9220
    frame #10: 0x00000001003b4fb2 cpptools-srv`preparse(int, char const**, a_scout_store*, edge::translation_unit*) + 242
    frame #11: 0x000000010038cc98 cpptools-srv`a_compiler_thread::compiler_thread_routine(a_compiler_thread*) + 296
    frame #12: 0x00000001003abefc cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void (*)(a_compiler_thread*), a_compiler_thread*> >(void*) + 44
    frame #13: 0x00007fff20326950 libsystem_pthread.dylib`_pthread_start + 224
    frame #14: 0x00007fff2032247b libsystem_pthread.dylib`thread_start + 15

I noticed now that this behavior only occurs when i open a relatively big file (86k LOC) which is in another workspace, where "C_Cpp.default.browse.path": [] is set

@sean-mcmanus sean-mcmanus removed the not reproing We're not able to reproduce the issue (it's unlikely to get fixed until we find one). label Feb 10, 2021
@sean-mcmanus sean-mcmanus added this to the 1.2.1 milestone Feb 10, 2021
@Dakror
Copy link

Dakror commented Feb 10, 2021

Finally :D

@sean-mcmanus
Copy link
Collaborator

The issue doens't repro if the "-Xclang" arguments are removed, i.e. the bug is that the filtering out of the ipch file argument doesn't work with the "-Xclang" arguments.

@Dakror
Copy link

Dakror commented Feb 10, 2021

Depending on which single -Xclang you remove from the 6 that are in my command for instance, you get a different output...

@sean-mcmanus
Copy link
Collaborator

Yeah, we weren't handing -Xclang correctly in all cases and we weren't handling -include-pch correctly as well. The fixes should be in 1.2.1 unless we decide to delay it for some reason (eta Wednesday or Thursday).

@sean-mcmanus
Copy link
Collaborator

I moved it to #6944 since it doesn't like it's the same as the original issue.

@sean-mcmanus sean-mcmanus removed this from the 1.2.1 milestone Feb 10, 2021
@sean-mcmanus sean-mcmanus removed their assignment Feb 10, 2021
@sean-mcmanus sean-mcmanus added the more info needed The issue report is not actionable in its current state label Feb 10, 2021
@sean-mcmanus sean-mcmanus self-assigned this Feb 10, 2021
@sean-mcmanus
Copy link
Collaborator

@Dakror There also appears to be a lack of IntelliSense support for pch files so it looks like definitions for those won't be visible to IntelliSense. I filed an issue at #3628 , but it hasn't gotten enough upvotes. Not sure how much work that would take.

@Dakror
Copy link

Dakror commented Feb 10, 2021

I've noticed that IntelliSense consistently puts error squiggles under all my library includes after build completion, is this related? since I use PCH for everything really

@xolom
Copy link
Author

xolom commented Feb 10, 2021

I now could catch a call stack again. That looks more promising than the last one..

cpptools:

  thread #34
    frame #0: 0x00007fff2031b8e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff2034de6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff202b4cf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x0000000106c391eb cpptools`run_tag_parser() + 315
    frame #4: 0x0000000106bc353e cpptools`process_translation_unit(char const*, int, an_exported_template_file*) + 958
    frame #5: 0x00000001068bf849 cpptools`cfe_main(int, char**) + 121
    frame #6: 0x0000000106bebb99 cpptools`cfe_main_exception_handler(int, char**) + 9
    frame #7: 0x00000001068bf939 cpptools`edg_main(int, char**) + 9
    frame #8: 0x0000000106c3c9b1 cpptools`antlr_parse_routine() + 577
    frame #9: 0x0000000106c3ccd8 cpptools`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void (*)()> >(void*) + 40
    frame #10: 0x00007fff2034d950 libsystem_pthread.dylib`_pthread_start + 224
    frame #11: 0x00007fff2034947b libsystem_pthread.dylib`thread_start + 15

cpptools-srv:

  thread #24
    frame #0: 0x00007fff2031b8e2 libsystem_kernel.dylib`__psynch_cvwait + 10
    frame #1: 0x00007fff2034de6f libsystem_pthread.dylib`_pthread_cond_wait + 1254
    frame #2: 0x00007fff202b4cf2 libc++.1.dylib`std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 18
    frame #3: 0x000000010038ced8 cpptools-srv`a_compiler_thread::fetch_fragment() + 136
    frame #4: 0x00000001003b47dc cpptools-srv`before_tu_wrapup() + 348
    frame #5: 0x0000000100345f6e cpptools-srv`process_translation_unit(char const*, int, an_exported_template_file*) + 958
    frame #6: 0x0000000100042279 cpptools-srv`cfe_main(int, char**) + 121
    frame #7: 0x000000010036ecd9 cpptools-srv`cfe_main_exception_handler(int, char**) + 9
    frame #8: 0x0000000100042369 cpptools-srv`edg_main(int, char**) + 9
    frame #9: 0x00000001003619e4 cpptools-srv`edge_compiler_main(int, char const**) + 9220
    frame #10: 0x00000001003b4fb2 cpptools-srv`preparse(int, char const**, a_scout_store*, edge::translation_unit*) + 242
    frame #11: 0x000000010038cc98 cpptools-srv`a_compiler_thread::compiler_thread_routine(a_compiler_thread*) + 296
    frame #12: 0x00000001003abefc cpptools-srv`void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void (*)(a_compiler_thread*), a_compiler_thread*> >(void*) + 44
    frame #13: 0x00007fff2034d950 libsystem_pthread.dylib`_pthread_start + 224
    frame #14: 0x00007fff2034947b libsystem_pthread.dylib`thread_start + 15

Intellisense completely stopped working.

@sean-mcmanus
Copy link
Collaborator

sean-mcmanus commented Feb 10, 2021

@Dakror Actually, it looks like I was mistaken -- IntelliSense should still work when -include-pch is used (at least after our fixes to handling that argument)...our non-handling of pch files is just an optimization we're not doing, but the headers should be found via the normal mechanism still (they just have to be reparsed from the .h files like normal instead of re-used from the precompile files). If you still see error squiggles after 1.2.1 (assuming the fix makes it into that release), you could file a new issue so we could investigate (using the C/C++: Log Diagnostics and checking the C/C++ logging with "Debug" C_Cpp.loggingLevel could help identify the issue).

UPDATE: Specifically, the .hxx header should get picked up by the "-include" (forcedInclude) argument (after the -Xclang issue is fixed). Otherwise, paths might need to be added to includePath.

@xolom Those call stacks still show no work being done. Those threads are normally in that state when they don't have any work to process.

@xolom
Copy link
Author

xolom commented Feb 15, 2021

@Colengms
You asked for the actions that i did before that behavior occurs. I can now say that this always happens after following output:
Sending 1 changes to server
That line is mostly printed several times then intellisense flame icon appears and never goes away. I need to restart vscode and everthing starts to work again. the cpptools and cpptools-srv processes become zombie processes and that's why i had so many processes of them (mentioned in my prior post)

As the call stacks aren't showing any work being done, could it be some communication issue?
This really get's annoying..

@sean-mcmanus
Copy link
Collaborator

sean-mcmanus commented Feb 17, 2021

@xolom Yeah, 1.2.0 switched to a new interprocess communications system between cpptools and cpptools-srv, so something could be causing a communications failure. We're aware of 1 crash that could occur in either process -- not sure if that crash could lead to the symptoms you're seeing though (should be fixed with our pending 1.2.2-insiders, not 1.2.1). Some users at #6958 on Mac may be hitting the same issue.

@Dakror Your issue is fixed with https://github.com/microsoft/vscode-cpptools/releases/tag/1.2.1 .

@Dakror
Copy link

Dakror commented Feb 17, 2021

Yes, thank you so much!

@xolom
Copy link
Author

xolom commented Feb 17, 2021

@sean-mcmanus That other issue sounds very familiar and i think there is a connection.. I will keep trying to get a useful call stack.

@sean-mcmanus
Copy link
Collaborator

sean-mcmanus commented Feb 17, 2021

@xolom The issue we believe we have fixed for 1.2.2-insiders would be a 1.2.0 regression. I'm not sure if there would be an interesting call stack if that bug were hit. My previous comment mentioned a "crash", but it looks like it wouldn't be a crash, but some other interprocess communication failure, i.e. it seems like it could be the same issue you're hitting. I would wait till we release 1.2.2-insiders soon to see if that fixes it.

@sean-mcmanus sean-mcmanus added this to the 1.2.2 milestone Feb 17, 2021
@sean-mcmanus
Copy link
Collaborator

@sean-mcmanus sean-mcmanus added fixed Check the Milestone for the release in which the fix is or will be available. and removed more info needed The issue report is not actionable in its current state labels Feb 24, 2021
@sean-mcmanus sean-mcmanus removed their assignment Feb 24, 2021
@sean-mcmanus
Copy link
Collaborator

@xolom We believe this is fixed with https://github.com/microsoft/vscode-cpptools/releases/tag/1.2.2 . Let us know if you're still hitting issues.

@xolom
Copy link
Author

xolom commented Feb 26, 2021

So far i had no issues. Looks like it is fixed!
Many thanks!

@github-actions github-actions bot locked and limited conversation to collaborators Apr 12, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Feature: Code Formatting fixed Check the Milestone for the release in which the fix is or will be available. performance
Projects
None yet
Development

No branches or pull requests

6 participants