/* Generated by Nim Compiler v0.10.2 */
/*   (c) 2014 Andreas Rumpf */
/* The generated code is subject to the original license. */
#define NIM_INTBITS 64
#include "nimbase.h"

#include <string.h>
typedef struct tsym225846 tsym225846;
typedef struct NimStringDesc NimStringDesc;
typedef struct TGenericSeq TGenericSeq;
typedef struct tcell44935 tcell44935;
typedef struct TNimType TNimType;
typedef struct tcellseq44951 tcellseq44951;
typedef struct tgcheap47016 tgcheap47016;
typedef struct tcellset44947 tcellset44947;
typedef struct tpagedesc44943 tpagedesc44943;
typedef struct tmemregion27210 tmemregion27210;
typedef struct tsmallchunk26440 tsmallchunk26440;
typedef struct tllchunk27204 tllchunk27204;
typedef struct tbigchunk26442 tbigchunk26442;
typedef struct tintset26417 tintset26417;
typedef struct ttrunk26413 ttrunk26413;
typedef struct tavlnode27208 tavlnode27208;
typedef struct tgcstat47014 tgcstat47014;
typedef struct tnode225816 tnode225816;
typedef struct analysisctx483026 analysisctx483026;
typedef struct TY483036 TY483036;
typedef struct monotonicvar483024 monotonicvar483024;
typedef struct TY483038 TY483038;
typedef struct TY483039 TY483039;
typedef struct tnodeseq225810 tnodeseq225810;
typedef struct tsymseq225818 tsymseq225818;
typedef struct TNimNode TNimNode;
typedef struct ttype225852 ttype225852;
typedef struct tlineinfo195539 tlineinfo195539;
typedef struct tident200021 tident200021;
typedef struct tidobj200015 tidobj200015;
typedef struct TNimObject TNimObject;
typedef struct ttypeseq225848 ttypeseq225848;
typedef struct tscope225840 tscope225840;
typedef struct TY225947 TY225947;
typedef struct tinstantiation225836 tinstantiation225836;
typedef struct tstrtable225820 tstrtable225820;
typedef struct tloc225830 tloc225830;
typedef struct trope177009 trope177009;
typedef struct tlib225834 tlib225834;
typedef struct tbasechunk26438 tbasechunk26438;
typedef struct tfreecell26430 tfreecell26430;
typedef struct TY225936 TY225936;
typedef struct tlistentry127022 tlistentry127022;
struct  TGenericSeq  {
NI len;
NI reserved;
};
struct  NimStringDesc  {
  TGenericSeq Sup;
NIM_CHAR data[SEQ_DECL_SIZE];
};
struct  tcell44935  {
NI Refcount;
TNimType* Typ;
};
struct  tcellseq44951  {
NI Len;
NI Cap;
tcell44935** D;
};
struct  tcellset44947  {
NI Counter;
NI Max;
tpagedesc44943* Head;
tpagedesc44943** Data;
};
typedef tsmallchunk26440* TY27222[512];
typedef ttrunk26413* ttrunkbuckets26415[256];
struct  tintset26417  {
ttrunkbuckets26415 Data;
};
struct  tmemregion27210  {
NI Minlargeobj;
NI Maxlargeobj;
TY27222 Freesmallchunks;
tllchunk27204* Llmem;
NI Currmem;
NI Maxmem;
NI Freemem;
NI Lastsize;
tbigchunk26442* Freechunkslist;
tintset26417 Chunkstarts;
tavlnode27208* Root;
tavlnode27208* Deleted;
tavlnode27208* Last;
tavlnode27208* Freeavlnodes;
};
struct  tgcstat47014  {
NI Stackscans;
NI Cyclecollections;
NI Maxthreshold;
NI Maxstacksize;
NI Maxstackcells;
NI Cycletablesize;
NI64 Maxpause;
};
struct  tgcheap47016  {
void* Stackbottom;
NI Cyclethreshold;
tcellseq44951 Zct;
tcellseq44951 Decstack;
tcellset44947 Cycleroots;
tcellseq44951 Tempstack;
NI Recgclock;
tmemregion27210 Region;
tgcstat47014 Stat;
};
struct  monotonicvar483024  {
tsym225846* V;
tsym225846* Alias;
tnode225816* Lower;
tnode225816* Upper;
tnode225816* Stride;
NU8 Dir;
NIM_BOOL Blacklisted;
};
struct TY483039 {
tnode225816* Field0;
tnode225816* Field1;
tnode225816* Field2;
NI Field3;
NIM_BOOL Field4;
};
struct  analysisctx483026  {
TY483036* Locals;
TY483038* Slices;
tnodeseq225810* Guards;
tsymseq225818* Args;
NI Spawns;
NI Currentspawnid;
NI Inloop;
};
typedef N_NIMCALL_PTR(void, TY3089) (void* p, NI op);
typedef N_NIMCALL_PTR(void*, TY3094) (void* p);
struct  TNimType  {
NI size;
NU8 kind;
NU8 flags;
TNimType* base;
TNimNode* node;
void* finalizer;
TY3089 marker;
TY3094 deepcopy;
};
struct  TNimNode  {
NU8 kind;
NI offset;
TNimType* typ;
NCSTRING name;
NI len;
TNimNode** sons;
};
struct  tlineinfo195539  {
NI16 Line;
NI16 Col;
NI32 Fileindex;
};
struct  tnode225816  {
ttype225852* Typ;
tlineinfo195539 Info;
NU16 Flags;
NU8 Kind;
union {
struct {NI64 Intval;
} S1;
struct {NF Floatval;
} S2;
struct {NimStringDesc* Strval;
} S3;
struct {tsym225846* Sym;
} S4;
struct {tident200021* Ident;
} S5;
struct {tnodeseq225810* Sons;
} S6;
} kindU;
NimStringDesc* Comment;
};
struct  TNimObject  {
TNimType* m_type;
};
struct  tidobj200015  {
  TNimObject Sup;
NI Id;
};
struct  tstrtable225820  {
NI Counter;
tsymseq225818* Data;
};
struct  tloc225830  {
NU8 K;
NU8 S;
NU8 Flags;
ttype225852* T;
trope177009* R;
trope177009* Heaproot;
};
struct  tsym225846  {
  tidobj200015 Sup;
NU8 Kind;
union {
struct {ttypeseq225848* Typeinstcache;
tscope225840* Typscope;
} S1;
struct {TY225947* Procinstcache;
tscope225840* Scope;
} S2;
struct {TY225947* Usedgenerics;
tstrtable225820 Tab;
} S3;
struct {tsym225846* Guard;
} S4;
} kindU;
NU16 Magic;
ttype225852* Typ;
tident200021* Name;
tlineinfo195539 Info;
tsym225846* Owner;
NU32 Flags;
tnode225816* Ast;
NU32 Options;
NI Position;
NI Offset;
tloc225830 Loc;
tlib225834* Annex;
tnode225816* Constraint;
};
struct  tident200021  {
  tidobj200015 Sup;
NimStringDesc* S;
tident200021* Next;
NI H;
};
typedef NimStringDesc* TY483908[6];
typedef NimStringDesc* TY197620[4];
struct  ttype225852  {
  tidobj200015 Sup;
NU8 Kind;
NU8 Callconv;
NU32 Flags;
ttypeseq225848* Sons;
tnode225816* N;
tsym225846* Owner;
tsym225846* Sym;
tsym225846* Destructor;
tsym225846* Deepcopy;
NI64 Size;
NI16 Align;
NI16 Locklevel;
tloc225830 Loc;
};
typedef NI TY26420[8];
struct  tpagedesc44943  {
tpagedesc44943* Next;
NI Key;
TY26420 Bits;
};
struct  tbasechunk26438  {
NI Prevsize;
NI Size;
NIM_BOOL Used;
};
struct  tsmallchunk26440  {
  tbasechunk26438 Sup;
tsmallchunk26440* Next;
tsmallchunk26440* Prev;
tfreecell26430* Freelist;
NI Free;
NI Acc;
NF Data;
};
struct  tllchunk27204  {
NI Size;
NI Acc;
tllchunk27204* Next;
};
struct  tbigchunk26442  {
  tbasechunk26438 Sup;
tbigchunk26442* Next;
tbigchunk26442* Prev;
NI Align;
NF Data;
};
struct  ttrunk26413  {
ttrunk26413* Next;
NI Key;
TY26420 Bits;
};
typedef tavlnode27208* TY27214[2];
struct  tavlnode27208  {
TY27214 Link;
NI Key;
NI Upperbound;
NI Level;
};
struct  tscope225840  {
NI Depthlevel;
tstrtable225820 Symbols;
tnodeseq225810* Usingsyms;
tscope225840* Parent;
};
struct  tinstantiation225836  {
tsym225846* Sym;
ttypeseq225848* Concretetypes;
TY225936* Usedby;
};
struct  trope177009  {
  TNimObject Sup;
trope177009* Left;
trope177009* Right;
NI Length;
NimStringDesc* Data;
};
struct  tlistentry127022  {
  TNimObject Sup;
tlistentry127022* Prev;
tlistentry127022* Next;
};
struct  tlib225834  {
  tlistentry127022 Sup;
NU8 Kind;
NIM_BOOL Generated;
NIM_BOOL Isoverriden;
trope177009* Name;
tnode225816* Path;
};
struct  tfreecell26430  {
tfreecell26430* Next;
NI Zerofield;
};
struct TY483036 {
  TGenericSeq Sup;
  monotonicvar483024 data[SEQ_DECL_SIZE];
};
struct TY483038 {
  TGenericSeq Sup;
  TY483039 data[SEQ_DECL_SIZE];
};
struct tnodeseq225810 {
  TGenericSeq Sup;
  tnode225816* data[SEQ_DECL_SIZE];
};
struct tsymseq225818 {
  TGenericSeq Sup;
  tsym225846* data[SEQ_DECL_SIZE];
};
struct ttypeseq225848 {
  TGenericSeq Sup;
  ttype225852* data[SEQ_DECL_SIZE];
};
struct TY225947 {
  TGenericSeq Sup;
  tinstantiation225836* data[SEQ_DECL_SIZE];
};
struct TY225936 {
  TGenericSeq Sup;
  NI32 data[SEQ_DECL_SIZE];
};
N_NIMCALL(tsym225846*, createmagic_368405)(NimStringDesc* name, NU16 m);
static N_INLINE(void, asgnRefNoCycle)(void** dest, void* src);
static N_INLINE(tcell44935*, usrtocell_48646)(void* usr);
static N_INLINE(void, rtladdzct_50204)(tcell44935* c);
N_NOINLINE(void, addzct_48617)(tcellseq44951* s, tcell44935* c);
N_NIMCALL(void, initanalysisctx_483059)(analysisctx483026* Result);
N_NIMCALL(void, nimGCvisit)(void* d, NI op);
N_NIMCALL(void, TMP3864)(void* p, NI op);
N_NIMCALL(void*, newSeq)(TNimType* typ, NI len);
N_NIMCALL(void, unsureAsgnRef)(void** dest, void* src);
N_NIMCALL(void, TMP3866)(void* p, NI op);
N_NOINLINE(void, chckNil)(void* p);
static N_INLINE(tnode225816*, lastson_226261)(tnode225816* n);
static N_INLINE(NI, sonslen_226249)(tnode225816* n);
N_NIMCALL(void, analyse_484509)(analysisctx483026* c, tnode225816* n);
N_NIMCALL(NIM_BOOL, issingleassignable_483416)(tnode225816* n);
static N_INLINE(tnode225816*, HEX5BHEX5D_226698)(tnode225816* n, NI i);
N_NIMCALL(NIM_BOOL, islocal_483501)(tnode225816* n);
N_NIMCALL(monotonicvar483024*, getslot_483239)(analysisctx483026* c, tsym225846* v);
N_NIMCALL(NI, lookupslot_483148)(analysisctx483026* c, tsym225846* s);
N_NIMCALL(TGenericSeq*, setLengthSeq)(TGenericSeq* seq, NI elemsize, NI newlen);
N_NIMCALL(void, invalidatefacts_370774)(tnodeseq225810** m, tnode225816* n);
N_NIMCALL(NU16, getmagic_261845)(tnode225816* op);
N_NIMCALL(void, gatherargs_483283)(analysisctx483026* c, tnode225816* n);
static N_INLINE(NI, safelen_226424)(tnode225816* n);
N_NIMCALL(tsym225846*, getroot_426533)(tnode225816* n);
N_NIMCALL(TGenericSeq*, incrSeq)(TGenericSeq* seq, NI elemsize);
N_NIMCALL(void, analysesons_484517)(analysisctx483026* c, tnode225816* n);
N_NIMCALL(void, addasgnfact_374618)(tnodeseq225810** m, tnode225816* key, tnode225816* value);
N_NIMCALL(void, analysecall_484647)(analysisctx483026* c, tnode225816* n, tsym225846* op);
static N_INLINE(NIM_BOOL, eqStrings)(NimStringDesc* a, NimStringDesc* b);
N_NIMCALL(NIM_BOOL, fromsystem_484616)(tsym225846* op);
N_NIMCALL(tsym225846*, getmodule_235243)(tsym225846* s);
N_NIMCALL(tnode225816*, skipconv_273732)(tnode225816* n);
N_NIMCALL(tnode225816*, min_484565)(tnode225816* a, tnode225816* b);
N_NIMCALL(void, addslice_483835)(analysisctx483026* c, tnode225816* n, tnode225816* x, tnode225816* le_483841, tnode225816* ri_483842);
N_NIMCALL(void, checklocal_483586)(analysisctx483026* c, tnode225816* n);
N_NIMCALL(void, localerror_197966)(tlineinfo195539 info, NimStringDesc* arg);
N_NIMCALL(tnode225816*, canon_369513)(tnode225816* n);
N_NIMCALL(void, addlowerboundasfacts_483708)(analysisctx483026* c);
N_NIMCALL(void, addfactle_374018)(tnodeseq225810** m, tnode225816* a, tnode225816* b);
N_NIMCALL(tnode225816*, newsymnode_226132)(tsym225846* sym);
N_NIMCALL(void, checkbounds_483697)(analysisctx483026* c, tnode225816* arr, tnode225816* idx);
N_NIMCALL(void, checkle_483686)(analysisctx483026* c, tnode225816* a, tnode225816* b);
N_NIMCALL(NU8, provele_373995)(tnodeseq225810* m, tnode225816* a, tnode225816* b);
static N_INLINE(void, appendString)(NimStringDesc* dest, NimStringDesc* src);
N_NIMCALL(NimStringDesc*, rendertree_250058)(tnode225816* n, NU8 renderflags);
N_NIMCALL(NimStringDesc*, rawNewString)(NI space);
N_NIMCALL(tnode225816*, lowbound_369448)(tnode225816* x);
N_NIMCALL(tnode225816*, highbound_369458)(tnode225816* x);
N_NIMCALL(void, genericAssign)(void* dest, void* src, TNimType* mt);
static N_INLINE(NI, len_226364)(tnode225816* n);
N_NIMCALL(void, internalerror_197987)(tlineinfo195539 info, NimStringDesc* errmsg);
N_NIMCALL(void, analysecase_484738)(analysisctx483026* c, tnode225816* n);
N_NIMCALL(void, addcasebranchfacts_374755)(tnodeseq225810** m, tnode225816* n, NI i);
N_NIMCALL(void, analyseif_484911)(analysisctx483026* c, tnode225816* n);
N_NIMCALL(void, addfact_370349)(tnodeseq225810** m, tnode225816* n_370353);
N_NIMCALL(void, addfactneg_370396)(tnodeseq225810** m, tnode225816* n_370400);
N_NIMCALL(NIM_BOOL, istrue_381730)(tnode225816* n);
N_NIMCALL(NIM_BOOL, hassubnodewith_226308)(tnode225816* n, NU8 kind);
N_NIMCALL(void, checkslicesaredisjoint_484168)(analysisctx483026* c);
N_NIMCALL(void, overlap_483899)(tnodeseq225810* m, tnode225816* x, tnode225816* y, tnode225816* c, tnode225816* d);
N_NIMCALL(NimStringDesc*, nsuFormatOpenArray)(NimStringDesc* formatstr, NimStringDesc** a, NI aLen0);
N_NIMCALL(tnode225816*, substride_484044)(analysisctx483026* c, tnode225816* n);
N_NIMCALL(tnode225816*, HEX2BHEX40_369779)(tnode225816* a, NI64 b);
N_NIMCALL(tnode225816*, shallowcopy_231347)(tnode225816* src);
N_NIMCALL(NIM_BOOL, sametree_370425)(tnode225816* a, tnode225816* b);
N_NIMCALL(NI64, simpleslice_373066)(tnode225816* a, tnode225816* b);
N_NIMCALL(NI64, stride_483924)(analysisctx483026* c, tnode225816* n);
N_NIMCALL(void, checkargs_485951)(analysisctx483026* a, tnode225816* n);
N_NIMCALL(tnode225816*, newnodei_226138)(NU8 kind, tlineinfo195539 info);
N_NIMCALL(tsym225846*, newsym_226074)(NU8 symkind, tident200021* name, tsym225846* owner, tlineinfo195539 info);
N_NIMCALL(tident200021*, getident_200472)(NimStringDesc* identifier);
N_NIMCALL(tsym225846*, getcompilerproc_282036)(NimStringDesc* name);
N_NIMCALL(void, addvar_424053)(tnode225816* father, tnode225816* v);
N_NIMCALL(tnode225816*, genaddrof_425872)(tnode225816* n);
N_NIMCALL(void, generatealiaschecks_485962)(analysisctx483026* a, tnode225816* result);
N_NIMCALL(void, add_226498)(tnode225816* father, tnode225816* son);
N_NIMCALL(tnode225816*, callcodegenproc_425906)(NimStringDesc* name, tnode225816* arg1, tnode225816* arg2, tnode225816* arg3);
N_NIMCALL(tnode225816*, transformspawn_485729)(tsym225846* owner, tnode225816* n, tnode225816* barrier);
N_NIMCALL(tnode225816*, transformslices_485615)(tnode225816* n);
N_NIMCALL(tnode225816*, copynode_226323)(tnode225816* src);
N_NIMCALL(NU8, spawnresult_425994)(ttype225852* t, NIM_BOOL inparallel);
N_NIMCALL(tnode225816*, wrapprocforspawn_426897)(tsym225846* owner, tnode225816* spawnexpr, ttype225852* rettype, tnode225816* barrier, tnode225816* dest);
N_NIMCALL(tnode225816*, transformspawnsons_485737)(tsym225846* owner, tnode225816* n, tnode225816* barrier);
STRING_LITERAL(TMP952, "slice", 5);
STRING_LITERAL(TMP3867, "+=", 2);
STRING_LITERAL(TMP3868, "[]", 2);
STRING_LITERAL(TMP3869, "invalid usage of counter after increment", 40);
STRING_LITERAL(TMP3874, "cannot prove: ", 14);
STRING_LITERAL(TMP3875, " <= ", 4);
STRING_LITERAL(TMP3876, "can prove: ", 11);
STRING_LITERAL(TMP3877, " > ", 3);
STRING_LITERAL(TMP3878, "[]=", 3);
STRING_LITERAL(TMP3879, "invalid control flow for \'parallel\'", 35);
STRING_LITERAL(TMP3880, "slot already has a lower bound", 30);
STRING_LITERAL(TMP3881, "\'parallel\' section without \'spawn\'", 34);
STRING_LITERAL(TMP3882, "cannot prove: $# > $#; required for ($#)..($#) disjoint from ($"
"#)..($#)", 71);
STRING_LITERAL(TMP3883, "($#)..($#) not disjoint from ($#)..($#)", 39);
STRING_LITERAL(TMP3884, "cannot prove ($#)..($#) disjoint from ($#)..($#)", 48);
STRING_LITERAL(TMP3885, "barrier", 7);
STRING_LITERAL(TMP3886, "Barrier", 7);
STRING_LITERAL(TMP3887, "openBarrier", 11);
STRING_LITERAL(TMP3888, "invalid context for \'spawn\'", 27);
STRING_LITERAL(TMP3889, "closeBarrier", 12);
tsym225846* opslice_483055;
extern tgcheap47016 gch_47044;
TNimType NTI483024; /* MonotonicVar */
extern TNimType NTI225814; /* PSym */
extern TNimType NTI225808; /* PNode */
TNimType NTI483022; /* TDirection */
extern TNimType NTI138; /* bool */
TNimType NTI483036; /* seq[MonotonicVar] */
TNimType NTI483039; /* tuple[x: PNode, a: PNode, b: PNode, spawnId: int, inLoop: bool] */
extern TNimType NTI108; /* int */
TNimType NTI483038; /* seq[tuple[x: PNode, a: PNode, b: PNode, spawnId: int, inLoop: bool]] */
extern TNimType NTI225818; /* TSymSeq */
extern TNimType NTI225810; /* TNodeSeq */
extern tnode225816* emptynode_226738;

