Fixed core_func_integer test
This commit is contained in:
parent
d8d954fca0
commit
af10e20f68
@ -482,11 +482,10 @@ namespace bitfieldReverse
|
|||||||
return Error;
|
return Error;
|
||||||
}
|
}
|
||||||
|
|
||||||
int perf32()
|
int perf32(glm::uint32 Count)
|
||||||
{
|
{
|
||||||
int Error = 0;
|
int Error = 0;
|
||||||
|
|
||||||
glm::uint32 Count = 10000000;
|
|
||||||
std::vector<glm::uint32> Data;
|
std::vector<glm::uint32> Data;
|
||||||
Data.resize(static_cast<std::size_t>(Count));
|
Data.resize(static_cast<std::size_t>(Count));
|
||||||
|
|
||||||
@ -520,11 +519,10 @@ namespace bitfieldReverse
|
|||||||
return Error;
|
return Error;
|
||||||
}
|
}
|
||||||
|
|
||||||
int perf64()
|
int perf64(glm::uint64 Count)
|
||||||
{
|
{
|
||||||
int Error = 0;
|
int Error = 0;
|
||||||
|
|
||||||
glm::uint64 Count = 10000000;
|
|
||||||
std::vector<glm::uint64> Data;
|
std::vector<glm::uint64> Data;
|
||||||
Data.resize(static_cast<std::size_t>(Count));
|
Data.resize(static_cast<std::size_t>(Count));
|
||||||
|
|
||||||
@ -558,12 +556,12 @@ namespace bitfieldReverse
|
|||||||
return Error;
|
return Error;
|
||||||
}
|
}
|
||||||
|
|
||||||
int perf()
|
int perf(std::size_t Samples)
|
||||||
{
|
{
|
||||||
int Error = 0;
|
int Error = 0;
|
||||||
|
|
||||||
Error += perf32();
|
Error += perf32(Samples);
|
||||||
Error += perf64();
|
Error += perf64(Samples);
|
||||||
|
|
||||||
return Error;
|
return Error;
|
||||||
}
|
}
|
||||||
@ -1478,11 +1476,10 @@ namespace bitCount
|
|||||||
return bitCount_bitfield(glm::tvec1<genType, glm::defaultp>(x)).x;
|
return bitCount_bitfield(glm::tvec1<genType, glm::defaultp>(x)).x;
|
||||||
}
|
}
|
||||||
|
|
||||||
int perf()
|
int perf(std::size_t Size)
|
||||||
{
|
{
|
||||||
int Error(0);
|
int Error(0);
|
||||||
|
|
||||||
std::size_t Size = 10000000;
|
|
||||||
std::vector<int> v;
|
std::vector<int> v;
|
||||||
v.resize(Size);
|
v.resize(Size);
|
||||||
|
|
||||||
@ -1579,10 +1576,11 @@ int main()
|
|||||||
Error += ::bitfieldExtract::test();
|
Error += ::bitfieldExtract::test();
|
||||||
|
|
||||||
# ifdef NDEBUG
|
# ifdef NDEBUG
|
||||||
Error += ::bitCount::perf();
|
std::size_t const Samples = 1000;
|
||||||
Error += ::bitfieldReverse::perf();
|
::bitCount::perf(Samples);
|
||||||
Error += ::findMSB::perf();
|
::bitfieldReverse::perf(Samples);
|
||||||
Error += ::findLSB::perf();
|
::findMSB::perf();
|
||||||
|
::findLSB::perf();
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
return Error;
|
return Error;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user