bytecodealliance / bytecodealliance/wasmtime

Cranelift: Support loading and storing vector types smaller than 128bit

Open
#10,254 1 comment 0 reactions 0 assignees View on GitHub
cranelift enhancement
Dominant language
Rust
Stars
18.6k
Forks
1.8k
Avg merge
1d 19h
Merged PRs (30d)
121

Description

#### Feature

While Cranelift can represent vector types smaller than 128bit, load and store operations for these smaller vector types are not implemented.

#### Benefit

Rustc has started passing vector types in vector registers on x86_64. Some of these vector types may be smaller than 128bit. Previously these vector types didn't need to be exposed to Cranelift as all vector operations are emulated by cg_clif using scalar operations. However now that they are passed in vector registers, cg_clif needs to use vector types at the ABI level and thus needs to support loading and storing small vectors.

#### Implementation

TODO: Do you have an implementation plan, and/or ideas for data structures or
algorithms to use?

#### Alternatives

Have a bunch of code in cg_clif dedicated to handling this. I probably need this anyway for the time being, but I prefer if I can get rid of it as soon as possible through native Cranelift support.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.