static N_INLINE(tcell44935*, usrtocell_48646)(void* usr) {
	tcell44935* result;
	result = 0;
	result = ((tcell44935*) ((NI)((NU64)(((NI) (usr))) - (NU64)(((NI)sizeof(tcell44935))))));
	return result;
}

static N_INLINE(void, rtladdzct_50204)(tcell44935* c) {
	addzct_48617((&gch_47044.Zct), c);
}

static N_INLINE(void, asgnRefNoCycle)(void** dest, void* src) {
	{
		tcell44935* c;
		if (!!((src == NIM_NIL))) goto LA3;
		c = usrtocell_48646(src);
		(*c).Refcount += 8;
	}
	LA3: ;
	{
		tcell44935* c;
		if (!!(((*dest) == NIM_NIL))) goto LA7;
		c = usrtocell_48646((*dest));
		{
			(*c).Refcount -= 8;
			if (!((NU64)((*c).Refcount) < (NU64)(8))) goto LA11;
			rtladdzct_50204(c);
		}
		LA11: ;
	}
	LA7: ;
	(*dest) = src;
}
N_NIMCALL(void, TMP3864)(void* p, NI op) {
	TY483036* a;
	NI LOC1;
	a = (TY483036*)p;
	LOC1 = 0;
	for (LOC1 = 0; LOC1 < a->Sup.len; LOC1++) {
	nimGCvisit((void*)a->data[LOC1].V, op);
	nimGCvisit((void*)a->data[LOC1].Alias, op);
	nimGCvisit((void*)a->data[LOC1].Lower, op);
	nimGCvisit((void*)a->data[LOC1].Upper, op);
	nimGCvisit((void*)a->data[LOC1].Stride, op);
	}
}
N_NIMCALL(void, TMP3866)(void* p, NI op) {
	TY483038* a;
	NI LOC1;
	a = (TY483038*)p;
	LOC1 = 0;
	for (LOC1 = 0; LOC1 < a->Sup.len; LOC1++) {
	nimGCvisit((void*)a->data[LOC1].Field0, op);
	nimGCvisit((void*)a->data[LOC1].Field1, op);
	nimGCvisit((void*)a->data[LOC1].Field2, op);
	}
}

