mirror of
https://github.com/paboyle/Grid.git
synced 2024-11-09 23:45:36 +00:00
Merge branch 'develop' of https://github.com/paboyle/Grid into develop
This commit is contained in:
commit
477ebf24f4
@ -49,7 +49,7 @@ NAMESPACE_BEGIN(Grid);
|
||||
|
||||
typedef Lattice<SiteLink> LinkField;
|
||||
typedef Lattice<SiteField> Field;
|
||||
typedef Field ComplexField;
|
||||
typedef LinkField ComplexField;
|
||||
};
|
||||
|
||||
typedef QedGImpl<vComplex> QedGImplR;
|
||||
|
@ -27,6 +27,7 @@
|
||||
/* END LEGAL */
|
||||
extern "C" {
|
||||
#include <openssl/sha.h>
|
||||
#include <openssl/evp.h>
|
||||
}
|
||||
#ifdef USE_IPP
|
||||
#include "ipp.h"
|
||||
@ -70,10 +71,8 @@ public:
|
||||
static inline std::vector<unsigned char> sha256(const void *data,size_t bytes)
|
||||
{
|
||||
std::vector<unsigned char> hash(SHA256_DIGEST_LENGTH);
|
||||
SHA256_CTX sha256;
|
||||
SHA256_Init (&sha256);
|
||||
SHA256_Update(&sha256, data,bytes);
|
||||
SHA256_Final (&hash[0], &sha256);
|
||||
auto digest = EVP_get_digestbyname("SHA256");
|
||||
EVP_Digest(data, bytes, &hash[0], NULL, digest, NULL);
|
||||
return hash;
|
||||
}
|
||||
static inline std::vector<int> sha256_seeds(const std::string &s)
|
||||
|
@ -793,6 +793,7 @@ int main (int argc, char ** argv)
|
||||
}
|
||||
std::cout <<" OK ! "<<std::endl;
|
||||
|
||||
#ifdef USE_FP16
|
||||
// Double to Half
|
||||
std::cout << GridLogMessage<< "Double to half" ;
|
||||
precisionChange(&H[0],&D[0],Ndp);
|
||||
@ -822,6 +823,7 @@ int main (int argc, char ** argv)
|
||||
assert( tmp < 1.0e-3 );
|
||||
}
|
||||
std::cout <<" OK ! "<<std::endl;
|
||||
#endif
|
||||
|
||||
}
|
||||
Grid_finalize();
|
||||
|
Loading…
Reference in New Issue
Block a user