StructLayout: Immediate VS crash on button press

In one (but not all) of my projects, the entire Studio immediately crashes half a second or so after I click the “show struct layout” Button. No error messages or anything.

When I run the studio with devenv /log, the last two log entries are:

  <entry>
    <record>728</record>
    <time>2020/10/31 06:30:09.126</time>
    <type>Warning</type>
    <source>GlobalBrokeredServiceContainer</source>
    <description>Request for &quot;Microsoft.VisualStudio.Shell.Internal.SettingsManager (1.0)&quot; from Process denied because the service is only exposed RemoteExclusiveClient, LiveShareGuest.</description>
  </entry>
  <entry>
    <record>729</record>
    <time>2020/10/31 06:30:09.126</time>
    <type>Warning</type>
    <source>GlobalBrokeredServiceContainer</source>
    <description>Request for proxy to &quot;Microsoft.VisualStudio.Shell.Internal.SettingsManager (1.0)&quot; is declined: ServiceAudienceMismatch.</description>
  </entry>
</activity>

Any other kind of log I could post to help?

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Reactions: 1
  • Comments: 18 (8 by maintainers)

Most upvoted comments

ok. the cmake --build . still fails with compiler errors it wants me to send to google. The .inc files in clang\AST don’t get generated.

Building X86GenDAGISel.inc… PLEASE submit a bug report to https://bugs.llvm.org/ and include the crash backtrace. Stack dump: 0. Program arguments: …\…\…\Debug\bin\llvm-tblgen.exe -gen-dag-isel -I E:/StructLayout/llvm-project/ll vm/lib/Target/X86 -IE:/StructLayout/llvm-project/build/include -IE:/StructLayout/llvm-project/llvm/include -I E:/Stru ctLayout/llvm-project/llvm/lib/Target -omit-comments --long-string-literals=0 E:/StructLayout/llvm-project/llvm/lib/T arget/X86/X86.td -o E:/StructLayout/llvm-project/build/lib/Target/X86/X86GenDAGISel.inc #0 0x7c55b94b (C:\Windows\SYSTEM32\ucrtbased.dll+0x8b94b) #1 0x7c55e40c (C:\Windows\SYSTEM32\ucrtbased.dll+0x8e40c)

As a pure guess, maybe it’s b/c I’m using the latest VS 2019 compiler?

Update: Going to try building from the IDE, opening ALL_BUILD.vccproj

Thanks for the details, glad to help. I made sure I pulled the latest lvm-project source and made the mods to match yours. I deleted my build dir and recreated with your cmds. It’s now running the cmake --build . (I assume I need to run that to build the libs needed). I will try to build LayoutParser once that’s done.

If you have time to try this out I would really appreciate it. Thanks.

I updated my comment with the results I see. As you see, I also hit the stack overflow exception.

We do use -std=c++17

So with the newest version, this still crashes - but different. VS doesn’t close itself immediately but rather hangs indefinitely while a windows problem reporting process hogs the task manager. But they never finish, even after a minute or so.

I got frustrated with the LLVM install instructions (They say to cd ..\.. but that throws me absolutely not “where I started” obviously) and gave up honestly. But if this can’t be solved otherwise I’ll dig into it.

That worked!

LayoutParser.cs:

image

Which probably doesn’t tell much and I should really compile that layoutparser project properly myself.

After that, things end as expected:

An unhandled exception of type 'System.StackOverflowException' occurred in StructLayout.dll
The program '[71184] devenv.exe: Program Trace' has exited with code 0 (0x0).
The program '[71184] devenv.exe' has exited with code -2147023895 (0x800703e9).

So I duplicated the entire project and deleted every file and started with just a trivial source.cpp… that works. So that should rule anything specific about the vcxproj itself. Good news I guess? I’m gonna dig around more.