N_NIMCALL(void, initanalysisctx_483059)(analysisctx483026* Result) {
	unsureAsgnRef((void**) (&(*Result).Locals), (TY483036*) newSeq((&NTI483036), 0));
	unsureAsgnRef((void**) (&(*Result).Slices), (TY483038*) newSeq((&NTI483038), 0));
	unsureAsgnRef((void**) (&(*Result).Args), (tsymseq225818*) newSeq((&NTI225818), 0));
	unsureAsgnRef((void**) (&(*Result).Guards), (tnodeseq225810*) newSeq((&NTI225810), 0));
}

static N_INLINE(NI, sonslen_226249)(tnode225816* n) {
	NI result;
	result = 0;
	{
		if (!(*n).kindU.S6.Sons == 0) goto LA3;
		result = 0;
	}
	goto LA1;
	LA3: ;
	{
		result = (*n).kindU.S6.Sons->Sup.len;
	}
	LA1: ;
	return result;
}

static N_INLINE(tnode225816*, lastson_226261)(tnode225816* n) {
	tnode225816* result;
	NI LOC1;
	result = 0;
	LOC1 = 0;
	LOC1 = sonslen_226249(n);
	result = (*n).kindU.S6.Sons->data[(NI64)(LOC1 - 1)];
	return result;
}

N_NIMCALL(NIM_BOOL, issingleassignable_483416)(tnode225816* n) {
	NIM_BOOL result;
	NIM_BOOL LOC1;
	tsym225846* s;
	NIM_BOOL LOC3;
	result = 0;
	LOC1 = 0;
	LOC1 = ((*n).Kind == ((NU8) 3));
	if (!(LOC1)) goto LA2;
	s = (*n).kindU.S4.Sym;
	LOC3 = 0;
	LOC3 = ((2097696 &(1<<(((*s).Kind)&31)))!=0);
	if (!(LOC3)) goto LA4;
	LOC3 = ((32776 & (*s).Flags) == 0);
	LA4: ;
	LOC1 = LOC3;
	LA2: ;
	result = LOC1;
	return result;
}

static N_INLINE(tnode225816*, HEX5BHEX5D_226698)(tnode225816* n, NI i) {
	tnode225816* result;
	result = 0;
	result = (*n).kindU.S6.Sons->data[i];
	return result;
}

N_NIMCALL(NIM_BOOL, islocal_483501)(tnode225816* n) {
	NIM_BOOL result;
	NIM_BOOL LOC1;
	tsym225846* s;
	NIM_BOOL LOC3;
	result = 0;
	LOC1 = 0;
	LOC1 = ((*n).Kind == ((NU8) 3));
	if (!(LOC1)) goto LA2;
	s = (*n).kindU.S4.Sym;
	LOC3 = 0;
	LOC3 = ((2100000 &(1<<(((*s).Kind)&31)))!=0);
	if (!(LOC3)) goto LA4;
	LOC3 = ((32776 & (*s).Flags) == 0);
	LA4: ;
	LOC1 = LOC3;
	LA2: ;
	result = LOC1;
	return result;
}

N_NIMCALL(NI, lookupslot_483148)(analysisctx483026* c, tsym225846* s) {
	NI result;
	result = 0;
	{
		NI i_483185;
		NI HEX3Atmp_483219;
		NI res_483222;
		i_483185 = 0;
		HEX3Atmp_483219 = 0;
		HEX3Atmp_483219 = ((*c).Locals->Sup.len - 1);
		res_483222 = 0;
		{
			while (1) {
				if (!(res_483222 <= HEX3Atmp_483219)) goto LA3;
				i_483185 = res_483222;
				{
					NIM_BOOL LOC6;
					LOC6 = 0;
					LOC6 = ((*c).Locals->data[i_483185].V == s);
					if (LOC6) goto LA7;
					LOC6 = ((*c).Locals->data[i_483185].Alias == s);
					LA7: ;
					if (!LOC6) goto LA8;
					result = i_483185;
					goto BeforeRet;
				}
				LA8: ;
				res_483222 += 1;
			} LA3: ;
		}
	}
	result = -1;
	goto BeforeRet;
	BeforeRet: ;
	return result;
}

N_NIMCALL(monotonicvar483024*, getslot_483239)(analysisctx483026* c, tsym225846* v) {
	monotonicvar483024* result;
	NI s;
	NI l;
	result = 0;
	s = lookupslot_483148((&(*c)), v);
	{
		if (!(0 <= s)) goto LA3;
		result = (&(*c).Locals->data[s]);
		goto BeforeRet;
	}
	LA3: ;
	l = (*c).Locals->Sup.len;
	(*c).Locals = (TY483036*) setLengthSeq(&((*c).Locals)->Sup, sizeof(monotonicvar483024), (NI64)(l + 1));
	asgnRefNoCycle((void**) (&(*c).Locals->data[l].V), v);
	result = (&(*c).Locals->data[l]);
	goto BeforeRet;
	BeforeRet: ;
	return result;
}

static N_INLINE(NI, safelen_226424)(tnode225816* n) {
	NI result;
	result = 0;
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = ((*n).Kind >= ((NU8) 0) && (*n).Kind <= ((NU8) 23));
		if (LOC3) goto LA4;
		LOC3 = (*n).kindU.S6.Sons == 0;
		LA4: ;
		if (!LOC3) goto LA5;
		result = 0;
	}
	goto LA1;
	LA5: ;
	{
		result = (*n).kindU.S6.Sons->Sup.len;
	}
	LA1: ;
	return result;
}

N_NIMCALL(void, gatherargs_483283)(analysisctx483026* c, tnode225816* n) {
	{
		NI i_483309;
		NI HEX3Atmp_483384;
		NI LOC2;
		NI res_483387;
		i_483309 = 0;
		HEX3Atmp_483384 = 0;
		LOC2 = 0;
		LOC2 = safelen_226424(n);
		HEX3Atmp_483384 = (LOC2 - 1);
		res_483387 = 0;
		{
			while (1) {
				tsym225846* root;
				tnode225816* LOC5;
				tnode225816* LOC18;
				if (!(res_483387 <= HEX3Atmp_483384)) goto LA4;
				i_483309 = res_483387;
				LOC5 = 0;
				LOC5 = HEX5BHEX5D_226698(n, i_483309);
				root = getroot_426533(LOC5);
				{
					if (!!((root == NIM_NIL))) goto LA8;
					{
						{
							tsym225846* r_483341;
							tsymseq225818* HEX3Atmp_483378;
							NI i_483381;
							NI l_483383;
							r_483341 = 0;
							HEX3Atmp_483378 = 0;
							HEX3Atmp_483378 = (*c).Args;
							i_483381 = 0;
							l_483383 = HEX3Atmp_483378->Sup.len;
							{
								while (1) {
									if (!(i_483381 < l_483383)) goto LA13;
									r_483341 = HEX3Atmp_483378->data[i_483381];
									{
										if (!(r_483341 == root)) goto LA16;
										goto LA10;
									}
									LA16: ;
									i_483381 += 1;
								} LA13: ;
							}
						}
						(*c).Args = (tsymseq225818*) incrSeq(&((*c).Args)->Sup, sizeof(tsym225846*));
						asgnRefNoCycle((void**) (&(*c).Args->data[(*c).Args->Sup.len-1]), root);
					} LA10: ;
				}
				LA8: ;
				LOC18 = 0;
				LOC18 = HEX5BHEX5D_226698(n, i_483309);
				gatherargs_483283(c, LOC18);
				res_483387 += 1;
			} LA4: ;
		}
	}
}

N_NIMCALL(void, analysesons_484517)(analysisctx483026* c, tnode225816* n) {
	{
		NI i_484543;
		NI HEX3Atmp_484545;
		NI LOC2;
		NI res_484548;
		i_484543 = 0;
		HEX3Atmp_484545 = 0;
		LOC2 = 0;
		LOC2 = safelen_226424(n);
		HEX3Atmp_484545 = (LOC2 - 1);
		res_484548 = 0;
		{
			while (1) {
				tnode225816* LOC5;
				if (!(res_484548 <= HEX3Atmp_484545)) goto LA4;
				i_484543 = res_484548;
				LOC5 = 0;
				LOC5 = HEX5BHEX5D_226698(n, i_484543);
				analyse_484509(c, LOC5);
				res_484548 += 1;
			} LA4: ;
		}
	}
}

static N_INLINE(NIM_BOOL, eqStrings)(NimStringDesc* a, NimStringDesc* b) {
	NIM_BOOL result;
	NIM_BOOL LOC11;
	int LOC13;
	result = 0;
	{
		if (!(a == b)) goto LA3;
		result = NIM_TRUE;
		goto BeforeRet;
	}
	LA3: ;
	{
		NIM_BOOL LOC7;
		LOC7 = 0;
		LOC7 = (a == NIM_NIL);
		if (LOC7) goto LA8;
		LOC7 = (b == NIM_NIL);
		LA8: ;
		if (!LOC7) goto LA9;
		result = NIM_FALSE;
		goto BeforeRet;
	}
	LA9: ;
	LOC11 = 0;
	LOC11 = ((*a).Sup.len == (*b).Sup.len);
	if (!(LOC11)) goto LA12;
	LOC13 = 0;
	LOC13 = memcmp(((NCSTRING) ((*a).data)), ((NCSTRING) ((*b).data)), (NI64)((*a).Sup.len * 1));
	LOC11 = (LOC13 == ((NI32) 0));
	LA12: ;
	result = LOC11;
	goto BeforeRet;
	BeforeRet: ;
	return result;
}

N_NIMCALL(NIM_BOOL, fromsystem_484616)(tsym225846* op) {
	NIM_BOOL result;
	tsym225846* LOC1;
	result = 0;
	LOC1 = 0;
	LOC1 = getmodule_235243(op);
	result = (((*LOC1).Flags &(1<<((((NU8) 13))&31)))!=0);
	return result;
}

N_NIMCALL(tnode225816*, min_484565)(tnode225816* a, tnode225816* b) {
	tnode225816* result;
	result = 0;
	{
		if (!a == 0) goto LA3;
		result = b;
	}
	goto LA1;
	LA3: ;
	{
		if (!((*a).kindU.S1.Intval < (*b).kindU.S1.Intval)) goto LA6;
		result = a;
	}
	goto LA1;
	LA6: ;
	{
		result = b;
	}
	LA1: ;
	return result;
}

