예제 #1
0
        public void RunStructLclFldScenario()
        {
            TestLibrary.TestFramework.BeginScenario(nameof(RunStructLclFldScenario));

            var test   = TestStruct.Create();
            var result = AdvSimd.ConvertToSingle(test._fld1);

            Unsafe.Write(_dataTable.outArrayPtr, result);
            ValidateResult(test._fld1, _dataTable.outArrayPtr);
        }
예제 #2
0
        public void RunClassLclFldScenario()
        {
            TestLibrary.TestFramework.BeginScenario(nameof(RunClassLclFldScenario));

            var test   = new SimpleUnaryOpTest__ConvertToSingle_Vector128_Int32();
            var result = AdvSimd.ConvertToSingle(test._fld1);

            Unsafe.Write(_dataTable.outArrayPtr, result);
            ValidateResult(test._fld1, _dataTable.outArrayPtr);
        }
예제 #3
0
        public void RunLclVarScenario_Load()
        {
            TestLibrary.TestFramework.BeginScenario(nameof(RunLclVarScenario_Load));

            var op1    = AdvSimd.LoadVector128((Int32 *)(_dataTable.inArray1Ptr));
            var result = AdvSimd.ConvertToSingle(op1);

            Unsafe.Write(_dataTable.outArrayPtr, result);
            ValidateResult(op1, _dataTable.outArrayPtr);
        }
        public void RunClsVarScenario()
        {
            TestLibrary.TestFramework.BeginScenario(nameof(RunClsVarScenario));

            var result = AdvSimd.ConvertToSingle(
                _clsVar1
                );

            Unsafe.Write(_dataTable.outArrayPtr, result);
            ValidateResult(_clsVar1, _dataTable.outArrayPtr);
        }
        public void RunBasicScenario_UnsafeRead()
        {
            TestLibrary.TestFramework.BeginScenario(nameof(RunBasicScenario_UnsafeRead));

            var result = AdvSimd.ConvertToSingle(
                Unsafe.Read <Vector128 <Int32> >(_dataTable.inArray1Ptr)
                );

            Unsafe.Write(_dataTable.outArrayPtr, result);
            ValidateResult(_dataTable.inArray1Ptr, _dataTable.outArrayPtr);
        }
            public void RunStructFldScenario_Load(SimpleUnaryOpTest__ConvertToSingle_Vector128_Int32 testClass)
            {
                fixed(Vector128 <Int32> *pFld1 = &_fld1)
                {
                    var result = AdvSimd.ConvertToSingle(
                        AdvSimd.LoadVector128((Int32 *)(pFld1))
                        );

                    Unsafe.Write(testClass._dataTable.outArrayPtr, result);
                    testClass.ValidateResult(_fld1, testClass._dataTable.outArrayPtr);
                }
            }
        public void RunClassFldScenario_Load()
        {
            TestLibrary.TestFramework.BeginScenario(nameof(RunClassFldScenario_Load));

            fixed(Vector128 <Int32> *pFld1 = &_fld1)
            {
                var result = AdvSimd.ConvertToSingle(
                    AdvSimd.LoadVector128((Int32 *)(pFld1))
                    );

                Unsafe.Write(_dataTable.outArrayPtr, result);
                ValidateResult(_fld1, _dataTable.outArrayPtr);
            }
        }
        public void RunClsVarScenario_Load()
        {
            TestLibrary.TestFramework.BeginScenario(nameof(RunClsVarScenario_Load));

            fixed(Vector64 <UInt32> *pClsVar1 = &_clsVar1)
            {
                var result = AdvSimd.ConvertToSingle(
                    AdvSimd.LoadVector64((UInt32 *)(pClsVar1))
                    );

                Unsafe.Write(_dataTable.outArrayPtr, result);
                ValidateResult(_clsVar1, _dataTable.outArrayPtr);
            }
        }
        public void RunClassLclFldScenario_Load()
        {
            TestLibrary.TestFramework.BeginScenario(nameof(RunClassLclFldScenario_Load));

            var test = new SimpleUnaryOpTest__ConvertToSingle_Vector64_Int32();

            fixed(Vector64 <Int32> *pFld1 = &test._fld1)
            {
                var result = AdvSimd.ConvertToSingle(
                    AdvSimd.LoadVector64((Int32 *)(pFld1))
                    );

                Unsafe.Write(_dataTable.outArrayPtr, result);
                ValidateResult(test._fld1, _dataTable.outArrayPtr);
            }
        }