Skip to content

Conversation

@cshung
Copy link
Contributor

@cshung cshung commented Feb 13, 2025

Problem

#3397

Solution

  • To support disassembling PE images stored only in memory,
  • The ReadyToRunReader is updated in this PR to support disassembling input given as a ImmutableArray<byte>.
  • This change provide the image content to the ReadyToRunReader so that it can perform the disassembling duty.
  • The change is tested by disassembling a simple single file bundle, with locally built ReadyToRunReader.

This change will NOT compile until we have the package updated, this CI is expected to fail for now.

@christophwille
Copy link
Member

@cshung will that also close #3337 or is the work you mentioned still open?

@cshung
Copy link
Contributor Author

cshung commented Feb 25, 2025

@cshung will that also close #3337 or is the work you mentioned still open?

This PR is unrelated to #3337. I think #3337 should be closed with #3340 as the package is already updated there.

@christophwille
Copy link
Member

What are the chances we can get this in during March?

@cshung
Copy link
Contributor Author

cshung commented Mar 12, 2025

What are the chances we can get this in during March?

I have merged the change on the runtime repo side, however, it looks like the new package is going to depend on System.Reflection.Metadata with version 10.0.0-preview.3.25152.4 or above.

@christophwille
Copy link
Member

Although even today we "up" the dependency for SRM in ILSpy vs ICS.Decompiler, taking on a preview dependency for a RTM version of ours (your PR was dog-eared for 9.1) might be a hard pill to swallow.

@christophwille
Copy link
Member

christophwille commented Apr 11, 2025

@cshung I suppose this https://www.nuget.org/packages/System.Reflection.Metadata/10.0.0-preview.3.25171.5 would be the new package? (to replace 9.0.1 here

<PackageVersion Include="System.Reflection.Metadata" Version="9.0.1" />
)

@cshung cshung force-pushed the public/disassemble-single-file-bundle branch from 75abee7 to b0f4fc5 Compare April 13, 2025 17:23
@cshung
Copy link
Contributor Author

cshung commented Apr 13, 2025

@cshung I suppose this https://www.nuget.org/packages/System.Reflection.Metadata/10.0.0-preview.3.25171.5 would be the new package? (to replace 9.0.1 here)

Yes! Assuming we are going to upgrade SRM to 10, I have rebased my PR and upgraded the package. This PR is now functional to disassemble ready to run code in a single file bundle.

@christophwille
Copy link
Member

ICSharpCode.Decompiler.csproj should not be touched - the "old" packages there are very much intentional (yes, a bog standard NuGet update will unknowingly wreak havoc)

@cshung cshung force-pushed the public/disassemble-single-file-bundle branch from 1c94194 to 2edccad Compare April 15, 2025 15:47
@cshung
Copy link
Contributor Author

cshung commented May 6, 2025

@christophwille, hello?

@christophwille
Copy link
Member

@siegfriedpammer is working on moving ILSpy to. NET 10, that is why we postponed merging this PR. Sorry for not telling you.

@siegfriedpammer siegfriedpammer force-pushed the public/disassemble-single-file-bundle branch from 2edccad to eaf0eca Compare July 4, 2025 17:49
@siegfriedpammer siegfriedpammer force-pushed the public/disassemble-single-file-bundle branch from eaf0eca to 9beb9cb Compare July 4, 2025 19:28
@siegfriedpammer siegfriedpammer merged commit f311afa into icsharpcode:master Jul 4, 2025
5 checks passed
@christophwille
Copy link
Member

@cshung thanks and sorry it took so long!

@siegfriedpammer siegfriedpammer linked an issue Jul 8, 2025 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Can't open the .NET bundle file (R2R).

3 participants