N_NIMCALL(void, checklocal_483586)(analysisctx483026* c, tnode225816* n) {
	{
		NIM_BOOL LOC3;
		NI s;
		LOC3 = 0;
		LOC3 = islocal_483501(n);
		if (!LOC3) goto LA4;
		s = lookupslot_483148(c, (*n).kindU.S4.Sym);
		{
			NIM_BOOL LOC8;
			LOC8 = 0;
			LOC8 = (0 <= s);
			if (!(LOC8)) goto LA9;
			LOC8 = !(((*c).Locals->data[s].Stride == NIM_NIL));
			LA9: ;
			if (!LOC8) goto LA10;
			localerror_197966((*n).Info, ((NimStringDesc*) &TMP3869));
		}
		LA10: ;
	}
	goto LA1;
	LA4: ;
	{
		{
			NI i_483643;
			NI HEX3Atmp_483659;
			NI LOC14;
			NI res_483662;
			i_483643 = 0;
			HEX3Atmp_483659 = 0;
			LOC14 = 0;
			LOC14 = safelen_226424(n);
			HEX3Atmp_483659 = (LOC14 - 1);
			res_483662 = 0;
			{
				while (1) {
					if (!(res_483662 <= HEX3Atmp_483659)) goto LA16;
					i_483643 = res_483662;
					checklocal_483586(c, (*n).kindU.S6.Sons->data[i_483643]);
					res_483662 += 1;
				} LA16: ;
			}
		}
	}
	LA1: ;
}

N_NIMCALL(void, addlowerboundasfacts_483708)(analysisctx483026* c) {
	{
		monotonicvar483024 v_483811;
		TY483036* HEX3Atmp_483814;
		NI i_483817;
		NI l_483819;
		memset((void*)(&v_483811), 0, sizeof(v_483811));
		HEX3Atmp_483814 = 0;
		HEX3Atmp_483814 = (*c).Locals;
		i_483817 = 0;
		l_483819 = HEX3Atmp_483814->Sup.len;
		{
			while (1) {
				if (!(i_483817 < l_483819)) goto LA3;
				memcpy((void*)(&v_483811), (NIM_CONST void*)(&HEX3Atmp_483814->data[i_483817]), sizeof(v_483811));
				{
					tnode225816* LOC8;
					if (!!(v_483811.Blacklisted)) goto LA6;
					LOC8 = 0;
					LOC8 = newsymnode_226132(v_483811.V);
					addfactle_374018((&(*c).Guards), v_483811.Lower, LOC8);
				}
				LA6: ;
				i_483817 += 1;
			} LA3: ;
		}
	}
}

static N_INLINE(void, appendString)(NimStringDesc* dest, NimStringDesc* src) {
	memcpy(((NCSTRING) ((&(*dest).data[((*dest).Sup.len)- 0]))), ((NCSTRING) ((*src).data)), (NI64)((*src).Sup.len + 1));
	(*dest).Sup.len += (*src).Sup.len;
}

N_NIMCALL(void, checkle_483686)(analysisctx483026* c, tnode225816* a, tnode225816* b) {
	NU8 LOC1;
	LOC1 = 0;
	LOC1 = provele_373995((*c).Guards, a, b);
	switch (LOC1) {
	case ((NU8) 0):
	{
		NimStringDesc* LOC3;
		NimStringDesc* LOC4;
		NimStringDesc* LOC5;
		LOC3 = 0;
		LOC4 = 0;
		LOC4 = rendertree_250058(a, 0);
		LOC5 = 0;
		LOC5 = rendertree_250058(b, 0);
		LOC3 = rawNewString(LOC4->Sup.len + LOC5->Sup.len + 18);
appendString(LOC3, ((NimStringDesc*) &TMP3874));
appendString(LOC3, LOC4);
appendString(LOC3, ((NimStringDesc*) &TMP3875));
appendString(LOC3, LOC5);
		localerror_197966((*a).Info, LOC3);
	}
	break;
	case ((NU8) 2):
	{
	}
	break;
	case ((NU8) 1):
	{
		NimStringDesc* LOC8;
		NimStringDesc* LOC9;
		NimStringDesc* LOC10;
		LOC8 = 0;
		LOC9 = 0;
		LOC9 = rendertree_250058(a, 0);
		LOC10 = 0;
		LOC10 = rendertree_250058(b, 0);
		LOC8 = rawNewString(LOC9->Sup.len + LOC10->Sup.len + 14);
appendString(LOC8, ((NimStringDesc*) &TMP3876));
appendString(LOC8, LOC9);
appendString(LOC8, ((NimStringDesc*) &TMP3877));
appendString(LOC8, LOC10);
		localerror_197966((*a).Info, LOC8);
	}
	break;
	}
}

N_NIMCALL(void, checkbounds_483697)(analysisctx483026* c, tnode225816* arr, tnode225816* idx) {
	tnode225816* LOC1;
	tnode225816* LOC2;
	LOC1 = 0;
	LOC1 = lowbound_369448(arr);
	checkle_483686(c, LOC1, idx);
	LOC2 = 0;
	LOC2 = highbound_369458(arr);
	checkle_483686(c, idx, LOC2);
}

N_NIMCALL(void, addslice_483835)(analysisctx483026* c, tnode225816* n, tnode225816* x, tnode225816* le_483841, tnode225816* ri_483842) {
	tnode225816* le;
	tnode225816* ri;
	NI oldstate;
	TY483039 LOC1;
	checklocal_483586((&(*c)), n);
	le = canon_369513(le_483841);
	ri = canon_369513(ri_483842);
	oldstate = (*c).Guards->Sup.len;
	addlowerboundasfacts_483708(c);
	checkbounds_483697((&(*c)), x, le);
	checkbounds_483697((&(*c)), x, ri);
	(*c).Guards = (tnodeseq225810*) setLengthSeq(&((*c).Guards)->Sup, sizeof(tnode225816*), oldstate);
	memset((void*)(&LOC1), 0, sizeof(LOC1));
	LOC1.Field0 = x;
	LOC1.Field1 = le;
	LOC1.Field2 = ri;
	LOC1.Field3 = (*c).Currentspawnid;
	LOC1.Field4 = (0 < (*c).Inloop);
	(*c).Slices = (TY483038*) incrSeq(&((*c).Slices)->Sup, sizeof(TY483039));
	genericAssign((void*)(&(*c).Slices->data[(*c).Slices->Sup.len-1]), (void*)(&LOC1), (&NTI483039));
}

N_NIMCALL(void, analysecall_484647)(analysisctx483026* c, tnode225816* n, tsym225846* op) {
	{
		NI oldspawnid;
		tnode225816* LOC5;
		if (!((*op).Magic == ((NU16) 213))) goto LA3;
		(*c).Spawns += 1;
		oldspawnid = (*c).Currentspawnid;
		(*c).Currentspawnid = (*c).Spawns;
		LOC5 = 0;
		LOC5 = HEX5BHEX5D_226698(n, 1);
		gatherargs_483283(c, LOC5);
		analysesons_484517(c, n);
		(*c).Currentspawnid = oldspawnid;
	}
	goto LA1;
	LA3: ;
	{
		NIM_BOOL LOC7;
		NIM_BOOL LOC9;
		LOC7 = 0;
		LOC7 = ((*op).Magic == ((NU16) 21));
		if (LOC7) goto LA8;
		LOC9 = 0;
		LOC9 = eqStrings((*(*op).Name).S, ((NimStringDesc*) &TMP3867));
		if (!(LOC9)) goto LA10;
		LOC9 = fromsystem_484616(op);
		LA10: ;
		LOC7 = LOC9;
		LA8: ;
		if (!LOC7) goto LA11;
		{
			tnode225816* LOC15;
			NIM_BOOL LOC16;
			tnode225816* incr;
			tnode225816* LOC19;
			LOC15 = 0;
			LOC15 = HEX5BHEX5D_226698(n, 1);
			LOC16 = 0;
			LOC16 = islocal_483501(LOC15);
			if (!LOC16) goto LA17;
			LOC19 = 0;
			LOC19 = HEX5BHEX5D_226698(n, 2);
			incr = skipconv_273732(LOC19);
			{
				NIM_BOOL LOC22;
				monotonicvar483024* slot;
				tnode225816* LOC26;
				LOC22 = 0;
				LOC22 = ((*incr).Kind >= ((NU8) 5) && (*incr).Kind <= ((NU8) 14));
				if (!(LOC22)) goto LA23;
				LOC22 = (IL64(0) < (*incr).kindU.S1.Intval);
				LA23: ;
				if (!LOC22) goto LA24;
				LOC26 = 0;
				LOC26 = HEX5BHEX5D_226698(n, 1);
				slot = getslot_483239(c, (*LOC26).kindU.S4.Sym);
				unsureAsgnRef((void**) (&(*slot).Stride), min_484565((*slot).Stride, incr));
			}
			LA24: ;
		}
		LA17: ;
		analysesons_484517(c, n);
	}
	goto LA1;
	LA11: ;
	{
		NIM_BOOL LOC28;
		tnode225816* LOC32;
		tnode225816* LOC33;
		tnode225816* LOC34;
		tnode225816* LOC35;
		tnode225816* LOC36;
		LOC28 = 0;
		LOC28 = eqStrings((*(*op).Name).S, ((NimStringDesc*) &TMP3868));
		if (!(LOC28)) goto LA29;
		LOC28 = fromsystem_484616(op);
		LA29: ;
		if (!LOC28) goto LA30;
		LOC32 = 0;
		LOC32 = HEX5BHEX5D_226698(n, 1);
		LOC33 = 0;
		LOC33 = HEX5BHEX5D_226698(n, 2);
		LOC34 = 0;
		LOC34 = HEX5BHEX5D_226698(LOC33, 1);
		LOC35 = 0;
		LOC35 = HEX5BHEX5D_226698(n, 2);
		LOC36 = 0;
		LOC36 = HEX5BHEX5D_226698(LOC35, 2);
		addslice_483835(c, n, LOC32, LOC34, LOC36);
		analysesons_484517(c, n);
	}
	goto LA1;
	LA30: ;
	{
		NIM_BOOL LOC38;
		tnode225816* LOC42;
		tnode225816* LOC43;
		tnode225816* LOC44;
		tnode225816* LOC45;
		tnode225816* LOC46;
		LOC38 = 0;
		LOC38 = eqStrings((*(*op).Name).S, ((NimStringDesc*) &TMP3878));
		if (!(LOC38)) goto LA39;
		LOC38 = fromsystem_484616(op);
		LA39: ;
		if (!LOC38) goto LA40;
		LOC42 = 0;
		LOC42 = HEX5BHEX5D_226698(n, 1);
		LOC43 = 0;
		LOC43 = HEX5BHEX5D_226698(n, 2);
		LOC44 = 0;
		LOC44 = HEX5BHEX5D_226698(LOC43, 1);
		LOC45 = 0;
		LOC45 = HEX5BHEX5D_226698(n, 2);
		LOC46 = 0;
		LOC46 = HEX5BHEX5D_226698(LOC45, 2);
		addslice_483835(c, n, LOC42, LOC44, LOC46);
		analysesons_484517(c, n);
	}
	goto LA1;
	LA40: ;
	{
		analysesons_484517(c, n);
	}
	LA1: ;
}

static N_INLINE(NI, len_226364)(tnode225816* n) {
	NI result;
	result = 0;
	{
		if (!(*n).kindU.S6.Sons == 0) goto LA3;
		result = 0;
	}
	goto LA1;
	LA3: ;
	{
		result = (*n).kindU.S6.Sons->Sup.len;
	}
	LA1: ;
	return result;
}

