Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@thaystg
Copy link
Contributor

@thaystg thaystg commented Feb 17, 2020

To fix the issue of enable reading embedded pdb everywhere the problem was that when the roslyn tests are compiling sources it creates embedded pdb with source file "", and before enable reading the embedded pdb we don't read this information, and now we read and our StackTrace corlib doesn't expect a source file "", it's okay if it's NULL but not "".
I could fix in corlib or in mono, I prefer to fix on mono because I don't know if there is any other place in corlib that doesn't expect source file "".

…lot.

To fix the issue of enabling embedded pdb everywhere the problem was that when the roslyn tests are compiling sources it creates embedded pdb with source file "", and before enable reading the embedded pdb we don't read this information, and now we read and our StackTrace file written in our corlib doesn't expect a source file "", it's okay if it's NULL but not "".
I could fix in corlib or in mono, I prefer to fix on mono because I don't know if there is any other place that doesn't expect source file "".

TEST_HARNESS = $(topdir)/class/lib/$(PROFILE_DIRECTORY)/$(PARENT_PROFILE)nunit-lite-console.exe
PLATFORM_DEBUG_FLAGS = /debug:portable
PLATFORM_DEBUG_FLAGS = /debug:embedded
Copy link
Contributor

Choose a reason for hiding this comment

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

Be sure to test both/all, not delete one test to add another.

Copy link
Contributor

Choose a reason for hiding this comment

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

Also, can these settings be combined -- portable and embedded?

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah, embedded implies portable.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I removed this change, I will do this in another PR.


$(test_output_dir)/dtest-excfilter.exe: Test/dtest-excfilter.il | $(test_output_dir)
$(ILASM) -out:$@ /exe /debug Test/dtest-excfilter.il
$(ILASM) -out:$@ /exe /debug:embedded Test/dtest-excfilter.il
Copy link
Contributor

Choose a reason for hiding this comment

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

Be sure to test both/all, not delete one test to add another.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I removed this change, I will do this in another PR.


// Temporarily disabled to unblock Roslyn
#if HOST_WIN32 || HOST_WASM
#if HOST_WIN32 || HAVE_SYS_ZLIB
Copy link
Contributor

Choose a reason for hiding this comment

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

Are embedded pdbs always compressed?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think yes

Copy link
Contributor

Choose a reason for hiding this comment

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

Don't you also need the HOST_WASM here? I thought wasm doesn't have a system zlib?

@thaystg
Copy link
Contributor Author

thaystg commented Feb 18, 2020

@monojenkins build failed

@thaystg thaystg requested a review from jaykrell February 18, 2020 12:18

location = g_new0 (MonoDebugSourceLocation, 1);
location->source_file = docname;
if (docname != NULL && docname[0] != 0)
Copy link
Contributor

Choose a reason for hiding this comment

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

cosmetic: if (docname && docname [0])

Copy link
Contributor

@jaykrell jaykrell Feb 18, 2020

Choose a reason for hiding this comment

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

or if (!docname || docname [0])
because replacing null with null is an identity, but maybe that is too subtle.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done!

@thaystg
Copy link
Contributor Author

thaystg commented Feb 18, 2020

@monojenkins build Linux AArch64

Copy link
Contributor

@CoffeeFlux CoffeeFlux left a comment

Choose a reason for hiding this comment

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

Thanks for sorting this out. Figured it would be something silly I missed :(

Might still be worth bringing up with the Roslyn team to see if that's intended behavior? This fix should go in regardless though, given it works in CoreCLR.


// Temporarily disabled to unblock Roslyn
#if HOST_WIN32 || HOST_WASM
#if HOST_WIN32 || HAVE_SYS_ZLIB
Copy link
Contributor

Choose a reason for hiding this comment

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

Don't you also need the HOST_WASM here? I thought wasm doesn't have a system zlib?

@lambdageek
Copy link
Member

This is related to #17209

@thaystg
Copy link
Contributor Author

thaystg commented Feb 18, 2020

@monojenkins build failed

@thaystg
Copy link
Contributor Author

thaystg commented Feb 19, 2020

@monojenkins build Linux ARMv5

@thaystg thaystg merged commit dd5926c into mono:master Feb 20, 2020
@Therzok
Copy link
Contributor

Therzok commented Feb 26, 2020

Is this getting backported to any current release?

@thaystg
Copy link
Contributor Author

thaystg commented Feb 26, 2020

@monojenkins backport 2020-02

@monojenkins
Copy link
Contributor

@thaystg backporting to 2020-02 failed, the patch results in conflicts:

Applying: Running the debugger tests using embedded pdb as this will be used a lot. To fix the issue of enabling embedded pdb everywhere the problem was that when the roslyn tests are compiling sources it creates embedded pdb with source file "", and before enable reading the embedded pdb we don't read this information, and now we read and our StackTrace file written in our corlib doesn't expect a source file "", it's okay if it's NULL but not "". I could fix in corlib or in mono, I prefer to fix on mono because I don't know if there is any other place that doesn't expect source file "".
Applying: Removing comment
Using index info to reconstruct a base tree...
M	mono/metadata/debug-mono-ppdb.c
Falling back to patching base and 3-way merge...
Auto-merging mono/metadata/debug-mono-ppdb.c
CONFLICT (content): Merge conflict in mono/metadata/debug-mono-ppdb.c
error: Failed to merge in the changes.
Patch failed at 0002 Removing comment

Please backport manually!

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.

6 participants