Added dotnet8.0 as a build target

This commit is contained in:
Martin Evans 2023-11-15 01:09:37 +00:00
parent 8a966171e1
commit e850115b5f
2 changed files with 3 additions and 3 deletions

View File

@ -1,6 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>netstandard2.0;net6.0;net7.0</TargetFrameworks>
<TargetFrameworks>netstandard2.0;net6.0;net7.0;net8.0</TargetFrameworks>
<RootNamespace>LLama</RootNamespace>
<Nullable>enable</Nullable>
<LangVersion>10</LangVersion>

View File

@ -137,7 +137,7 @@ namespace LLama.Native
AvxLevel.Avx => "avx",
AvxLevel.Avx2 => "avx2",
#if NET8_0_OR_GREATER
AvxLevel.Avx512 => "avx512"
AvxLevel.Avx512 => "avx512",
#endif
_ => throw new ArgumentException($"Unknown AvxLevel '{level}'")
};
@ -154,7 +154,7 @@ namespace LLama.Native
if (System.Runtime.Intrinsics.X86.Avx2.IsSupported)
_avxLevel = AvxLevel.Avx2;
#if NET8_0_OR_GREATER
if (System.Runtime.Intrinsics.X86.Avx512.IsSupported)
if (System.Runtime.Intrinsics.X86.Avx512F.IsSupported)
_avxLevel = AvxLevel.Avx512;
#endif
}