You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When initializing Vector128 with constant float/double value (e.g., Vector128.Create(2.0f)) the values are loaded into 32/64-bit register (fmov) and then duplicated into 128-bit register (dup.4s/2d). For immediate floating-point constants on Arm64 this can be optimized into a single fmovFMOV (vector, immediate) which copies the immediate constant into every element of the 128-bit register.
With AOT LLVM the behavior is already optimized and it uses fmov.4s/2d to directly fill the 128-bit register.
Steps to take:
Move the Arm64 immediate floating-point constant check functionality to a separate function so that it can be used both for float/double types as well as for vector types.
When initializing Vector128 with constant
float
/double
value (e.g.,Vector128.Create(2.0f)
) the values are loaded into 32/64-bit register (fmov
) and then duplicated into 128-bit register (dup.4s/2d
). For immediate floating-point constants on Arm64 this can be optimized into a singlefmov
FMOV (vector, immediate) which copies the immediate constant into every element of the 128-bit register.With AOT LLVM the behavior is already optimized and it uses
fmov.4s/2d
to directly fill the 128-bit register.Steps to take:
float
/double
types as well as for vector types.runtime/src/mono/mono/mini/mini-arm64.c
Lines 4876 to 4906 in ff2de36
fmov
for immediate constants.The text was updated successfully, but these errors were encountered: