init: v1.0.0

This commit is contained in:
yaole
2026-05-27 23:03:00 +08:00
commit 8d97f750eb
466 changed files with 80067 additions and 0 deletions
+24
View File
@@ -0,0 +1,24 @@
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <time.h>
#include "gcl.h"
int main() {
int msgLen = 10*1024*1024;
char *msg = malloc(msgLen);
char digest[32];
clock_t start, end;
int count = 100;
start = clock();
for (int i = 0; i < count; i++) {
sm3(msg, msgLen, &digest);
}
end = clock();
printf("sm3: %.1fMBps\n", (double)count * msgLen/1024/1024/ ((double)(end - start) / CLOCKS_PER_SEC));
free(msg);
return 0;
}