Skip to content

Instantly share code, notes, and snippets.

View saidwho12's full-sized avatar

Saïd Metiche saidwho12

  • 08:10 (UTC -04:00)
View GitHub Profile
void CalcMultShift(uint64_t *mult, uint64_t *shift, uint64_t F2, uint64_t F1)
{
uint64_t m = 1, s;
uint64_t maxsft = __lzcnt64(F2);
printf("\nF1:%llu, F2:%llu\n\n", F1,F2);
for (s = 0; s < maxsft; ++s) {
uint64_t dividend = F2 << s;
uint64_t rem;
@saidwho12
saidwho12 / utf_decoder_test.c
Created July 19, 2021 02:20
UTF-8 SIMD tests
#include <stdio.h>
#include <stdlib.h>
#include <memory.h>
#include <inttypes.h>
#include <time.h>
#include <x86intrin.h>
#ifdef WIN32
#include <windows.h>