diff --git a/NuGetTest/Hast.NuGet.Console/Program.cs b/NuGetTest/Hast.NuGet.Console/Program.cs index f2448ecc..9994cae0 100644 --- a/NuGetTest/Hast.NuGet.Console/Program.cs +++ b/NuGetTest/Hast.NuGet.Console/Program.cs @@ -15,7 +15,7 @@ // To cross-compile, first run without any arguments (this will throw an exception during execution), then copy the // HardwareFramework directory to the remote device and pass the binary's path as the argument, e.g.: // dotnet Hast.NuGet.Console.dll HardwareFramework/bin/*.azure.xclbin -var binaryPath = Environment.GetCommandLineArgs().FirstOrDefault(item => item.EndsWithOrdinalIgnoreCase(".xclbin")); +var binaryPath = Environment.GetCommandLineArgs().Find(item => item.EndsWithOrdinalIgnoreCase(".xclbin")); if (File.Exists(binaryPath)) { configuration.SingleBinaryPath = binaryPath; diff --git a/src/Samples/Hast.Samples.SampleAssembly/PrimeCalculator.cs b/src/Samples/Hast.Samples.SampleAssembly/PrimeCalculator.cs index 58b4ec12..52c6a92d 100644 --- a/src/Samples/Hast.Samples.SampleAssembly/PrimeCalculator.cs +++ b/src/Samples/Hast.Samples.SampleAssembly/PrimeCalculator.cs @@ -192,10 +192,10 @@ public bool IsPrimeNumberSync(uint number, IHastlayer hastlayer = null, IHardwar RunIsPrimeNumberAsync(number, memory => Task.Run(() => IsPrimeNumberSync(memory)), hastlayer, configuration).Result; public Task IsPrimeNumberAsync(uint number, IHastlayer hastlayer = null, IHardwareGenerationConfiguration configuration = null) => - RunIsPrimeNumberAsync(number, memory => IsPrimeNumberAsync(memory), hastlayer, configuration); + RunIsPrimeNumberAsync(number, IsPrimeNumberAsync, hastlayer, configuration); public bool[] ArePrimeNumbers(uint[] numbers, IHastlayer hastlayer = null, IHardwareGenerationConfiguration configuration = null) => - RunArePrimeNumbersMethod(numbers, memory => ArePrimeNumbers(memory), hastlayer, configuration); + RunArePrimeNumbersMethod(numbers, ArePrimeNumbers, hastlayer, configuration); public bool[] ParallelizedArePrimeNumbers(uint[] numbers, IHastlayer hastlayer = null, IHardwareGenerationConfiguration configuration = null) { diff --git a/src/Samples/Hast.Samples.SampleAssembly/SimdCalculator.cs b/src/Samples/Hast.Samples.SampleAssembly/SimdCalculator.cs index 4185cb73..e5863abc 100644 --- a/src/Samples/Hast.Samples.SampleAssembly/SimdCalculator.cs +++ b/src/Samples/Hast.Samples.SampleAssembly/SimdCalculator.cs @@ -115,28 +115,28 @@ private void RunSimdOperation(SimpleMemory memory, SimdOperation operation) #region Helpers public int[] AddVectors(int[] vector1, int[] vector2, IHastlayer hastlayer = null, IHardwareGenerationConfiguration configuration = null) => - RunSimdOperation(vector1, vector2, memory => AddVectors(memory), hastlayer, configuration); + RunSimdOperation(vector1, vector2, AddVectors, hastlayer, configuration); public int[] SubtractVectors( int[] vector1, int[] vector2, IHastlayer hastlayer = null, IHardwareGenerationConfiguration configuration = null) => - RunSimdOperation(vector1, vector2, memory => SubtractVectors(memory), hastlayer, configuration); + RunSimdOperation(vector1, vector2, SubtractVectors, hastlayer, configuration); public int[] MultiplyVectors( int[] vector1, int[] vector2, IHastlayer hastlayer = null, IHardwareGenerationConfiguration configuration = null) => - RunSimdOperation(vector1, vector2, memory => MultiplyVectors(memory), hastlayer, configuration); + RunSimdOperation(vector1, vector2, MultiplyVectors, hastlayer, configuration); public int[] DivideVectors( int[] vector1, int[] vector2, IHastlayer hastlayer = null, IHardwareGenerationConfiguration configuration = null) => - RunSimdOperation(vector1, vector2, memory => DivideVectors(memory), hastlayer, configuration); + RunSimdOperation(vector1, vector2, DivideVectors, hastlayer, configuration); private int[] RunSimdOperation( int[] vector1,