Skip to content

ILLinker corrupts exception handler ranges for method #1507

@BrzVlad

Description

@BrzVlad

Steps to reproduce:

  1. Install VS 16.8 Preview 3 and .net 5.0 rc1
  2. Build https://github.com/modulardev2/ThreadException (Client wasm project)
  3. Go to binaries folder, disassemble System.Net.Http.dll, look for method <GetStringAsyncCore>d__41 MoveNext (). The EH clause ranges for the method are correct
  4. Publish the same project (folder publish). Go to binaries folder, disassemble System.Net.Http.dll, look for same method as before and notice the clause ranges have been corrupted.

As part for publishing, _RunILLink is ran. This goes over the assemblies from the sdk, which are correct, and outputs them in the obj\Release\net5.0\linked\ folder. At this moment the method is corrupted. The linker seems to run as follows : https://gist.github.com/BrzVlad/e0f358c9d096c5acef745a1c49aae8d1

While I haven't tried building the project from linux with dotnet command, the behavior should be the same.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions