Skip to content

[Wasm][AOT] Using Array.Sort falls back to the interpreter #81403

@jeromelaban

Description

@jeromelaban

Description

When running Array.Sort the AOT compiler falls back to the interpreter.

image

Sample code :

var length = 1000;
var arr = new Span<int>(new int[length]);
for (var i = 0; i < length; i++)
{
    arr[i] = (int)Random.Shared.Next();
}

var temp = new int[length];
for (var j = 0; j < 500; j++)
{
    arr.CopyTo(temp);
    Array.Sort(temp);
}

Configuration

https://github.com/dotnet/runtime/tree/release/7.0

Regression?

No, likely always was behaving this way.

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions