nuget server logo nuget api documents
↑

API Docs / Microsoft.VisualBasic.Runtime / SIMDEnvironment

SIMDEnvironment

Full name Microsoft.VisualBasic.Math.SIMD.SIMDEnvironment Assembly Microsoft.VisualBasic.Runtime Members 17

SIMD(Single Instruction Multiple Data)即单指令流多数据流, 是一种采用一个控制器来控制多个处理器,同时对一组数据(又称“数据 向量”)中的每一个分别执行相同的操作从而实现空间上的并行性的技术。 简单来说就是一个指令能够同时处理多个数据。

00 Remarks

逐元素内核(SimdEngine / SimdMath)不会对 输入数组做长度一致性检查,默认调用方已经保证这一点;而 归约与点积(SimdReduce)会显式校验长度并抛出 ArgumentException。

01 Syntax

Microsoft.VisualBasic.Math.SIMD.SIMDEnvironment

02 Properties

NameOverloadsSummary
config 1 【兼容保留】SIMD 计算模式配置。
IsEnabled 1 当前的 SIMD 是否启用。等价于 config <> disable 并且 硬件确实支持向量加速。
IsHardwareAccelerated 1 委托到 SimdCapabilities.IsHardwareAccelerated。
IsFmaSupported 1 委托到 SimdCapabilities.IsFma。
IsAvx2Supported 1 委托到 SimdCapabilities.IsAvx2。
IsAdvSimdSupported 1 委托到 SimdCapabilities.IsAdvSimd。
Description 1 当前处理器的能力描述文本。

03 Fields

NameOverloadsSummary
countDouble 2 Vector(Of Double).Count
countFloat 2 Vector(Of Single).Count
countInteger 2 Vector(Of Integer).Count
countLong 2 Vector(Of Long).Count
countShort 2 Vector(Of Short).Count

04 Members

property config #
config

【兼容保留】SIMD 计算模式配置。

Remarks

为了保持与旧代码的二进制/源码兼容,这个属性仍然存在且可读写; 但只有 SIMDConfiguration.disable 会影响实际分派结果 (强制走纯标量路径),其余取值统一按自动探测处理。

property IsEnabled #
IsEnabled

当前的 SIMD 是否启用。等价于 config <> disable 并且 硬件确实支持向量加速。

property IsHardwareAccelerated #
IsHardwareAccelerated
property IsFmaSupported #
IsFmaSupported
property IsAvx2Supported #
IsAvx2Supported
property IsAdvSimdSupported #
IsAdvSimdSupported
property Description #
Description

当前处理器的能力描述文本。

field countDouble #
countDouble

Vector(Of Double).Count

field countFloat #
countFloat

Vector(Of Single).Count

field countInteger #
countInteger

Vector(Of Integer).Count

field countLong #
countLong

Vector(Of Long).Count

field countShort #
countShort

Vector(Of Short).Count

field countDouble overload 2 #
countDouble
field countFloat overload 2 #
countFloat
field countInteger overload 2 #
countInteger
field countLong overload 2 #
countLong
field countShort overload 2 #
countShort