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

Support reading embedded source #16

Merged
merged 2 commits into from
Aug 4, 2016
Merged

Conversation

nguerrera
Copy link
Contributor

@nguerrera nguerrera commented Jul 7, 2016

No description provided.

@nguerrera nguerrera changed the title Support reading embedded source Support reading embedded source (WIP) Jul 12, 2016
@nguerrera nguerrera force-pushed the embed-source-in-pdb branch 3 times, most recently from 73964d7 to 7697b0c Compare July 13, 2016 23:38
@nguerrera nguerrera changed the title Support reading embedded source (WIP) Support reading embedded source Jul 13, 2016
@nguerrera
Copy link
Contributor Author

@tmat Ready for review. Updated to match spec change and added tests.

// https://github.com/dotnet/corefx/issues/8004 tracks adding that API to corefx and
// this should be updated to use that when it's fixed. In the meantime, we are forced
// to make an extra copy here.
Array.Copy(reader.ReadBytes(count), source, count);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we just add that one API now? Seems like making an extra copy here would be pretty significant hit.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure. I'll send a PR.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The feature is in corefx master, but corefx build is currently blocked.

@tmat
Copy link
Member

tmat commented Aug 1, 2016

I have updated DSRN to the latest build. We can now add tests.

@nguerrera
Copy link
Contributor Author

@tmat I've updated to match latest Roslyn PR, but DSRN still doesn't have my changes. Tests are still asserting NativeNotYetImplemented(). :(

@nguerrera
Copy link
Contributor Author

nguerrera commented Aug 4, 2016

@tmat false alarm (forgot to restore and got old DSRN). There is an issue in the native PDBs I'm generating so I'm backing that out from initial Roslyn PR. I've disabled the native test.

@@ -37,6 +37,9 @@
<ItemGroup>
<Compile Include="PdbConverterTests.cs" />
</ItemGroup>
<ItemGroup>
<Service Include="{82A7F48D-3B50-4B1E-B82E-3ADA8210C358}" />
</ItemGroup>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test explorer adds this. I'm tired of reverting it. OK to leave it?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK.

@nguerrera
Copy link
Contributor Author

@tmat Please review. Can we merge without the no-copy optimization (blocked on corefx build) and native support (pulling from Roslyn PR).


namespace Microsoft.DiaSymReader.PortablePdb.UnitTests
{
using System.Linq;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are these intentionally here, or could they be move up?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SymTestHelpers copied from elsewhere, causes ctrl + . to put more usings next to it. I'll move System.Linq.

@tmat
Copy link
Member

tmat commented Aug 4, 2016

👍 (a couple of minor suggestions)

@nguerrera
Copy link
Contributor Author

Applied all the suggestions.

@tmat tmat merged commit 2e5ed44 into dotnet:master Aug 4, 2016
@nguerrera nguerrera deleted the embed-source-in-pdb branch August 4, 2016 04:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants