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

tag parser freeze on parsing large define #9076

Closed
dibalavs opened this issue Mar 23, 2022 · 10 comments
Closed

tag parser freeze on parsing large define #9076

dibalavs opened this issue Mar 23, 2022 · 10 comments
Labels
bug fixed Check the Milestone for the release in which the fix is or will be available. Language Service performance verified Bug has been reproduced Visual Studio Inherited from Visual Studio
Milestone

Comments

@dibalavs
Copy link

Issue Type: Bug

In attachment - simple project.
tag parser freezes when try to parse test.h file

Extension version: 1.8.4
VS Code version: Code 1.65.2 (c722ca6c7eed3d7987c0d5c3df5c45f6b15e77d1, 2022-03-10T15:36:26.048Z)
OS version: Linux x64 5.4.0-100-generic
Restricted Mode: No

System Info
Item Value
CPUs Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz (8 x 3923)
GPU Status 2d_canvas: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
opengl: enabled_on
rasterization: disabled_software
skia_renderer: enabled_on
video_decode: disabled_software
vulkan: disabled_off
webgl: enabled
webgl2: enabled
Load (avg) 6, 5, 4
Memory (System) 31.25GB (0.75GB free)
Process Argv --unity-launch
Screen Reader no
VM 0%
DESKTOP_SESSION ubuntu
XDG_CURRENT_DESKTOP Unity
XDG_SESSION_DESKTOP ubuntu
XDG_SESSION_TYPE x11
@dibalavs
Copy link
Author

vscode_bug.tar.gz

@sean-mcmanus
Copy link
Collaborator

Does that test.h have a lot of defines? If so, it's bug #6454 .

@sean-mcmanus sean-mcmanus self-assigned this Mar 23, 2022
@sean-mcmanus sean-mcmanus added Language Service more info needed The issue report is not actionable in its current state labels Mar 23, 2022
@dibalavs
Copy link
Author

@sean-mcmanus , No. It has only 1 define. but very large.

@sean-mcmanus
Copy link
Collaborator

Are you able to paste the contents of the define inline? I can't seem to download https://github.com/microsoft/vscode-cpptools/files/8333962/vscode_bug.tar.gz .

@dibalavs
Copy link
Author

strange. I will re-attach file
vscode_bug.tar.gz

@dibalavs
Copy link
Author

@sean-mcmanus Please check attachment again.

@sean-mcmanus
Copy link
Collaborator

Okay, I repro the issue. Do you know if it ever finishes? Our parser is "stuck" processing the define. Not sure if it's just slow or permanently stuck. As a workaround you can add that folder that file belongs to to the C_Cpp.files.exclude setting or the file if you change the C_Cpp.exclusionPolicy to work for files.

@sean-mcmanus sean-mcmanus added bug performance Visual Studio Inherited from Visual Studio verified Bug has been reproduced and removed more info needed The issue report is not actionable in its current state labels Mar 24, 2022
@sean-mcmanus
Copy link
Collaborator

sean-mcmanus commented Mar 24, 2022

Also, the issue's cause is different from #6454 .

@sean-mcmanus
Copy link
Collaborator

I get a crash after about an hour. I've filed a bug on VS at https://developercommunity.visualstudio.com/t/c-tag-parser-gets-stuck-parsing-for-an-hour-and-th/1702811 -- that issue might not be publicly viewable though.

@sean-mcmanus sean-mcmanus removed their assignment Mar 25, 2022
@bobbrow bobbrow added this to the Tracking milestone Apr 5, 2022
@sean-mcmanus sean-mcmanus modified the milestones: Tracking, 1.10.3 May 18, 2022
@sean-mcmanus sean-mcmanus added the fixed Check the Milestone for the release in which the fix is or will be available. label May 18, 2022
@sean-mcmanus
Copy link
Collaborator

This is fixed with 1.10.3 (pre-release).

@github-actions github-actions bot locked and limited conversation to collaborators Jul 24, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug fixed Check the Milestone for the release in which the fix is or will be available. Language Service performance verified Bug has been reproduced Visual Studio Inherited from Visual Studio
Projects
None yet
Development

No branches or pull requests

3 participants