Skip to content

Conversation

@kant2002
Copy link
Contributor

@kant2002 kant2002 commented Feb 8, 2022

If element in the cache, properly return success creation status

@ghost ghost added community-contribution Indicates that the PR has been added by a community member area-System.Runtime.InteropServices and removed community-contribution Indicates that the PR has been added by a community member labels Feb 8, 2022
@ghost
Copy link

ghost commented Feb 8, 2022

Tagging subscribers to this area: @dotnet/interop-contrib
See info in area-owners.md if you want to be subscribed.

Issue Details

If element in the cache, properly return success creation status

Author: kant2002
Assignees: -
Labels:

area-System.Runtime.InteropServices

Milestone: -

Copy link
Member

@AaronRobinsonMSFT AaronRobinsonMSFT left a comment

Choose a reason for hiding this comment

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

Do we have a test for this? I assume we can use the one we have for CoreCLR, but don't run that on NativeAOT at the moment. @MichalStrehovsky is that fair?

@kant2002
Copy link
Contributor Author

kant2002 commented Feb 8, 2022

We seems to be have Smoke tests which similar to scenario where I hit this bug.

public static void TestRCWRoundTripRequireUnwrap()

I think this tests should catch this

static void ValidateCreateObjectCachingScenario()

And this test was enabled in runtimelab. So I'm puzzled a bit.

@kant2002
Copy link
Contributor Author

kant2002 commented Feb 8, 2022

To be precise. My scenario was

cw.GetOrCreateObjectForComInstance(ptr, CreateObjectFlags.None);
cw.GetOrCreateObjectForComInstance(ptr, CreateObjectFlags.Unwrap);

@MichalStrehovsky
Copy link
Member

Do we have a test for this? I assume we can use the one we have for CoreCLR, but don't run that on NativeAOT at the moment. @MichalStrehovsky is that fair?

Yes, eventually we should run all the Pri-0 interop tests in the CI. I'm standing up more of the CI as I'm typing this.

@MichalStrehovsky
Copy link
Member

The NativeAOT arm64 failures are unrelated. I think I'll need to pull the NativeAOT ARM64 testing until the issues are root caused. Lucky for me, it found an infra issue where the ARM64 machines are not configured to collect dumps, so can't even get a dump out of this :(.

@MichalStrehovsky MichalStrehovsky merged commit 49e46e3 into dotnet:main Feb 9, 2022
@kant2002 kant2002 deleted the patch-3 branch February 9, 2022 03:28
@ghost ghost locked as resolved and limited conversation to collaborators Mar 11, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants