Skip to content

[Arm64] Add Short Vector ABI support for HW Intrinsics #9599

@sdmaclea

Description

@sdmaclea

The types Vector64<T> and Vector128<T> are intended to map to ABI Short Vector fundamental types. These should be passed in vector registers.

Current code will pass these in integer registers.

IsShortVector can be crudely implemented as follows:

bool Compiler::IsShortVector(CORINFO_CLASS_HANDLE hClass)
{
    return isIntrinsicType(hClass) && (getBaseTypeOfSIMDType(hClass) != TYP_UNKNOWN);
}

Compiler::getPrimitiveTypeForStruct() can be trivially updated to return TYP_SIMD8 or TYP_SIMD16 when IsShortVector() == true

I made an initial naive attempt to implement and failed, but I really need a design discussion.

@CarolEidt @tannergooding @dotnet/arm64-contrib @dotnet/jit-contrib

category:reach
theme:intrinsics
skill-level:expert
cost:medium

Metadata

Metadata

Assignees

Labels

arch-arm64area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMIenhancementProduct code improvement that does NOT require public API changes/additions

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions