コード例 #1
0
        public void float4_normalizesafe_burst()
        {
            FunctionPointer <float4_normalizesafe.TestFunction> testFunction = BurstCompiler.CompileFunctionPointer <float4_normalizesafe.TestFunction>(float4_normalizesafe.BurstTestFunction);
            var args = new float4_normalizesafe.Arguments();

            args.Init();

            Measure.Method(() =>
            {
                testFunction.Invoke(ref args);
            })
            .Definition(sampleUnit: SampleUnit.Microsecond)
            .WarmupCount(1)
            .MeasurementCount(10)
            .Run();
            args.Dispose();
        }
コード例 #2
0
        public void float4_normalizesafe_mono()
        {
            float4_normalizesafe.TestFunction testFunction = float4_normalizesafe.MonoTestFunction;
            var args = new float4_normalizesafe.Arguments();

            args.Init();

            Measure.Method(() =>
            {
                testFunction.Invoke(ref args);
            })
            .Definition(sampleUnit: SampleUnit.Microsecond)
            .WarmupCount(1)
            .MeasurementCount(10)
            .Run();
            args.Dispose();
        }