N_NIMCALL(void, analysecase_484738)(analysisctx483026* c, tnode225816* n) {
	NI oldfacts;
	analyse_484509(c, (*n).kindU.S6.Sons->data[0]);
	oldfacts = (*c).Guards->Sup.len;
	{
		NI i_484790;
		NI HEX3Atmp_484882;
		NI LOC2;
		NI res_484885;
		i_484790 = 0;
		HEX3Atmp_484882 = 0;
		LOC2 = 0;
		LOC2 = len_226364(n);
		HEX3Atmp_484882 = (LOC2 - 1);
		res_484885 = 1;
		{
			while (1) {
				tnode225816* branch;
				if (!(res_484885 <= HEX3Atmp_484882)) goto LA4;
				i_484790 = res_484885;
				branch = (*n).kindU.S6.Sons->data[i_484790];
				(*c).Guards = (tnodeseq225810*) setLengthSeq(&((*c).Guards)->Sup, sizeof(tnode225816*), oldfacts);
				addcasebranchfacts_374755((&(*c).Guards), n, i_484790);
				{
					NI i_484844;
					NI HEX3Atmp_484877;
					NI LOC6;
					NI res_484880;
					i_484844 = 0;
					HEX3Atmp_484877 = 0;
					LOC6 = 0;
					LOC6 = len_226364(branch);
					HEX3Atmp_484877 = (LOC6 - 1);
					res_484880 = 0;
					{
						while (1) {
							if (!(res_484880 <= HEX3Atmp_484877)) goto LA8;
							i_484844 = res_484880;
							analyse_484509(c, (*branch).kindU.S6.Sons->data[i_484844]);
							res_484880 += 1;
						} LA8: ;
					}
				}
				res_484885 += 1;
			} LA4: ;
		}
	}
	(*c).Guards = (tnodeseq225810*) setLengthSeq(&((*c).Guards)->Sup, sizeof(tnode225816*), oldfacts);
}

N_NIMCALL(void, analyseif_484911)(analysisctx483026* c, tnode225816* n) {
	NI oldfacts;
	tnode225816* LOC1;
	analyse_484509(c, (*(*n).kindU.S6.Sons->data[0]).kindU.S6.Sons->data[0]);
	oldfacts = (*c).Guards->Sup.len;
	LOC1 = 0;
	LOC1 = canon_369513((*(*n).kindU.S6.Sons->data[0]).kindU.S6.Sons->data[0]);
	addfact_370349((&(*c).Guards), LOC1);
	analyse_484509(c, (*(*n).kindU.S6.Sons->data[0]).kindU.S6.Sons->data[1]);
	{
		NI i_485034;
		NI HEX3Atmp_485187;
		NI LOC3;
		NI res_485190;
		i_485034 = 0;
		HEX3Atmp_485187 = 0;
		LOC3 = 0;
		LOC3 = len_226364(n);
		HEX3Atmp_485187 = (LOC3 - 1);
		res_485190 = 1;
		{
			while (1) {
				tnode225816* branch;
				if (!(res_485190 <= HEX3Atmp_485187)) goto LA5;
				i_485034 = res_485190;
				branch = (*n).kindU.S6.Sons->data[i_485034];
				(*c).Guards = (tnodeseq225810*) setLengthSeq(&((*c).Guards)->Sup, sizeof(tnode225816*), oldfacts);
				{
					NI j_485076;
					NI HEX3Atmp_485176;
					NI res_485179;
					j_485076 = 0;
					HEX3Atmp_485176 = 0;
					HEX3Atmp_485176 = (NI64)(i_485034 - 1);
					res_485179 = 0;
					{
						while (1) {
							tnode225816* LOC9;
							if (!(res_485179 <= HEX3Atmp_485176)) goto LA8;
							j_485076 = res_485179;
							LOC9 = 0;
							LOC9 = canon_369513((*(*n).kindU.S6.Sons->data[j_485076]).kindU.S6.Sons->data[0]);
							addfactneg_370396((&(*c).Guards), LOC9);
							res_485179 += 1;
						} LA8: ;
					}
				}
				{
					NI LOC12;
					tnode225816* LOC15;
					LOC12 = 0;
					LOC12 = len_226364(branch);
					if (!(1 < LOC12)) goto LA13;
					LOC15 = 0;
					LOC15 = canon_369513((*branch).kindU.S6.Sons->data[0]);
					addfact_370349((&(*c).Guards), LOC15);
				}
				LA13: ;
				{
					NI i_485143;
					NI HEX3Atmp_485182;
					NI LOC17;
					NI res_485185;
					i_485143 = 0;
					HEX3Atmp_485182 = 0;
					LOC17 = 0;
					LOC17 = len_226364(branch);
					HEX3Atmp_485182 = (LOC17 - 1);
					res_485185 = 0;
					{
						while (1) {
							if (!(res_485185 <= HEX3Atmp_485182)) goto LA19;
							i_485143 = res_485185;
							analyse_484509(c, (*branch).kindU.S6.Sons->data[i_485143]);
							res_485185 += 1;
						} LA19: ;
					}
				}
				res_485190 += 1;
			} LA5: ;
		}
	}
	(*c).Guards = (tnodeseq225810*) setLengthSeq(&((*c).Guards)->Sup, sizeof(tnode225816*), oldfacts);
}

N_NIMCALL(void, analyse_484509)(analysisctx483026* c, tnode225816* n) {
	switch ((*n).Kind) {
	case ((NU8) 73):
	case ((NU8) 74):
	{
		tnode225816* LOC18;
		tnode225816* value;
		tnode225816* LOC28;
		tnode225816* LOC29;
		{
			NIM_BOOL LOC4;
			tnode225816* LOC5;
			tnode225816* LOC7;
			monotonicvar483024* slot;
			tnode225816* LOC10;
			tnode225816* LOC11;
			LOC4 = 0;
			LOC5 = 0;
			LOC5 = HEX5BHEX5D_226698(n, 0);
			LOC4 = issingleassignable_483416(LOC5);
			if (!(LOC4)) goto LA6;
			LOC7 = 0;
			LOC7 = HEX5BHEX5D_226698(n, 1);
			LOC4 = islocal_483501(LOC7);
			LA6: ;
			if (!LOC4) goto LA8;
			LOC10 = 0;
			LOC10 = HEX5BHEX5D_226698(n, 1);
			slot = getslot_483239(c, (*LOC10).kindU.S4.Sym);
			LOC11 = 0;
			LOC11 = HEX5BHEX5D_226698(n, 0);
			unsureAsgnRef((void**) (&(*slot).Alias), (*LOC11).kindU.S4.Sym);
		}
		goto LA2;
		LA8: ;
		{
			tnode225816* LOC13;
			NIM_BOOL LOC14;
			monotonicvar483024* slot;
			tnode225816* LOC17;
			LOC13 = 0;
			LOC13 = HEX5BHEX5D_226698(n, 0);
			LOC14 = 0;
			LOC14 = islocal_483501(LOC13);
			if (!LOC14) goto LA15;
			LOC17 = 0;
			LOC17 = HEX5BHEX5D_226698(n, 0);
			slot = getslot_483239(c, (*LOC17).kindU.S4.Sym);
			(*slot).Blacklisted = NIM_TRUE;
		}
		goto LA2;
		LA15: ;
		LA2: ;
		LOC18 = 0;
		LOC18 = HEX5BHEX5D_226698(n, 0);
		invalidatefacts_370774((&(*c).Guards), LOC18);
		value = HEX5BHEX5D_226698(n, 1);
		{
			NU16 LOC21;
			NI oldspawnid;
			tnode225816* LOC24;
			tnode225816* LOC25;
			tnode225816* LOC26;
			LOC21 = 0;
			LOC21 = getmagic_261845(value);
			if (!(LOC21 == ((NU16) 213))) goto LA22;
			(*c).Spawns += 1;
			oldspawnid = (*c).Currentspawnid;
			(*c).Currentspawnid = (*c).Spawns;
			LOC24 = 0;
			LOC24 = HEX5BHEX5D_226698(value, 1);
			gatherargs_483283(c, LOC24);
			LOC25 = 0;
			LOC25 = HEX5BHEX5D_226698(value, 1);
			analysesons_484517(c, LOC25);
			LOC26 = 0;
			LOC26 = HEX5BHEX5D_226698(n, 0);
			analyse_484509(c, LOC26);
			(*c).Currentspawnid = oldspawnid;
		}
		goto LA19;
		LA22: ;
		{
			analysesons_484517(c, n);
		}
		LA19: ;
		LOC28 = 0;
		LOC28 = HEX5BHEX5D_226698(n, 0);
		LOC29 = 0;
		LOC29 = HEX5BHEX5D_226698(n, 1);
		addasgnfact_374618((&(*c).Guards), LOC28, LOC29);
	}
	break;
	case ((NU8) 27):
	case ((NU8) 29):
	case ((NU8) 30):
	case ((NU8) 31):
	case ((NU8) 26):
	case ((NU8) 28):
	case ((NU8) 32):
	{
		{
			tnode225816* LOC33;
			tnode225816* LOC36;
			LOC33 = 0;
			LOC33 = HEX5BHEX5D_226698(n, 0);
			if (!((*LOC33).Kind == ((NU8) 3))) goto LA34;
			LOC36 = 0;
			LOC36 = HEX5BHEX5D_226698(n, 0);
			analysecall_484647(c, n, (*LOC36).kindU.S4.Sym);
		}
		goto LA31;
		LA34: ;
		{
			analysesons_484517(c, n);
		}
		LA31: ;
	}
	break;
	case ((NU8) 42):
	{
		tnode225816* LOC39;
		tnode225816* LOC40;
		tnode225816* LOC41;
		LOC39 = 0;
		LOC39 = HEX5BHEX5D_226698(n, 0);
		LOC40 = 0;
		LOC40 = HEX5BHEX5D_226698(n, 1);
		LOC41 = 0;
		LOC41 = HEX5BHEX5D_226698(n, 1);
		addslice_483835(c, n, LOC39, LOC40, LOC41);
		analysesons_484517(c, n);
	}
	break;
	case ((NU8) 109):
	case ((NU8) 108):
	case ((NU8) 106):
	{
		localerror_197966((*n).Info, ((NimStringDesc*) &TMP3879));
	}
	break;
	case ((NU8) 99):
	case ((NU8) 100):
	{
		{
			tnode225816* it_485322;
			it_485322 = 0;
			{
				NI i_485583;
				NI HEX3Atmp_485585;
				NI LOC46;
				NI res_485587;
				i_485583 = 0;
				HEX3Atmp_485585 = 0;
				LOC46 = 0;
				LOC46 = len_226364(n);
				HEX3Atmp_485585 = (LOC46 - 1);
				res_485587 = 0;
				{
					while (1) {
						tnode225816* value;
						NIM_BOOL isspawned;
						NU16 LOC49;
						if (!(res_485587 <= HEX3Atmp_485585)) goto LA48;
						i_485583 = res_485587;
						it_485322 = (*n).kindU.S6.Sons->data[i_485583];
						value = lastson_226261(it_485322);
						LOC49 = 0;
						LOC49 = getmagic_261845(value);
						isspawned = (LOC49 == ((NU16) 213));
						{
							NI oldspawnid;
							tnode225816* LOC54;
							tnode225816* LOC55;
							if (!isspawned) goto LA52;
							(*c).Spawns += 1;
							oldspawnid = (*c).Currentspawnid;
							(*c).Currentspawnid = (*c).Spawns;
							LOC54 = 0;
							LOC54 = HEX5BHEX5D_226698(value, 1);
							gatherargs_483283(c, LOC54);
							LOC55 = 0;
							LOC55 = HEX5BHEX5D_226698(value, 1);
							analysesons_484517(c, LOC55);
							(*c).Currentspawnid = oldspawnid;
						}
						LA52: ;
						{
							if (!!(((*value).Kind == ((NU8) 1)))) goto LA58;
							{
								NI j_485366;
								NI HEX3Atmp_485575;
								NI LOC61;
								NI res_485578;
								j_485366 = 0;
								HEX3Atmp_485575 = 0;
								LOC61 = 0;
								LOC61 = len_226364(it_485322);
								HEX3Atmp_485575 = (NI64)(LOC61 - 3);
								res_485578 = 0;
								{
									while (1) {
										if (!(res_485578 <= HEX3Atmp_485575)) goto LA63;
										j_485366 = res_485578;
										{
											tnode225816* LOC66;
											NIM_BOOL LOC67;
											monotonicvar483024* slot;
											tnode225816* LOC70;
											LOC66 = 0;
											LOC66 = HEX5BHEX5D_226698(it_485322, j_485366);
											LOC67 = 0;
											LOC67 = islocal_483501(LOC66);
											if (!LOC67) goto LA68;
											LOC70 = 0;
											LOC70 = HEX5BHEX5D_226698(it_485322, j_485366);
											slot = getslot_483239(c, (*LOC70).kindU.S4.Sym);
											{
												if (!(*slot).Lower == 0) goto LA73;
												unsureAsgnRef((void**) (&(*slot).Lower), value);
											}
											goto LA71;
											LA73: ;
											{
												internalerror_197987((*it_485322).Info, ((NimStringDesc*) &TMP3880));
											}
											LA71: ;
										}
										LA68: ;
										res_485578 += 1;
									} LA63: ;
								}
							}
							{
								if (!!(isspawned)) goto LA78;
								analyse_484509(c, value);
							}
							LA78: ;
						}
						LA58: ;
						res_485587 += 1;
					} LA48: ;
				}
			}
		}
	}
	break;
	case ((NU8) 97):
	{
		analysecase_484738(c, n);
	}
	break;
	case ((NU8) 92):
	case ((NU8) 48):
	{
		analyseif_484911(c, n);
	}
	break;
	case ((NU8) 96):
	{
		analyse_484509(c, (*n).kindU.S6.Sons->data[0]);
		(*c).Inloop += 1;
		{
			NIM_BOOL LOC85;
			LOC85 = 0;
			LOC85 = istrue_381730((*n).kindU.S6.Sons->data[0]);
			if (!LOC85) goto LA86;
			analysesons_484517(c, (*n).kindU.S6.Sons->data[1]);
		}
		goto LA83;
		LA86: ;
		{
			NI oldstate;
			NI oldfacts;
			tnode225816* LOC89;
			oldstate = (*c).Locals->Sup.len;
			oldfacts = (*c).Guards->Sup.len;
			LOC89 = 0;
			LOC89 = canon_369513((*n).kindU.S6.Sons->data[0]);
			addfact_370349((&(*c).Guards), LOC89);
			analyse_484509(c, (*n).kindU.S6.Sons->data[1]);
			(*c).Locals = (TY483036*) setLengthSeq(&((*c).Locals)->Sup, sizeof(monotonicvar483024), oldstate);
			(*c).Guards = (tnodeseq225810*) setLengthSeq(&((*c).Guards)->Sup, sizeof(tnode225816*), oldfacts);
			{
				NIM_BOOL LOC92;
				tnode225816* LOC95;
				LOC92 = 0;
				LOC92 = hassubnodewith_226308((*n).kindU.S6.Sons->data[1], ((NU8) 110));
				if (!!(LOC92)) goto LA93;
				LOC95 = 0;
				LOC95 = canon_369513((*n).kindU.S6.Sons->data[0]);
				addfactneg_370396((&(*c).Guards), LOC95);
			}
			LA93: ;
		}
		LA83: ;
		(*c).Inloop -= 1;
	}
	break;
	case ((NU8) 98):
	case ((NU8) 79):
	case ((NU8) 81):
	case ((NU8) 80):
	case ((NU8) 84):
	case ((NU8) 82):
	case ((NU8) 83):
	case ((NU8) 101):
	case ((NU8) 90):
	{
	}
	break;
	default:
	{
		analysesons_484517(c, n);
	}
	break;
	}
}

