/* Generated by Nim Compiler v2.2.10 */
/* Compiled for: Linux, amd64, gcc */
/* Command for C compiler:
   gcc -c  -w -fmax-errors=3 -fno-strict-aliasing -pthread -O3 -fno-ident -fno-math-errno   -I/home/runner/work/nightlies/nightlies/nim-2.2.10/lib -I/home/runner/work/nightlies/nightlies/nim-2.2.10/dist/atlas/src -o /home/runner/work/nightlies/nightlies/nim-2.2.10/dist/atlas/.nimcache/@pposix.nim.c.o /home/runner/work/nightlies/nightlies/nim-2.2.10/dist/atlas/.nimcache/@pposix.nim.c */
#define NIM_INTBITS 64

#include "nimbase.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
N_LIB_PRIVATE N_NOINLINE(void, raiseOverflow)(void);
N_LIB_PRIVATE N_NIMCALL(int, WTERMSIG__posixZposix_u1070)(int s_p0);
static N_INLINE(NIM_BOOL*, nimErrorFlag)(void);
extern NIM_THREADVAR NIM_BOOL nimInErrorMode__system_u4216;
N_LIB_PRIVATE N_NIMCALL(NIM_BOOL, WIFSIGNALED__posixZposix_u1079)(int s_p0) {
	NIM_BOOL result;
	NI TM__mJPr4mHlDfNAl9asG6X7NFA_2;
{	result = (NIM_BOOL)0;
	if (nimAddInt((NI32)(s_p0 & ((NI32)127)), ((NI32)1), &TM__mJPr4mHlDfNAl9asG6X7NFA_2)) { raiseOverflow(); goto BeforeRet_;
	};
	if (TM__mJPr4mHlDfNAl9asG6X7NFA_2 < (-2147483647 -1) || TM__mJPr4mHlDfNAl9asG6X7NFA_2 > 2147483647){ raiseOverflow(); goto BeforeRet_;
	}
	result = (((NI8)0) < (NI8)((NI64)(((NI8) ((NI32)(TM__mJPr4mHlDfNAl9asG6X7NFA_2)))) >> (NU64)(((NI)1) & (8 - 1))));
	}BeforeRet_: ;
	return result;
}
N_LIB_PRIVATE N_NIMCALL(int, WTERMSIG__posixZposix_u1070)(int s_p0) {
	int result;
	result = (NI32)(s_p0 & ((NI32)127));
	return result;
}
N_LIB_PRIVATE N_NIMCALL(int, WEXITSTATUS__posixZposix_u1063)(int s_p0) {
	int result;
	result = (NI32)((NI64)((NI32)(s_p0 & ((NI32)65280))) >> (NU64)(((NI)8) & (32 - 1)));
	return result;
}
static N_INLINE(NIM_BOOL*, nimErrorFlag)(void) {
	NIM_BOOL* result;
	result = (&nimInErrorMode__system_u4216);
	return result;
}
N_LIB_PRIVATE N_NIMCALL(NIM_BOOL, WIFEXITED__posixZposix_u1076)(int s_p0) {
	NIM_BOOL result;
	int T1_;
NIM_BOOL* nimErr_;
{nimErr_ = nimErrorFlag();
	result = (NIM_BOOL)0;
	T1_ = (int)0;
	T1_ = WTERMSIG__posixZposix_u1070(s_p0);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	result = (T1_ == ((NI32)0));
	}BeforeRet_: ;
	return result;
}
