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

            args.Init();

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

            args.Init();

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