N_NIMCALL(void, overlap_483899)(tnodeseq225810* m, tnode225816* x, tnode225816* y, tnode225816* c, tnode225816* d) {
	NU8 LOC1;
	LOC1 = 0;
	LOC1 = provele_373995(m, x, d);
	switch (LOC1) {
	case ((NU8) 0):
	{
		TY483908 LOC3;
		NimStringDesc* LOC4;
		memset((void*)LOC3, 0, sizeof(LOC3));
		LOC3[0] = rendertree_250058(x, 0);
		LOC3[1] = rendertree_250058(d, 0);
		LOC3[2] = rendertree_250058(x, 0);
		LOC3[3] = rendertree_250058(y, 0);
		LOC3[4] = rendertree_250058(c, 0);
		LOC3[5] = rendertree_250058(d, 0);
		LOC4 = 0;
		LOC4 = nsuFormatOpenArray(((NimStringDesc*) &TMP3882), LOC3, 6);
		localerror_197966((*x).Info, LOC4);
	}
	break;
	case ((NU8) 2):
	{
		NU8 LOC6;
		LOC6 = 0;
		LOC6 = provele_373995(m, c, y);
		switch (LOC6) {
		case ((NU8) 0):
		{
			TY483908 LOC8;
			NimStringDesc* LOC9;
			memset((void*)LOC8, 0, sizeof(LOC8));
			LOC8[0] = rendertree_250058(c, 0);
			LOC8[1] = rendertree_250058(y, 0);
			LOC8[2] = rendertree_250058(x, 0);
			LOC8[3] = rendertree_250058(y, 0);
			LOC8[4] = rendertree_250058(c, 0);
			LOC8[5] = rendertree_250058(d, 0);
			LOC9 = 0;
			LOC9 = nsuFormatOpenArray(((NimStringDesc*) &TMP3882), LOC8, 6);
			localerror_197966((*x).Info, LOC9);
		}
		break;
		case ((NU8) 2):
		{
			TY197620 LOC11;
			NimStringDesc* LOC12;
			memset((void*)LOC11, 0, sizeof(LOC11));
			LOC11[0] = rendertree_250058(x, 0);
			LOC11[1] = rendertree_250058(y, 0);
			LOC11[2] = rendertree_250058(c, 0);
			LOC11[3] = rendertree_250058(d, 0);
			LOC12 = 0;
			LOC12 = nsuFormatOpenArray(((NimStringDesc*) &TMP3883), LOC11, 4);
			localerror_197966((*x).Info, LOC12);
		}
		break;
		case ((NU8) 1):
		{
		}
		break;
		}
	}
	break;
	case ((NU8) 1):
	{
	}
	break;
	}
}

N_NIMCALL(tnode225816*, substride_484044)(analysisctx483026* c, tnode225816* n) {
	tnode225816* result;
	result = 0;
	{
		NIM_BOOL LOC3;
		NI s;
		LOC3 = 0;
		LOC3 = islocal_483501(n);
		if (!LOC3) goto LA4;
		s = lookupslot_483148(c, (*n).kindU.S4.Sym);
		{
			NIM_BOOL LOC8;
			LOC8 = 0;
			LOC8 = (0 <= s);
			if (!(LOC8)) goto LA9;
			LOC8 = !(((*c).Locals->data[s].Stride == NIM_NIL));
			LA9: ;
			if (!LOC8) goto LA10;
			result = HEX2BHEX40_369779(n, (*(*c).Locals->data[s].Stride).kindU.S1.Intval);
		}
		goto LA6;
		LA10: ;
		{
			result = n;
		}
		LA6: ;
	}
	goto LA1;
	LA4: ;
	{
		NI LOC14;
		LOC14 = 0;
		LOC14 = safelen_226424(n);
		if (!(0 < LOC14)) goto LA15;
		result = shallowcopy_231347(n);
		{
			NI i_484118;
			NI HEX3Atmp_484148;
			NI LOC18;
			NI res_484151;
			i_484118 = 0;
			HEX3Atmp_484148 = 0;
			LOC18 = 0;
			LOC18 = len_226364(n);
			HEX3Atmp_484148 = (LOC18 - 1);
			res_484151 = 0;
			{
				while (1) {
					if (!(res_484151 <= HEX3Atmp_484148)) goto LA20;
					i_484118 = res_484151;
					asgnRefNoCycle((void**) (&(*result).kindU.S6.Sons->data[i_484118]), substride_484044(c, (*n).kindU.S6.Sons->data[i_484118]));
					res_484151 += 1;
				} LA20: ;
			}
		}
	}
	goto LA1;
	LA15: ;
	{
		result = n;
	}
	LA1: ;
	return result;
}

N_NIMCALL(NI64, stride_483924)(analysisctx483026* c, tnode225816* n) {
	NI64 result;
	result = 0;
	{
		NIM_BOOL LOC3;
		NI s;
		LOC3 = 0;
		LOC3 = islocal_483501(n);
		if (!LOC3) goto LA4;
		s = lookupslot_483148(c, (*n).kindU.S4.Sym);
		{
			NIM_BOOL LOC8;
			LOC8 = 0;
			LOC8 = (0 <= s);
			if (!(LOC8)) goto LA9;
			LOC8 = !(((*c).Locals->data[s].Stride == NIM_NIL));
			LA9: ;
			if (!LOC8) goto LA10;
			result = (*(*c).Locals->data[s].Stride).kindU.S1.Intval;
		}
		LA10: ;
	}
	goto LA1;
	LA4: ;
	{
		{
			NI i_483996;
			NI HEX3Atmp_484024;
			NI LOC14;
			NI res_484027;
			i_483996 = 0;
			HEX3Atmp_484024 = 0;
			LOC14 = 0;
			LOC14 = safelen_226424(n);
			HEX3Atmp_484024 = (LOC14 - 1);
			res_484027 = 0;
			{
				while (1) {
					NI64 LOC17;
					if (!(res_484027 <= HEX3Atmp_484024)) goto LA16;
					i_483996 = res_484027;
					LOC17 = 0;
					LOC17 = stride_483924(c, (*n).kindU.S6.Sons->data[i_483996]);
					result += LOC17;
					res_484027 += 1;
				} LA16: ;
			}
		}
	}
	LA1: ;
	return result;
}

