/* Generated by Nim Compiler v1.6.14 */
#define NIM_INTBITS 32

#include "nimbase.h"
#include <string.h>
#undef LANGUAGE_C
#undef MIPSEB
#undef MIPSEL
#undef PPC
#undef R3000
#undef R4000
#undef i386
#undef linux
#undef mips
#undef near
#undef far
#undef powerpc
#undef unix
#define nimfr_(x, y)
#define nimln_(x, y)
typedef struct tyObject_RodFile__fVxxWpdMqDQj2Vdv19aO6UQ tyObject_RodFile__fVxxWpdMqDQj2Vdv19aO6UQ;
typedef struct tyObject_BiTable__f1TRECC4Lgx6Suak6pB8oQ tyObject_BiTable__f1TRECC4Lgx6Suak6pB8oQ;
typedef struct tySequence__sM4lkSb7zS6F7OVMvW9cffQ tySequence__sM4lkSb7zS6F7OVMvW9cffQ;
typedef struct tySequence__9bAGqSvkAaFL9bWjsEPslrFA tySequence__9bAGqSvkAaFL9bWjsEPslrFA;
typedef struct tyObject_BiTable__YFXXoy9ajAIwHK4kQgVvjcw tyObject_BiTable__YFXXoy9ajAIwHK4kQgVvjcw;
typedef struct tySequence__IHUFRsFxZNv7YydiUO2esQ tySequence__IHUFRsFxZNv7YydiUO2esQ;
typedef struct NimStringDesc NimStringDesc;
typedef struct TGenericSeq TGenericSeq;
typedef struct TNimType TNimType;
typedef struct TNimNode TNimNode;
typedef struct tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g;
typedef struct tyObject_CellSeq__nav876ELHgxScHhs30CKiA tyObject_CellSeq__nav876ELHgxScHhs30CKiA;
typedef struct tyObject_GcHeap__ZRn9bWCksoiGwT2drZZzyWQ tyObject_GcHeap__ZRn9bWCksoiGwT2drZZzyWQ;
typedef struct tyObject_GcStack__qFeGMKlnq6c9cTM2vPWycQQ tyObject_GcStack__qFeGMKlnq6c9cTM2vPWycQQ;
typedef struct tyObject_MemRegion__6QRscFDo4mEwbg9aL76vDGQ tyObject_MemRegion__6QRscFDo4mEwbg9aL76vDGQ;
typedef struct tyObject_SmallChunk__eUrTKmsk1Dqt5tm2WUT2Lw tyObject_SmallChunk__eUrTKmsk1Dqt5tm2WUT2Lw;
typedef struct tyObject_BigChunk__39bC3HTk2w4NGDjG74oNjmA tyObject_BigChunk__39bC3HTk2w4NGDjG74oNjmA;
typedef struct tyObject_LLChunk__Fjkr5Ya6Zl0UoUGxG047hA tyObject_LLChunk__Fjkr5Ya6Zl0UoUGxG047hA;
typedef struct tyObject_IntSet__WrQriiGmHk59cB1lNPtGo6A tyObject_IntSet__WrQriiGmHk59cB1lNPtGo6A;
typedef struct tyObject_Trunk__Ju1AURWHenTn3cJwAjbUhg tyObject_Trunk__Ju1AURWHenTn3cJwAjbUhg;
typedef struct tyObject_AvlNode__aGkK1t9a0WoXjpugXR6FWpw tyObject_AvlNode__aGkK1t9a0WoXjpugXR6FWpw;
typedef struct tyObject_HeapLinks__5IkCDh5QlsYpsfEMJf6zNw tyObject_HeapLinks__5IkCDh5QlsYpsfEMJf6zNw;
typedef struct tyTuple__p2vAp9cQ6YrpDq9cI3XzEDWA tyTuple__p2vAp9cQ6YrpDq9cI3XzEDWA;
typedef struct tyObject_GcStat__OG9ams3mtFJyICkjTOHbc9bg tyObject_GcStat__OG9ams3mtFJyICkjTOHbc9bg;
typedef struct tyObject_CellSet__A0mJvGLunfUxGkLUtesjdA tyObject_CellSet__A0mJvGLunfUxGkLUtesjdA;
typedef struct tyObject_PageDesc__N7tjEodqPVJaQ6oKQW8YfQ tyObject_PageDesc__N7tjEodqPVJaQ6oKQW8YfQ;
struct tyObject_BiTable__f1TRECC4Lgx6Suak6pB8oQ {
tySequence__sM4lkSb7zS6F7OVMvW9cffQ* vals;
tySequence__9bAGqSvkAaFL9bWjsEPslrFA* keys;
};
struct tyObject_BiTable__YFXXoy9ajAIwHK4kQgVvjcw {
tySequence__IHUFRsFxZNv7YydiUO2esQ* vals;
tySequence__9bAGqSvkAaFL9bWjsEPslrFA* keys;
};
struct TGenericSeq {
NI len;
NI reserved;
};
struct NimStringDesc {
  TGenericSeq Sup;
NIM_CHAR data[SEQ_DECL_SIZE];
};
typedef NU8 tyEnum_TNimKind__pspQAsqJLrw3jEKBD9bxmyQ;
typedef NU8 tySet_tyEnum_TNimTypeFlag__Yt5hq6z2IoHhKZrzIVrc1w;
typedef N_NIMCALL_PTR(void, tyProc__ojoeKfW4VYIm36I9cpDTQIg) (void* p, NI op);
typedef N_NIMCALL_PTR(void*, tyProc__WSm2xU5ARYv9aAR4l0z9c9auQ) (void* p);
struct TNimType {
NI size;
NI align;
tyEnum_TNimKind__pspQAsqJLrw3jEKBD9bxmyQ kind;
tySet_tyEnum_TNimTypeFlag__Yt5hq6z2IoHhKZrzIVrc1w flags;
TNimType* base;
TNimNode* node;
void* finalizer;
tyProc__ojoeKfW4VYIm36I9cpDTQIg marker;
tyProc__WSm2xU5ARYv9aAR4l0z9c9auQ deepcopy;
};
typedef NU8 tyEnum_TNimNodeKind__rrp49bl1h9aEkXfXp9bNg0yZw;
struct TNimNode {
tyEnum_TNimNodeKind__rrp49bl1h9aEkXfXp9bNg0yZw kind;
NI offset;
TNimType* typ;
NCSTRING name;
NI len;
TNimNode** sons;
};
struct tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g {
NI refcount;
TNimType* typ;
};
struct tyObject_GcStack__qFeGMKlnq6c9cTM2vPWycQQ {
void* bottom;
};
struct tyObject_CellSeq__nav876ELHgxScHhs30CKiA {
NI len;
NI cap;
tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g** d;
};
typedef tyObject_SmallChunk__eUrTKmsk1Dqt5tm2WUT2Lw* tyArray__1eFxjkcKGHnofywkmCV8oQ[256];
typedef NU32 tyArray__BHbOSqU1t9b3Gt7K2c6fQig[24];
typedef tyObject_BigChunk__39bC3HTk2w4NGDjG74oNjmA* tyArray__KxTmKT9a3kTkdwYfqXhEYSw[32];
typedef tyArray__KxTmKT9a3kTkdwYfqXhEYSw tyArray__ATT5LBefmjy9bg8ApRmg3rw[24];
typedef tyObject_Trunk__Ju1AURWHenTn3cJwAjbUhg* tyArray__RxhBwkGQwTHLKhoK685Xfg[256];
struct tyObject_IntSet__WrQriiGmHk59cB1lNPtGo6A {
tyArray__RxhBwkGQwTHLKhoK685Xfg data;
};
typedef tyObject_AvlNode__aGkK1t9a0WoXjpugXR6FWpw* tyArray__DrxDrI9bg9apB70ydOoNZrWw[2];
struct tyObject_AvlNode__aGkK1t9a0WoXjpugXR6FWpw {
tyArray__DrxDrI9bg9apB70ydOoNZrWw link;
NI key;
NI upperBound;
NI level;
};
struct tyTuple__p2vAp9cQ6YrpDq9cI3XzEDWA {
tyObject_BigChunk__39bC3HTk2w4NGDjG74oNjmA* Field0;
NI Field1;
};
typedef tyTuple__p2vAp9cQ6YrpDq9cI3XzEDWA tyArray__wsokuoa9bVBSU4gPLKbFaaw[30];
struct tyObject_HeapLinks__5IkCDh5QlsYpsfEMJf6zNw {
NI len;
tyArray__wsokuoa9bVBSU4gPLKbFaaw chunks;
tyObject_HeapLinks__5IkCDh5QlsYpsfEMJf6zNw* next;
};
struct tyObject_MemRegion__6QRscFDo4mEwbg9aL76vDGQ {
NI minLargeObj;
NI maxLargeObj;
tyArray__1eFxjkcKGHnofywkmCV8oQ freeSmallChunks;
NU32 flBitmap;
tyArray__BHbOSqU1t9b3Gt7K2c6fQig slBitmap;
tyArray__ATT5LBefmjy9bg8ApRmg3rw matrix;
tyObject_LLChunk__Fjkr5Ya6Zl0UoUGxG047hA* llmem;
NI currMem;
NI maxMem;
NI freeMem;
NI occ;
NI lastSize;
tyObject_IntSet__WrQriiGmHk59cB1lNPtGo6A chunkStarts;
tyObject_AvlNode__aGkK1t9a0WoXjpugXR6FWpw* root;
tyObject_AvlNode__aGkK1t9a0WoXjpugXR6FWpw* deleted;
tyObject_AvlNode__aGkK1t9a0WoXjpugXR6FWpw* last;
tyObject_AvlNode__aGkK1t9a0WoXjpugXR6FWpw* freeAvlNodes;
NIM_BOOL locked;
NIM_BOOL blockChunkSizeIncrease;
NI nextChunkSize;
tyObject_AvlNode__aGkK1t9a0WoXjpugXR6FWpw bottomData;
tyObject_HeapLinks__5IkCDh5QlsYpsfEMJf6zNw heapLinks;
};
struct tyObject_GcStat__OG9ams3mtFJyICkjTOHbc9bg {
NI stackScans;
NI cycleCollections;
NI maxThreshold;
NI maxStackSize;
NI maxStackCells;
NI cycleTableSize;
NI64 maxPause;
};
struct tyObject_CellSet__A0mJvGLunfUxGkLUtesjdA {
NI counter;
NI max;
tyObject_PageDesc__N7tjEodqPVJaQ6oKQW8YfQ* head;
tyObject_PageDesc__N7tjEodqPVJaQ6oKQW8YfQ** data;
};
struct tyObject_GcHeap__ZRn9bWCksoiGwT2drZZzyWQ {
tyObject_GcStack__qFeGMKlnq6c9cTM2vPWycQQ stack;
NI cycleThreshold;
NI zctThreshold;
tyObject_CellSeq__nav876ELHgxScHhs30CKiA zct;
tyObject_CellSeq__nav876ELHgxScHhs30CKiA decStack;
tyObject_CellSeq__nav876ELHgxScHhs30CKiA tempStack;
NI recGcLock;
tyObject_MemRegion__6QRscFDo4mEwbg9aL76vDGQ region;
tyObject_GcStat__OG9ams3mtFJyICkjTOHbc9bg stat;
tyObject_CellSet__A0mJvGLunfUxGkLUtesjdA marked;
tyObject_CellSeq__nav876ELHgxScHhs30CKiA additionalRoots;
NI gcThreadId;
};
struct tySequence__9bAGqSvkAaFL9bWjsEPslrFA {
  TGenericSeq Sup;
  NU32 data[SEQ_DECL_SIZE];
};
struct tySequence__sM4lkSb7zS6F7OVMvW9cffQ {
  TGenericSeq Sup;
  NimStringDesc* data[SEQ_DECL_SIZE];
};
struct tySequence__IHUFRsFxZNv7YydiUO2esQ {
  TGenericSeq Sup;
  NI64 data[SEQ_DECL_SIZE];
};
N_LIB_PRIVATE N_NIMCALL(void, loadSeq__icZic_3226)(tyObject_RodFile__fVxxWpdMqDQj2Vdv19aO6UQ* f, tySequence__sM4lkSb7zS6F7OVMvW9cffQ** s);
N_LIB_PRIVATE N_NIMCALL(void, loadSeq__icZic_3245)(tyObject_RodFile__fVxxWpdMqDQj2Vdv19aO6UQ* f, tySequence__9bAGqSvkAaFL9bWjsEPslrFA** s);
N_LIB_PRIVATE N_NIMCALL(void, loadSeq__icZic_3357)(tyObject_RodFile__fVxxWpdMqDQj2Vdv19aO6UQ* f, tySequence__IHUFRsFxZNv7YydiUO2esQ** s);
N_LIB_PRIVATE N_NIMCALL(NI, hash__pureZhashes_279)(NimStringDesc* x);
static N_INLINE(NIM_BOOL, eqStrings)(NimStringDesc* a, NimStringDesc* b);
static N_INLINE(NIM_BOOL, equalMem__system_1741)(void* a, void* b, NI size);
static N_INLINE(int, nimCmpMem)(void* a, void* b, NI size);
static N_INLINE(NI, nextTry__icZbitabs_8)(NI h, NI maxHash);
static N_INLINE(NIM_BOOL, mustRehash__icZbitabs_44)(NI length, NI counter);
N_LIB_PRIVATE N_NIMCALL(void, enlarge__icZic_952)(tyObject_BiTable__f1TRECC4Lgx6Suak6pB8oQ* t);
N_LIB_PRIVATE N_NIMCALL(void*, newSeq)(TNimType* typ, NI len);
N_LIB_PRIVATE N_NIMCALL(void, unsureAsgnRef)(void** dest, void* src);
N_LIB_PRIVATE N_NIMCALL(TGenericSeq*, setLengthSeqV2)(TGenericSeq* s, TNimType* typ, NI newLen);
N_LIB_PRIVATE N_NIMCALL(TGenericSeq*, incrSeqV3)(TGenericSeq* s, TNimType* typ);
N_LIB_PRIVATE N_NIMCALL(NimStringDesc*, copyStringRC1)(NimStringDesc* src);
static N_INLINE(void, nimGCunrefNoCycle)(void* p);
static N_INLINE(void, decRef__system_5309)(tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g* c);
static N_INLINE(NI, minuspercent___system_716)(NI x, NI y);
static N_INLINE(NIM_BOOL, ltpercent___system_1005)(NI x, NI y);
static N_INLINE(void, rtlAddZCT__system_5307)(tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g* c);
N_LIB_PRIVATE N_NOINLINE(void, addZCT__system_5258)(tyObject_CellSeq__nav876ELHgxScHhs30CKiA* s, tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g* c);
static N_INLINE(tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g*, usrToCell__system_5264)(void* usr);
static N_INLINE(NI, hash__pureZjson_2974)(NI64 x);
static N_INLINE(NI, hashWangYi1__pureZhashes_136)(NU64 x);
static N_INLINE(NU64, hiXorLo__pureZhashes_79)(NU64 a, NU64 b);
static N_INLINE(NU64, hiXorLoFallback64__pureZhashes_35)(NU64 a, NU64 b);
N_LIB_PRIVATE N_NIMCALL(void, enlarge__icZic_2518)(tyObject_BiTable__YFXXoy9ajAIwHK4kQgVvjcw* t);
N_LIB_PRIVATE N_NIMCALL(void, storeSeq__icZic_4437)(tyObject_RodFile__fVxxWpdMqDQj2Vdv19aO6UQ* f, tySequence__sM4lkSb7zS6F7OVMvW9cffQ* s);
N_LIB_PRIVATE N_NIMCALL(void, storeSeq__icZic_4470)(tyObject_RodFile__fVxxWpdMqDQj2Vdv19aO6UQ* f, tySequence__9bAGqSvkAaFL9bWjsEPslrFA* s);
N_LIB_PRIVATE N_NIMCALL(void, storeSeq__icZic_4582)(tyObject_RodFile__fVxxWpdMqDQj2Vdv19aO6UQ* f, tySequence__IHUFRsFxZNv7YydiUO2esQ* s);
extern TNimType NTIseqLlitidT__9bAGqSvkAaFL9bWjsEPslrFA_;
extern TNimType NTIseqLstringT__sM4lkSb7zS6F7OVMvW9cffQ_;
extern TNimType NTIseqLbiggestintT__IHUFRsFxZNv7YydiUO2esQ_;
extern tyObject_GcHeap__ZRn9bWCksoiGwT2drZZzyWQ gch__system_5211;
N_LIB_PRIVATE N_NIMCALL(void, load__icZic_3222)(tyObject_RodFile__fVxxWpdMqDQj2Vdv19aO6UQ* f, tyObject_BiTable__f1TRECC4Lgx6Suak6pB8oQ* t) {
	loadSeq__icZic_3226(f, (&(*t).vals));
	loadSeq__icZic_3245(f, (&(*t).keys));
}
N_LIB_PRIVATE N_NIMCALL(void, load__icZic_3353)(tyObject_RodFile__fVxxWpdMqDQj2Vdv19aO6UQ* f, tyObject_BiTable__YFXXoy9ajAIwHK4kQgVvjcw* t) {
	loadSeq__icZic_3357(f, (&(*t).vals));
	loadSeq__icZic_3245(f, (&(*t).keys));
}
static N_INLINE(int, nimCmpMem)(void* a, void* b, NI size) {
	int result;
	result = (int)0;
	result = memcmp(a, b, ((size_t) (size)));
	return result;
}
static N_INLINE(NIM_BOOL, equalMem__system_1741)(void* a, void* b, NI size) {
	NIM_BOOL result;
	int T1_;
	result = (NIM_BOOL)0;
	T1_ = (int)0;
	T1_ = nimCmpMem(a, b, size);
	result = (T1_ == ((NI32) 0));
	return result;
}
static N_INLINE(NIM_BOOL, eqStrings)(NimStringDesc* a, NimStringDesc* b) {
	NIM_BOOL result;
	NI alen;
	NI blen;
{	result = (NIM_BOOL)0;
	alen = (a ? a->Sup.len : 0);
	blen = (b ? b->Sup.len : 0);
	{
		if (!(alen == blen)) goto LA3_;
		{
			if (!(alen == ((NI) 0))) goto LA7_;
			result = NIM_TRUE;
			goto BeforeRet_;
		}
		LA7_: ;
		result = equalMem__system_1741(((void*) ((&a->data[((NI) 0)]))), ((void*) ((&b->data[((NI) 0)]))), ((NI) (alen)));
		goto BeforeRet_;
	}
	LA3_: ;
	}BeforeRet_: ;
	return result;
}
static N_INLINE(NI, nextTry__icZbitabs_8)(NI h, NI maxHash) {
	NI result;
	result = (NI)0;
	result = (NI)((NI)(h + ((NI) 1)) & maxHash);
	return result;
}
static N_INLINE(NIM_BOOL, mustRehash__icZbitabs_44)(NI length, NI counter) {
	NIM_BOOL result;
	NIM_BOOL T1_;
	result = (NIM_BOOL)0;
	T1_ = (NIM_BOOL)0;
	T1_ = ((NI)(length * ((NI) 2)) < (NI)(counter * ((NI) 3)));
	if (T1_) goto LA2_;
	T1_ = ((NI)(length - counter) < ((NI) 4));
	LA2_: ;
	result = T1_;
	return result;
}
N_LIB_PRIVATE N_NIMCALL(void, enlarge__icZic_952)(tyObject_BiTable__f1TRECC4Lgx6Suak6pB8oQ* t) {
	tySequence__9bAGqSvkAaFL9bWjsEPslrFA* n;
	NI T1_;
	tySequence__9bAGqSvkAaFL9bWjsEPslrFA* T2_;
	n = NIM_NIL;
	T1_ = ((*t).keys ? (*t).keys->Sup.len : 0);
	n = (tySequence__9bAGqSvkAaFL9bWjsEPslrFA*) newSeq((&NTIseqLlitidT__9bAGqSvkAaFL9bWjsEPslrFA_), ((NI) ((NI)(T1_ * ((NI) 2)))));
	T2_ = NIM_NIL;
	T2_ = (*t).keys;
	unsureAsgnRef((void**) (&(*t).keys), n);
	n = T2_;
	{
		NI i;
		NI colontmp_;
		NI T4_;
		NI res;
		i = (NI)0;
		colontmp_ = (NI)0;
		T4_ = ((n ? n->Sup.len : 0)-1);
		colontmp_ = T4_;
		res = ((NI) 0);
		{
			while (1) {
				NU32 eh;
				if (!(res <= colontmp_)) goto LA6;
				i = res;
				eh = n->data[i];
				{
					NI j;
					NI T11_;
					NI T12_;
					if (!((NU32)(((NU32) 0)) < (NU32)(eh))) goto LA9_;
					T11_ = (NI)0;
					T11_ = hash__pureZhashes_279((*t).vals->data[(NI)(((NI) (eh)) - ((NI) 256))]);
					T12_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
					j = (NI)(T11_ & T12_);
					{
						while (1) {
							NI T15_;
							if (!((NU32)(((NU32) 0)) < (NU32)((*t).keys->data[j]))) goto LA14;
							T15_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
							j = nextTry__icZbitabs_8(j, T15_);
						} LA14: ;
					}
					(*t).keys->data[j] = n->data[i];
					n->data[i] = 0;
				}
				LA9_: ;
				res += ((NI) 1);
			} LA6: ;
		}
	}
}
static N_INLINE(NI, minuspercent___system_716)(NI x, NI y) {
	NI result;
	result = (NI)0;
	result = ((NI) ((NU)((NU32)(((NU) (x))) - (NU32)(((NU) (y))))));
	return result;
}
static N_INLINE(NIM_BOOL, ltpercent___system_1005)(NI x, NI y) {
	NIM_BOOL result;
	result = (NIM_BOOL)0;
	result = ((NU32)(((NU) (x))) < (NU32)(((NU) (y))));
	return result;
}
static N_INLINE(void, rtlAddZCT__system_5307)(tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g* c) {
	addZCT__system_5258((&gch__system_5211.zct), c);
}
static N_INLINE(void, decRef__system_5309)(tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g* c) {
	(*c).refcount = minuspercent___system_716((*c).refcount, ((NI) 8));
	{
		NIM_BOOL T3_;
		T3_ = (NIM_BOOL)0;
		T3_ = ltpercent___system_1005((*c).refcount, ((NI) 8));
		if (!T3_) goto LA4_;
		rtlAddZCT__system_5307(c);
	}
	LA4_: ;
}
static N_INLINE(tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g*, usrToCell__system_5264)(void* usr) {
	tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g* result;
	NI T1_;
	result = (tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g*)0;
	T1_ = (NI)0;
	T1_ = minuspercent___system_716(((NI) (ptrdiff_t) (usr)), ((NI) 8));
	result = ((tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g*) (T1_));
	return result;
}
static N_INLINE(void, nimGCunrefNoCycle)(void* p) {
	tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g* T1_;
	T1_ = (tyObject_Cell__nhn83Yf9cX7rcmG5W9b4oa6g*)0;
	T1_ = usrToCell__system_5264(p);
	decRef__system_5309(T1_);
}
N_LIB_PRIVATE N_NIMCALL(NU32, getOrIncl__icZic_926)(tyObject_BiTable__f1TRECC4Lgx6Suak6pB8oQ* t, NimStringDesc* v) {
	NU32 result;
	NI origH;
	NI h;
	NI T1_;
	NI T35_;
	NI T36_;
	NimStringDesc* T37_;
{	result = (NU32)0;
	origH = hash__pureZhashes_279(v);
	T1_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
	h = (NI)(origH & T1_);
	{
		NI T4_;
		T4_ = ((*t).keys ? (*t).keys->Sup.len : 0);
		if (!!((T4_ == ((NI) 0)))) goto LA5_;
		{
			while (1) {
				NU32 litId;
				NI T17_;
				litId = (*t).keys->data[h];
				{
					if (!!(((NU32)(((NU32) 0)) < (NU32)(litId)))) goto LA11_;
					goto LA7;
				}
				LA11_: ;
				{
					if (!eqStrings((*t).vals->data[(NI)(((NI) ((*t).keys->data[h])) - ((NI) 256))], v)) goto LA15_;
					result = litId;
					goto BeforeRet_;
				}
				LA15_: ;
				T17_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
				h = nextTry__icZbitabs_8(h, T17_);
			}
		} LA7: ;
		{
			NI T20_;
			NI T21_;
			NIM_BOOL T22_;
			NI T25_;
			T20_ = ((*t).keys ? (*t).keys->Sup.len : 0);
			T21_ = ((*t).vals ? (*t).vals->Sup.len : 0);
			T22_ = (NIM_BOOL)0;
			T22_ = mustRehash__icZbitabs_44(T20_, T21_);
			if (!T22_) goto LA23_;
			enlarge__icZic_952(t);
			T25_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
			h = (NI)(origH & T25_);
			{
				while (1) {
					NU32 litId_2;
					NI T32_;
					litId_2 = (*t).keys->data[h];
					{
						if (!!(((NU32)(((NU32) 0)) < (NU32)(litId_2)))) goto LA30_;
						goto LA26;
					}
					LA30_: ;
					T32_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
					h = nextTry__icZbitabs_8(h, T32_);
				}
			} LA26: ;
		}
		LA23_: ;
	}
	goto LA2_;
	LA5_: ;
	{
		NI T34_;
		unsureAsgnRef((void**) (&(*t).keys), (tySequence__9bAGqSvkAaFL9bWjsEPslrFA*) setLengthSeqV2(((*t).keys)?&((*t).keys)->Sup:NIM_NIL, (&NTIseqLlitidT__9bAGqSvkAaFL9bWjsEPslrFA_), ((NI) 16)));
		T34_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
		h = (NI)(origH & T34_);
	}
	LA2_: ;
	T35_ = ((*t).vals ? (*t).vals->Sup.len : 0);
	result = ((NU32) ((NI)(T35_ + ((NI) 256))));
	(*t).keys->data[h] = result;
	unsureAsgnRef((void**) (&(*t).vals), (tySequence__sM4lkSb7zS6F7OVMvW9cffQ*) incrSeqV3((TGenericSeq*)((*t).vals), (&NTIseqLstringT__sM4lkSb7zS6F7OVMvW9cffQ_)));
	T36_ = (*t).vals->Sup.len++;
	T37_ = NIM_NIL;
	T37_ = (*t).vals->data[T36_]; (*t).vals->data[T36_] = copyStringRC1(v);
	if (T37_) nimGCunrefNoCycle(T37_);
	}BeforeRet_: ;
	return result;
}
static N_INLINE(NU64, hiXorLoFallback64__pureZhashes_35)(NU64 a, NU64 b) {
	NU64 result;
	NU64 aH;
	NU64 aL;
	NU64 bH;
	NU64 bL;
	NU64 rHH;
	NU64 rHL;
	NU64 rLH;
	NU64 rLL;
	NU64 t;
	NU64 c;
	NU64 lo;
	NU64 T6_;
	NU64 hi;
{	result = (NU64)0;
	aH = (NU64)((NU64)(a) >> (NU64)(((NI) 32)));
	aL = (NU64)(a & 4294967295ULL);
	bH = (NU64)((NU64)(b) >> (NU64)(((NI) 32)));
	bL = (NU64)(b & 4294967295ULL);
	rHH = (NU64)((NU64)(aH) * (NU64)(bH));
	rHL = (NU64)((NU64)(aH) * (NU64)(bL));
	rLH = (NU64)((NU64)(aL) * (NU64)(bH));
	rLL = (NU64)((NU64)(aL) * (NU64)(bL));
	t = (NU64)((NU64)(rLL) + (NU64)((NU64)((NU64)(rHL) << (NU64)(((NI) 32)))));
	{
		if (!((NU64)(t) < (NU64)(rLL))) goto LA3_;
		c = 1ULL;
	}
	goto LA1_;
	LA3_: ;
	{
		c = 0ULL;
	}
	LA1_: ;
	lo = (NU64)((NU64)(t) + (NU64)((NU64)((NU64)(rLH) << (NU64)(((NI) 32)))));
	T6_ = (NU64)0;
	{
		if (!((NU64)(lo) < (NU64)(t))) goto LA9_;
		T6_ = 1ULL;
	}
	goto LA7_;
	LA9_: ;
	{
		T6_ = 0ULL;
	}
	LA7_: ;
	c += T6_;
	hi = (NU64)((NU64)((NU64)((NU64)((NU64)((NU64)(rHH) + (NU64)((NU64)((NU64)(rHL) >> (NU64)(((NI) 32)))))) + (NU64)((NU64)((NU64)(rLH) >> (NU64)(((NI) 32)))))) + (NU64)(c));
	result = (NU64)(hi ^ lo);
	goto BeforeRet_;
	}BeforeRet_: ;
	return result;
}
static N_INLINE(NU64, hiXorLo__pureZhashes_79)(NU64 a, NU64 b) {
	NU64 result;
	result = (NU64)0;
	result = hiXorLoFallback64__pureZhashes_35(a, b);
	return result;
}
static N_INLINE(NI, hashWangYi1__pureZhashes_136)(NU64 x) {
	NI result;
	NU64 T1_;
	NU64 T2_;
	result = (NI)0;
	T1_ = (NU64)0;
	T1_ = hiXorLo__pureZhashes_79(11562461410679940143ULL, (NU64)(x ^ 16646288086500911323ULL));
	T2_ = (NU64)0;
	T2_ = hiXorLo__pureZhashes_79(T1_, 16952864883938283885ULL);
	result = ((NI) (T2_));
	return result;
}
static N_INLINE(NI, hash__pureZjson_2974)(NI64 x) {
	NI result;
	result = (NI)0;
	result = hashWangYi1__pureZhashes_136(((NU64) (x)));
	return result;
}
N_LIB_PRIVATE N_NIMCALL(void, enlarge__icZic_2518)(tyObject_BiTable__YFXXoy9ajAIwHK4kQgVvjcw* t) {
	tySequence__9bAGqSvkAaFL9bWjsEPslrFA* n;
	NI T1_;
	tySequence__9bAGqSvkAaFL9bWjsEPslrFA* T2_;
	n = NIM_NIL;
	T1_ = ((*t).keys ? (*t).keys->Sup.len : 0);
	n = (tySequence__9bAGqSvkAaFL9bWjsEPslrFA*) newSeq((&NTIseqLlitidT__9bAGqSvkAaFL9bWjsEPslrFA_), ((NI) ((NI)(T1_ * ((NI) 2)))));
	T2_ = NIM_NIL;
	T2_ = (*t).keys;
	unsureAsgnRef((void**) (&(*t).keys), n);
	n = T2_;
	{
		NI i;
		NI colontmp_;
		NI T4_;
		NI res;
		i = (NI)0;
		colontmp_ = (NI)0;
		T4_ = ((n ? n->Sup.len : 0)-1);
		colontmp_ = T4_;
		res = ((NI) 0);
		{
			while (1) {
				NU32 eh;
				if (!(res <= colontmp_)) goto LA6;
				i = res;
				eh = n->data[i];
				{
					NI j;
					NI T11_;
					NI T12_;
					if (!((NU32)(((NU32) 0)) < (NU32)(eh))) goto LA9_;
					T11_ = (NI)0;
					T11_ = hash__pureZjson_2974((*t).vals->data[(NI)(((NI) (eh)) - ((NI) 256))]);
					T12_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
					j = (NI)(T11_ & T12_);
					{
						while (1) {
							NI T15_;
							if (!((NU32)(((NU32) 0)) < (NU32)((*t).keys->data[j]))) goto LA14;
							T15_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
							j = nextTry__icZbitabs_8(j, T15_);
						} LA14: ;
					}
					(*t).keys->data[j] = n->data[i];
					n->data[i] = 0;
				}
				LA9_: ;
				res += ((NI) 1);
			} LA6: ;
		}
	}
}
N_LIB_PRIVATE N_NIMCALL(NU32, getOrIncl__icZic_2490)(tyObject_BiTable__YFXXoy9ajAIwHK4kQgVvjcw* t, NI64 v) {
	NU32 result;
	NI origH;
	NI h;
	NI T1_;
	NI T35_;
	NI T36_;
{	result = (NU32)0;
	origH = hash__pureZjson_2974(v);
	T1_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
	h = (NI)(origH & T1_);
	{
		NI T4_;
		T4_ = ((*t).keys ? (*t).keys->Sup.len : 0);
		if (!!((T4_ == ((NI) 0)))) goto LA5_;
		{
			while (1) {
				NU32 litId;
				NI T17_;
				litId = (*t).keys->data[h];
				{
					if (!!(((NU32)(((NU32) 0)) < (NU32)(litId)))) goto LA11_;
					goto LA7;
				}
				LA11_: ;
				{
					if (!((*t).vals->data[(NI)(((NI) ((*t).keys->data[h])) - ((NI) 256))] == v)) goto LA15_;
					result = litId;
					goto BeforeRet_;
				}
				LA15_: ;
				T17_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
				h = nextTry__icZbitabs_8(h, T17_);
			}
		} LA7: ;
		{
			NI T20_;
			NI T21_;
			NIM_BOOL T22_;
			NI T25_;
			T20_ = ((*t).keys ? (*t).keys->Sup.len : 0);
			T21_ = ((*t).vals ? (*t).vals->Sup.len : 0);
			T22_ = (NIM_BOOL)0;
			T22_ = mustRehash__icZbitabs_44(T20_, T21_);
			if (!T22_) goto LA23_;
			enlarge__icZic_2518(t);
			T25_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
			h = (NI)(origH & T25_);
			{
				while (1) {
					NU32 litId_2;
					NI T32_;
					litId_2 = (*t).keys->data[h];
					{
						if (!!(((NU32)(((NU32) 0)) < (NU32)(litId_2)))) goto LA30_;
						goto LA26;
					}
					LA30_: ;
					T32_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
					h = nextTry__icZbitabs_8(h, T32_);
				}
			} LA26: ;
		}
		LA23_: ;
	}
	goto LA2_;
	LA5_: ;
	{
		NI T34_;
		unsureAsgnRef((void**) (&(*t).keys), (tySequence__9bAGqSvkAaFL9bWjsEPslrFA*) setLengthSeqV2(((*t).keys)?&((*t).keys)->Sup:NIM_NIL, (&NTIseqLlitidT__9bAGqSvkAaFL9bWjsEPslrFA_), ((NI) 16)));
		T34_ = (((*t).keys ? (*t).keys->Sup.len : 0)-1);
		h = (NI)(origH & T34_);
	}
	LA2_: ;
	T35_ = ((*t).vals ? (*t).vals->Sup.len : 0);
	result = ((NU32) ((NI)(T35_ + ((NI) 256))));
	(*t).keys->data[h] = result;
	unsureAsgnRef((void**) (&(*t).vals), (tySequence__IHUFRsFxZNv7YydiUO2esQ*) incrSeqV3((TGenericSeq*)((*t).vals), (&NTIseqLbiggestintT__IHUFRsFxZNv7YydiUO2esQ_)));
	T36_ = (*t).vals->Sup.len++;
	(*t).vals->data[T36_] = v;
	}BeforeRet_: ;
	return result;
}
N_LIB_PRIVATE N_NIMCALL(void, store__icZic_4433)(tyObject_RodFile__fVxxWpdMqDQj2Vdv19aO6UQ* f, tyObject_BiTable__f1TRECC4Lgx6Suak6pB8oQ t) {
	storeSeq__icZic_4437(f, t.vals);
	storeSeq__icZic_4470(f, t.keys);
}
N_LIB_PRIVATE N_NIMCALL(void, store__icZic_4578)(tyObject_RodFile__fVxxWpdMqDQj2Vdv19aO6UQ* f, tyObject_BiTable__YFXXoy9ajAIwHK4kQgVvjcw t) {
	storeSeq__icZic_4582(f, t.vals);
	storeSeq__icZic_4470(f, t.keys);
}
N_LIB_PRIVATE N_NIMCALL(NU32, getKeyId__icZnavigator_327)(tyObject_BiTable__f1TRECC4Lgx6Suak6pB8oQ t, NimStringDesc* v) {
	NU32 result;
	NI origH;
	NI h;
	NI T1_;
{	result = (NU32)0;
	origH = hash__pureZhashes_279(v);
	T1_ = ((t.keys ? t.keys->Sup.len : 0)-1);
	h = (NI)(origH & T1_);
	{
		NI T4_;
		T4_ = (t.keys ? t.keys->Sup.len : 0);
		if (!!((T4_ == ((NI) 0)))) goto LA5_;
		{
			while (1) {
				NU32 litId;
				NI T17_;
				litId = t.keys->data[h];
				{
					if (!!(((NU32)(((NU32) 0)) < (NU32)(litId)))) goto LA11_;
					goto LA7;
				}
				LA11_: ;
				{
					if (!eqStrings(t.vals->data[(NI)(((NI) (t.keys->data[h])) - ((NI) 256))], v)) goto LA15_;
					result = litId;
					goto BeforeRet_;
				}
				LA15_: ;
				T17_ = ((t.keys ? t.keys->Sup.len : 0)-1);
				h = nextTry__icZbitabs_8(h, T17_);
			}
		} LA7: ;
	}
	LA5_: ;
	result = ((NU32) 0);
	goto BeforeRet_;
	}BeforeRet_: ;
	return result;
}
N_LIB_PRIVATE N_NIMCALL(NI, len__icZic_9616)(tyObject_BiTable__f1TRECC4Lgx6Suak6pB8oQ t) {
	NI result;
	NI T1_;
	result = (NI)0;
	T1_ = (t.vals ? t.vals->Sup.len : 0);
	result = T1_;
	return result;
}
N_LIB_PRIVATE N_NIMCALL(NI, len__icZic_9669)(tyObject_BiTable__YFXXoy9ajAIwHK4kQgVvjcw t) {
	NI result;
	NI T1_;
	result = (NI)0;
	T1_ = (t.vals ? t.vals->Sup.len : 0);
	result = T1_;
	return result;
}