N_NIMCALL(void, checkslicesaredisjoint_484168)(analysisctx483026* c) {
	addlowerboundasfacts_483708(c);
	{
		tnode225816* x_484411;
		tnode225816* a_484412;
		tnode225816* b_484413;
		NI id_484414;
		NIM_BOOL inloop_484415;
		TY483038* HEX3Atmp_484457;
		NI i_484460;
		NI l_484462;
		x_484411 = 0;
		a_484412 = 0;
		b_484413 = 0;
		id_484414 = 0;
		inloop_484415 = 0;
		HEX3Atmp_484457 = 0;
		HEX3Atmp_484457 = (*c).Slices;
		i_484460 = 0;
		l_484462 = HEX3Atmp_484457->Sup.len;
		{
			while (1) {
				if (!(i_484460 < l_484462)) goto LA3;
				x_484411 = HEX3Atmp_484457->data[i_484460].Field0;
				a_484412 = HEX3Atmp_484457->data[i_484460].Field1;
				b_484413 = HEX3Atmp_484457->data[i_484460].Field2;
				id_484414 = HEX3Atmp_484457->data[i_484460].Field3;
				inloop_484415 = HEX3Atmp_484457->data[i_484460].Field4;
				{
					tnode225816* LOC8;
					tnode225816* LOC9;
					if (!inloop_484415) goto LA6;
					LOC8 = 0;
					LOC8 = substride_484044((&(*c)), a_484412);
					LOC9 = 0;
					LOC9 = substride_484044((&(*c)), b_484413);
					overlap_483899((*c).Guards, a_484412, b_484413, LOC8, LOC9);
				}
				LA6: ;
				i_484460 += 1;
			} LA3: ;
		}
	}
	{
		NI i_484426;
		NI HEX3Atmp_484471;
		NI res_484474;
		i_484426 = 0;
		HEX3Atmp_484471 = 0;
		HEX3Atmp_484471 = ((*c).Slices->Sup.len-1);
		res_484474 = 0;
		{
			while (1) {
				if (!(res_484474 <= HEX3Atmp_484471)) goto LA12;
				i_484426 = res_484474;
				{
					NI j_484437;
					NI HEX3Atmp_484465;
					NI HEX3Atmp_484466;
					NI res_484469;
					j_484437 = 0;
					HEX3Atmp_484465 = 0;
					HEX3Atmp_484466 = 0;
					HEX3Atmp_484465 = (NI64)(i_484426 + 1);
					HEX3Atmp_484466 = ((*c).Slices->Sup.len-1);
					res_484469 = HEX3Atmp_484465;
					{
						while (1) {
							TY483039 x;
							TY483039 y;
							if (!(res_484469 <= HEX3Atmp_484466)) goto LA15;
							j_484437 = res_484469;
							memset((void*)(&x), 0, sizeof(x));
							memcpy((void*)(&x), (NIM_CONST void*)(&(*c).Slices->data[i_484426]), sizeof(x));
							memset((void*)(&y), 0, sizeof(y));
							memcpy((void*)(&y), (NIM_CONST void*)(&(*c).Slices->data[j_484437]), sizeof(y));
							{
								NIM_BOOL LOC18;
								LOC18 = 0;
								LOC18 = !((x.Field3 == y.Field3));
								if (!(LOC18)) goto LA19;
								LOC18 = sametree_370425(x.Field0, y.Field0);
								LA19: ;
								if (!LOC18) goto LA20;
								{
									NIM_BOOL LOC24;
									LOC24 = 0;
									LOC24 = !(x.Field4);
									if (LOC24) goto LA25;
									LOC24 = !(y.Field4);
									LA25: ;
									if (!LOC24) goto LA26;
									overlap_483899((*c).Guards, x.Field1, x.Field2, y.Field1, y.Field2);
								}
								goto LA22;
								LA26: ;
								{
									NI64 k;
									NI64 m;
									NIM_BOOL LOC29;
									NI64 stride;
									NI64 LOC33;
									NI64 LOC34;
									k = simpleslice_373066(x.Field1, x.Field2);
									m = simpleslice_373066(y.Field1, y.Field2);
									LOC29 = 0;
									LOC29 = (IL64(0) <= k);
									if (!(LOC29)) goto LA30;
									LOC29 = (IL64(0) <= m);
									LA30: ;
									if (!LOC29) goto LA31;
									overlap_483899((*c).Guards, x.Field1, x.Field2, y.Field1, y.Field2);
									LOC33 = 0;
									LOC33 = stride_483924((&(*c)), x.Field1);
									LOC34 = 0;
									LOC34 = stride_483924((&(*c)), y.Field1);
									stride = ((LOC33 <= LOC34) ? LOC33 : LOC34);
									{
										NIM_BOOL LOC37;
										LOC37 = 0;
										LOC37 = (k < stride);
										if (!(LOC37)) goto LA38;
										LOC37 = (m < stride);
										LA38: ;
										if (!LOC37) goto LA39;
									}
									goto LA35;
									LA39: ;
									{
										TY197620 LOC42;
										NimStringDesc* LOC43;
										memset((void*)LOC42, 0, sizeof(LOC42));
										LOC42[0] = rendertree_250058(x.Field1, 0);
										LOC42[1] = rendertree_250058(x.Field2, 0);
										LOC42[2] = rendertree_250058(y.Field1, 0);
										LOC42[3] = rendertree_250058(y.Field2, 0);
										LOC43 = 0;
										LOC43 = nsuFormatOpenArray(((NimStringDesc*) &TMP3884), LOC42, 4);
										localerror_197966((*x.Field0).Info, LOC43);
									}
									LA35: ;
								}
								goto LA22;
								LA31: ;
								{
									TY197620 LOC45;
									NimStringDesc* LOC46;
									memset((void*)LOC45, 0, sizeof(LOC45));
									LOC45[0] = rendertree_250058(x.Field1, 0);
									LOC45[1] = rendertree_250058(x.Field2, 0);
									LOC45[2] = rendertree_250058(y.Field1, 0);
									LOC45[3] = rendertree_250058(y.Field2, 0);
									LOC46 = 0;
									LOC46 = nsuFormatOpenArray(((NimStringDesc*) &TMP3884), LOC45, 4);
									localerror_197966((*x.Field0).Info, LOC46);
								}
								LA22: ;
							}
							LA20: ;
							res_484469 += 1;
						} LA15: ;
					}
				}
				res_484474 += 1;
			} LA12: ;
		}
	}
}

N_NIMCALL(void, checkargs_485951)(analysisctx483026* a, tnode225816* n) {
}

N_NIMCALL(void, generatealiaschecks_485962)(analysisctx483026* a, tnode225816* result) {
}

N_NIMCALL(tnode225816*, transformslices_485615)(tnode225816* n) {
	tnode225816* result;
	result = 0;
	{
		NIM_BOOL LOC3;
		tnode225816* LOC5;
		tsym225846* op;
		tnode225816* LOC8;
		LOC3 = 0;
		LOC3 = ((*n).Kind == ((NU8) 27) || (*n).Kind == ((NU8) 29) || (*n).Kind == ((NU8) 30) || (*n).Kind == ((NU8) 31) || (*n).Kind == ((NU8) 26) || (*n).Kind == ((NU8) 28) || (*n).Kind == ((NU8) 32));
		if (!(LOC3)) goto LA4;
		LOC5 = 0;
		LOC5 = HEX5BHEX5D_226698(n, 0);
		LOC3 = ((*LOC5).Kind == ((NU8) 3));
		LA4: ;
		if (!LOC3) goto LA6;
		LOC8 = 0;
		LOC8 = HEX5BHEX5D_226698(n, 0);
		op = (*LOC8).kindU.S4.Sym;
		{
			NIM_BOOL LOC11;
			tnode225816* LOC15;
			tnode225816* LOC16;
			tnode225816* LOC17;
			tnode225816* LOC18;
			tnode225816* LOC19;
			tnode225816* LOC20;
			LOC11 = 0;
			LOC11 = eqStrings((*(*op).Name).S, ((NimStringDesc*) &TMP3868));
			if (!(LOC11)) goto LA12;
			LOC11 = fromsystem_484616(op);
			LA12: ;
			if (!LOC11) goto LA13;
			result = copynode_226323(n);
			LOC15 = 0;
			LOC15 = newsymnode_226132(opslice_483055);
			add_226498(result, LOC15);
			LOC16 = 0;
			LOC16 = HEX5BHEX5D_226698(n, 1);
			add_226498(result, LOC16);
			LOC17 = 0;
			LOC17 = HEX5BHEX5D_226698(n, 2);
			LOC18 = 0;
			LOC18 = HEX5BHEX5D_226698(LOC17, 1);
			add_226498(result, LOC18);
			LOC19 = 0;
			LOC19 = HEX5BHEX5D_226698(n, 2);
			LOC20 = 0;
			LOC20 = HEX5BHEX5D_226698(LOC19, 2);
			add_226498(result, LOC20);
			goto BeforeRet;
		}
		LA13: ;
	}
	LA6: ;
	{
		NI LOC23;
		LOC23 = 0;
		LOC23 = safelen_226424(n);
		if (!(0 < LOC23)) goto LA24;
		result = shallowcopy_231347(n);
		{
			NI i_485679;
			NI HEX3Atmp_485709;
			NI LOC27;
			NI res_485712;
			i_485679 = 0;
			HEX3Atmp_485709 = 0;
			LOC27 = 0;
			LOC27 = len_226364(n);
			HEX3Atmp_485709 = (LOC27 - 1);
			res_485712 = 0;
			{
				while (1) {
					if (!(res_485712 <= HEX3Atmp_485709)) goto LA29;
					i_485679 = res_485712;
					asgnRefNoCycle((void**) (&(*result).kindU.S6.Sons->data[i_485679]), transformslices_485615((*n).kindU.S6.Sons->data[i_485679]));
					res_485712 += 1;
				} LA29: ;
			}
		}
	}
	goto LA21;
	LA24: ;
	{
		result = n;
	}
	LA21: ;
	BeforeRet: ;
	return result;
}

N_NIMCALL(tnode225816*, transformspawnsons_485737)(tsym225846* owner, tnode225816* n, tnode225816* barrier) {
	tnode225816* result;
	result = 0;
	result = shallowcopy_231347(n);
	{
		NI i_485765;
		NI HEX3Atmp_485795;
		NI LOC2;
		NI res_485798;
		i_485765 = 0;
		HEX3Atmp_485795 = 0;
		LOC2 = 0;
		LOC2 = len_226364(n);
		HEX3Atmp_485795 = (LOC2 - 1);
		res_485798 = 0;
		{
			while (1) {
				if (!(res_485798 <= HEX3Atmp_485795)) goto LA4;
				i_485765 = res_485798;
				asgnRefNoCycle((void**) (&(*result).kindU.S6.Sons->data[i_485765]), transformspawn_485729(owner, (*n).kindU.S6.Sons->data[i_485765], barrier));
				res_485798 += 1;
			} LA4: ;
		}
	}
	return result;
}

N_NIMCALL(tnode225816*, transformspawn_485729)(tsym225846* owner, tnode225816* n, tnode225816* barrier) {
	tnode225816* result;
	result = 0;
	switch ((*n).Kind) {
	case ((NU8) 99):
	case ((NU8) 100):
	{
		result = NIM_NIL;
		{
			tnode225816* it_485821;
			it_485821 = 0;
			{
				NI i_485928;
				NI HEX3Atmp_485930;
				NI LOC4;
				NI res_485932;
				i_485928 = 0;
				HEX3Atmp_485930 = 0;
				LOC4 = 0;
				LOC4 = len_226364(n);
				HEX3Atmp_485930 = (LOC4 - 1);
				res_485932 = 0;
				{
					while (1) {
						tnode225816* b;
						if (!(res_485932 <= HEX3Atmp_485930)) goto LA6;
						i_485928 = res_485932;
						it_485821 = (*n).kindU.S6.Sons->data[i_485928];
						b = lastson_226261(it_485821);
						{
							NU16 LOC9;
							tnode225816* m;
							ttype225852* t;
							tnode225816* LOC21;
							tnode225816* LOC22;
							LOC9 = 0;
							LOC9 = getmagic_261845(b);
							if (!(LOC9 == ((NU16) 213))) goto LA10;
							{
								NI LOC14;
								LOC14 = 0;
								LOC14 = len_226364(it_485821);
								if (!!((LOC14 == 3))) goto LA15;
								localerror_197966((*it_485821).Info, ((NimStringDesc*) &TMP3888));
							}
							LA15: ;
							m = transformslices_485615(b);
							{
								if (!result == 0) goto LA19;
								result = newnodei_226138(((NU8) 115), (*n).Info);
								add_226498(result, n);
							}
							LA19: ;
							LOC21 = 0;
							LOC21 = HEX5BHEX5D_226698(b, 1);
							LOC22 = 0;
							LOC22 = HEX5BHEX5D_226698(LOC21, 0);
							t = (*(*LOC22).Typ).Sons->data[0];
							{
								NU8 LOC25;
								tnode225816* LOC28;
								tnode225816* LOC29;
								NI LOC30;
								LOC25 = 0;
								LOC25 = spawnresult_425994(t, NIM_TRUE);
								if (!(LOC25 == ((NU8) 2))) goto LA26;
								LOC28 = 0;
								LOC28 = HEX5BHEX5D_226698(it_485821, 0);
								LOC29 = 0;
								LOC29 = wrapprocforspawn_426897(owner, m, (*b).Typ, barrier, LOC28);
								add_226498(result, LOC29);
								LOC30 = 0;
								LOC30 = len_226364(it_485821);
								asgnRefNoCycle((void**) (&(*it_485821).kindU.S6.Sons->data[(NI64)(LOC30 - 1)]), emptynode_226738);
							}
							goto LA23;
							LA26: ;
							{
								NI LOC32;
								LOC32 = 0;
								LOC32 = len_226364(it_485821);
								asgnRefNoCycle((void**) (&(*it_485821).kindU.S6.Sons->data[(NI64)(LOC32 - 1)]), wrapprocforspawn_426897(owner, m, (*b).Typ, barrier, NIM_NIL));
							}
							LA23: ;
						}
						LA10: ;
						res_485932 += 1;
					} LA6: ;
				}
			}
		}
		{
			if (!result == 0) goto LA35;
			result = n;
		}
		LA35: ;
	}
	break;
	case ((NU8) 73):
	case ((NU8) 74):
	{
		tnode225816* b;
		b = HEX5BHEX5D_226698(n, 1);
		{
			NIM_BOOL LOC40;
			NU16 LOC41;
			ttype225852* t;
			tnode225816* LOC43;
			tnode225816* LOC44;
			NU8 LOC45;
			tnode225816* m;
			tnode225816* LOC48;
			LOC40 = 0;
			LOC41 = 0;
			LOC41 = getmagic_261845(b);
			LOC40 = (LOC41 == ((NU16) 213));
			if (!(LOC40)) goto LA42;
			LOC43 = 0;
			LOC43 = HEX5BHEX5D_226698(b, 1);
			LOC44 = 0;
			LOC44 = HEX5BHEX5D_226698(LOC43, 0);
			t = (*(*LOC44).Typ).Sons->data[0];
			LOC45 = 0;
			LOC45 = spawnresult_425994(t, NIM_TRUE);
			LOC40 = (LOC45 == ((NU8) 2));
			LA42: ;
			if (!LOC40) goto LA46;
			m = transformslices_485615(b);
			LOC48 = 0;
			LOC48 = HEX5BHEX5D_226698(n, 0);
			result = wrapprocforspawn_426897(owner, m, (*b).Typ, barrier, LOC48);
			goto BeforeRet;
		}
		LA46: ;
		result = transformspawnsons_485737(owner, n, barrier);
	}
	break;
	case ((NU8) 27):
	case ((NU8) 29):
	case ((NU8) 30):
	case ((NU8) 31):
	case ((NU8) 26):
	case ((NU8) 28):
	case ((NU8) 32):
	{
		{
			NU16 LOC52;
			LOC52 = 0;
			LOC52 = getmagic_261845(n);
			if (!(LOC52 == ((NU16) 213))) goto LA53;
			result = transformslices_485615(n);
			result = wrapprocforspawn_426897(owner, result, (*n).Typ, barrier, NIM_NIL);
			goto BeforeRet;
		}
		LA53: ;
		result = transformspawnsons_485737(owner, n, barrier);
	}
	break;
	default:
	{
		{
			NI LOC58;
			LOC58 = 0;
			LOC58 = safelen_226424(n);
			if (!(0 < LOC58)) goto LA59;
			result = transformspawnsons_485737(owner, n, barrier);
		}
		goto LA56;
		LA59: ;
		{
			result = n;
		}
		LA56: ;
	}
	break;
	}
	BeforeRet: ;
	return result;
}

N_NIMCALL(tnode225816*, liftparallel_485972)(tsym225846* owner, tnode225816* n) {
	tnode225816* result;
	analysisctx483026 a;
	tnode225816* body;
	tnode225816* varsection;
	tsym225846* temp;
	tident200021* LOC5;
	tsym225846* LOC6;
	tnode225816* tempnode;
	tnode225816* barrier;
	tnode225816* LOC7;
	tnode225816* LOC8;
	tnode225816* LOC9;
	result = 0;
	memset((void*)(&a), 0, sizeof(a));
	chckNil((void*)(&a));
	memset((void*)(&a), 0, sizeof(a));
	initanalysisctx_483059((&a));
	body = lastson_226261(n);
	analyse_484509((&a), body);
	{
		if (!(a.Spawns == 0)) goto LA3;
		localerror_197966((*n).Info, ((NimStringDesc*) &TMP3881));
	}
	LA3: ;
	checkslicesaredisjoint_484168((&a));
	checkargs_485951((&a), body);
	varsection = newnodei_226138(((NU8) 99), (*n).Info);
	LOC5 = 0;
	LOC5 = getident_200472(((NimStringDesc*) &TMP3885));
	temp = newsym_226074(((NU8) 5), LOC5, owner, (*n).Info);
	LOC6 = 0;
	LOC6 = getcompilerproc_282036(((NimStringDesc*) &TMP3886));
	asgnRefNoCycle((void**) (&(*temp).Typ), (*LOC6).Typ);
	(*temp).Flags |= ((NI32)1)<<((((NU8) 2))%(sizeof(NI32)*8));
	tempnode = newsymnode_226132(temp);
	addvar_424053(varsection, tempnode);
	barrier = genaddrof_425872(tempnode);
	result = newnodei_226138(((NU8) 115), (*n).Info);
	generatealiaschecks_485962((&a), result);
	add_226498(result, varsection);
	LOC7 = 0;
	LOC7 = callcodegenproc_425906(((NimStringDesc*) &TMP3887), barrier, NIM_NIL, NIM_NIL);
	add_226498(result, LOC7);
	LOC8 = 0;
	LOC8 = transformspawn_485729(owner, body, barrier);
	add_226498(result, LOC8);
	LOC9 = 0;
	LOC9 = callcodegenproc_425906(((NimStringDesc*) &TMP3889), barrier, NIM_NIL, NIM_NIL);
	add_226498(result, LOC9);
	return result;
}
NIM_EXTERNC N_NOINLINE(void, HEX00_semparallelInit)(void) {
	asgnRefNoCycle((void**) (&opslice_483055), createmagic_368405(((NimStringDesc*) &TMP952), ((NU16) 151)));
}

NIM_EXTERNC N_NOINLINE(void, HEX00_semparallelDatInit)(void) {
static TNimNode* TMP3860[7];
static TNimNode* TMP3861[2];
NI TMP3863;
static char* NIM_CONST TMP3862[2] = {
"ascending", 
"descending"};
static TNimNode* TMP3865[5];
static TNimNode TMP950[17];
NTI483024.size = sizeof(monotonicvar483024);
NTI483024.kind = 18;
NTI483024.base = 0;
NTI483024.flags = 2;
TMP3860[0] = &TMP950[1];
TMP950[1].kind = 1;
TMP950[1].offset = offsetof(monotonicvar483024, V);
TMP950[1].typ = (&NTI225814);
TMP950[1].name = "v";
TMP3860[1] = &TMP950[2];
TMP950[2].kind = 1;
TMP950[2].offset = offsetof(monotonicvar483024, Alias);
TMP950[2].typ = (&NTI225814);
TMP950[2].name = "alias";
TMP3860[2] = &TMP950[3];
TMP950[3].kind = 1;
TMP950[3].offset = offsetof(monotonicvar483024, Lower);
TMP950[3].typ = (&NTI225808);
TMP950[3].name = "lower";
TMP3860[3] = &TMP950[4];
TMP950[4].kind = 1;
TMP950[4].offset = offsetof(monotonicvar483024, Upper);
TMP950[4].typ = (&NTI225808);
TMP950[4].name = "upper";
TMP3860[4] = &TMP950[5];
TMP950[5].kind = 1;
TMP950[5].offset = offsetof(monotonicvar483024, Stride);
TMP950[5].typ = (&NTI225808);
TMP950[5].name = "stride";
TMP3860[5] = &TMP950[6];
NTI483022.size = sizeof(NU8);
NTI483022.kind = 14;
NTI483022.base = 0;
NTI483022.flags = 3;
for (TMP3863 = 0; TMP3863 < 2; TMP3863++) {
TMP950[TMP3863+7].kind = 1;
TMP950[TMP3863+7].offset = TMP3863;
TMP950[TMP3863+7].name = TMP3862[TMP3863];
TMP3861[TMP3863] = &TMP950[TMP3863+7];
}
TMP950[9].len = 2; TMP950[9].kind = 2; TMP950[9].sons = &TMP3861[0];
NTI483022.node = &TMP950[9];
TMP950[6].kind = 1;
TMP950[6].offset = offsetof(monotonicvar483024, Dir);
TMP950[6].typ = (&NTI483022);
TMP950[6].name = "dir";
TMP3860[6] = &TMP950[10];
TMP950[10].kind = 1;
TMP950[10].offset = offsetof(monotonicvar483024, Blacklisted);
TMP950[10].typ = (&NTI138);
TMP950[10].name = "blacklisted";
TMP950[0].len = 7; TMP950[0].kind = 2; TMP950[0].sons = &TMP3860[0];
NTI483024.node = &TMP950[0];
NTI483036.size = sizeof(TY483036*);
NTI483036.kind = 24;
NTI483036.base = (&NTI483024);
NTI483036.flags = 2;
NTI483036.marker = TMP3864;
NTI483039.size = sizeof(TY483039);
NTI483039.kind = 18;
NTI483039.base = 0;
NTI483039.flags = 2;
TMP3865[0] = &TMP950[12];
TMP950[12].kind = 1;
TMP950[12].offset = offsetof(TY483039, Field0);
TMP950[12].typ = (&NTI225808);
TMP950[12].name = "Field0";
TMP3865[1] = &TMP950[13];
TMP950[13].kind = 1;
TMP950[13].offset = offsetof(TY483039, Field1);
TMP950[13].typ = (&NTI225808);
TMP950[13].name = "Field1";
TMP3865[2] = &TMP950[14];
TMP950[14].kind = 1;
TMP950[14].offset = offsetof(TY483039, Field2);
TMP950[14].typ = (&NTI225808);
TMP950[14].name = "Field2";
TMP3865[3] = &TMP950[15];
TMP950[15].kind = 1;
TMP950[15].offset = offsetof(TY483039, Field3);
TMP950[15].typ = (&NTI108);
TMP950[15].name = "Field3";
TMP3865[4] = &TMP950[16];
TMP950[16].kind = 1;
TMP950[16].offset = offsetof(TY483039, Field4);
TMP950[16].typ = (&NTI138);
TMP950[16].name = "Field4";
TMP950[11].len = 5; TMP950[11].kind = 2; TMP950[11].sons = &TMP3865[0];
NTI483039.node = &TMP950[11];
NTI483038.size = sizeof(TY483038*);
NTI483038.kind = 24;
NTI483038.base = (&NTI483039);
NTI483038.flags = 2;
NTI483038.marker = TMP3866;
}

