Product: GCC Component: rtl-optimization Version: 7.3.0
After we enable the schedule DO_PREDICATION, we get wrong scheduling result in sched2 pass. The key dump is shown as following: .......(Unimportant things) ;; | 93 | 15 | a20=sxn([a19]) ;; | 94 | 10 | t2=a20==0 ;; | 95 | 9 | pc={(t2!=0)?L107:pc} jump_insn1 ;; | 159 | 10 | a21=0xffffffffffff8000 ;; | 98 | 9 | t0=a23!=a21 ;; | 99 | 8 | pc={(t0==0)?L173:pc} jump_insn2 ;; | 105 | 7 | a22=a23/a20 div_insn ;; | 106 | 1 | a23=sxn(a22) .......(Unimportant things) ;; --- EBB Dependences --- from bb4 to bb6 ;; insn code bb dep prio cost reservation .......(Unimportant things) ;; 93 94 4 4 15 1 : 105(t,1) 99(a,0) 94(t,5) ;; 94 1645 4 1 10 1 : 106(t,1) 95(t,1) ;; 95 139 4 13 9 1 : 106(c,1) 99(a,1)nm ;; 159 129 5 0 10 1 : 98(t,1) ;; 98 1650 5 2 9 1 : 105(t,1) 106(t,1)m 99(t,1) ;; 99 139 5 15 8 1 : 105(c,1) 106(c,1) ;; 105 37 6 4 7 1 : 106(t,6)m ;; 106 94 6 6 1 1 : .......(Unimportant things) When we enable the schedule DO_PREDICATION, we can produce conditional execution insn. Since insn 98(t0=a23!=a21) doesn't have dependence with jump_insn1 95 (pc={(t2!=0)?L107:pc}), so insn 98 can issue before jump_insn1 95. And insn 93 (a20=sxn([a19])) can also issue before jump_insn1 95. After that, insn 105(a22=a23/a20) can become conditional execution insn shown as following dump: ;; 51--> 93 a20=sxn([a19]) : rescanning insn with uid = 105. ;; dependencies resolved: insn 105 predicated ;; Ready-->Q: insn 105: queued for 1 cycles (change queue index). ;; tick updated: insn 105 into queue with cost=1 After predicating, insn 105 have become : [t0]a22=a23/a20 ;; 52--> 105 (t0) a22=a23/a20 : ;; Ready list (t = 52): .......(Unimportant things) ;; Ready list (t = 56): 94:50:prio=10 [52;56]:94 ;; 56--> 94 t2=a20==0 : .......(Unimportant things) ;; Ready list (t = 57): 95:51:prio=9 [56;57]:95 ;; 57--> 95 pc={(t2!=0)?L107:pc} : finally, insn 105([t0]a22=a23/a20) is issued before insn 95 (pc={(t2!=0)?L107:pc}). However, insn 95 has decided reg a20 is valid not. In this case, a20 is 0, so we get division by 0 error. The scheduling result is shown as the following: tstneq@ags t0, a23, a21 # [28] # 98 .... l16si@agl a20, a19, 0 # [51] # 93 .... [t0] quos@sau a22, a23, a20 # [52] # 105 tsteqi@sau t2, a20, 0 # [53] # 94 [t2] b@pcu .L5, 1 # [54] # 95 [!t0] b@pcu .L28, 0 # [55] # 99 ...... Insn 105 (div_insn)should not be issued before insn 95(jump_insn1). Note: This ebb is 3 basic-blocks. Since supporting DO_PREDICATION target is little, it's difficult to recurrent in other target. How can we solve the problem? Best wishes!
typedef long int ptrdiff_t; typedef long unsigned int size_t; typedef short unsigned int wchar_t; typedef struct { long long __max_align_ll __attribute__((__aligned__(__alignof__(long long)))); long double __max_align_ld __attribute__((__aligned__(__alignof__(long double)))); } max_align_t; typedef signed char __int8_t; typedef unsigned char __uint8_t; typedef short int __int16_t; typedef short unsigned int __uint16_t; typedef int __int32_t; typedef unsigned int __uint32_t; typedef long int __int64_t; typedef long unsigned int __uint64_t; typedef signed char __int_least8_t; typedef unsigned char __uint_least8_t; typedef short int __int_least16_t; typedef short unsigned int __uint_least16_t; typedef int __int_least32_t; typedef unsigned int __uint_least32_t; typedef long int __int_least64_t; typedef long unsigned int __uint_least64_t; typedef long int __intmax_t; typedef long unsigned int __uintmax_t; typedef long int __intptr_t; typedef long unsigned int __uintptr_t; typedef int _LOCK_T; typedef int _LOCK_RECURSIVE_T; typedef long __blkcnt_t; typedef long __blksize_t; typedef __uint64_t __fsblkcnt_t; typedef __uint32_t __fsfilcnt_t; typedef long _off_t; typedef int __pid_t; typedef short __dev_t; typedef unsigned short __uid_t; typedef unsigned short __gid_t; typedef __uint32_t __id_t; typedef unsigned short __ino_t; typedef __uint32_t __mode_t; __extension__ typedef long long _off64_t; typedef _off_t __off_t; typedef _off64_t __loff_t; typedef long __key_t; typedef long _fpos_t; typedef long unsigned int __size_t; typedef long signed int _ssize_t; typedef _ssize_t __ssize_t; typedef unsigned int wint_t; typedef struct { int __count; union { wint_t __wch; unsigned char __wchb[4]; } __value; } _mbstate_t; typedef _LOCK_RECURSIVE_T _flock_t; typedef void *_iconv_t; typedef unsigned long __clock_t; typedef long __time_t; typedef unsigned long __clockid_t; typedef unsigned long __timer_t; typedef __uint8_t __sa_family_t; typedef __uint32_t __socklen_t; typedef unsigned short __nlink_t; typedef long __suseconds_t; typedef unsigned long __useconds_t; typedef char * __va_list; typedef unsigned int __ULong; struct _reent; struct __locale_t; struct _Bigint { struct _Bigint *_next; int _k, _maxwds, _sign, _wds; __ULong _x[1]; }; struct __tm { int __tm_sec; int __tm_min; int __tm_hour; int __tm_mday; int __tm_mon; int __tm_year; int __tm_wday; int __tm_yday; int __tm_isdst; }; struct _on_exit_args { void * _fnargs[32]; void * _dso_handle[32]; __ULong _fntypes; __ULong _is_cxa; }; struct _atexit { struct _atexit *_next; int _ind; void (*_fns[32])(void); struct _on_exit_args _on_exit_args; }; struct __sbuf { unsigned char *_base; int _size; }; struct __sFILE { unsigned char *_p; int _r; int _w; short _flags; short _file; struct __sbuf _bf; int _lbfsize; void * _cookie; int (*_read) (struct _reent *, void *, char *, int); int (*_write) (struct _reent *, void *, const char *, int); _fpos_t (*_seek) (struct _reent *, void *, _fpos_t, int); int (*_close) (struct _reent *, void *); struct __sbuf _ub; unsigned char *_up; int _ur; unsigned char _ubuf[3]; unsigned char _nbuf[1]; struct __sbuf _lb; int _blksize; _off_t _offset; struct _reent *_data; _flock_t _lock; _mbstate_t _mbstate; int _flags2; }; typedef struct __sFILE __FILE; struct _glue { struct _glue *_next; int _niobs; __FILE *_iobs; }; struct _rand48 { unsigned short _seed[3]; unsigned short _mult[3]; unsigned short _add; }; struct _reent { int _errno; __FILE *_stdin, *_stdout, *_stderr; int _inc; char _emergency[25]; int _unspecified_locale_info; struct __locale_t *_locale; int __sdidinit; void (*__cleanup) (struct _reent *); struct _Bigint *_result; int _result_k; struct _Bigint *_p5s; struct _Bigint **_freelist; int _cvtlen; char *_cvtbuf; union { struct { unsigned int _unused_rand; char * _strtok_last; char _asctime_buf[26]; struct __tm _localtime_buf; int _gamma_signgam; __extension__ unsigned long long _rand_next; struct _rand48 _r48; _mbstate_t _mblen_state; _mbstate_t _mbtowc_state; _mbstate_t _wctomb_state; char _l64a_buf[8]; char _signal_buf[24]; int _getdate_err; _mbstate_t _mbrlen_state; _mbstate_t _mbrtowc_state; _mbstate_t _mbsrtowcs_state; _mbstate_t _wcrtomb_state; _mbstate_t _wcsrtombs_state; int _h_errno; } _reent; struct { unsigned char * _nextf[30]; unsigned int _nmalloc[30]; } _unused; } _new; struct _atexit *_atexit; struct _atexit _atexit0; void (**(_sig_func))(int); struct _glue __sglue; __FILE __sf[3]; }; extern struct _reent *_impure_ptr ; extern struct _reent *const _global_impure_ptr ; void _reclaim_reent (struct _reent *); struct __locale_t; typedef struct __locale_t *locale_t; int bcmp(const void *, const void *, size_t) __attribute__((__pure__)); void bcopy(const void *, void *, size_t); void bzero(void *, size_t); void explicit_bzero(void *, size_t); int ffs(int) __attribute__((__const__)); int ffsl(long) __attribute__((__const__)); int ffsll(long long) __attribute__((__const__)); int fls(int) __attribute__((__const__)); int flsl(long) __attribute__((__const__)); int flsll(long long) __attribute__((__const__)); char *index(const char *, int) __attribute__((__pure__)); char *rindex(const char *, int) __attribute__((__pure__)); int strcasecmp(const char *, const char *) __attribute__((__pure__)); int strncasecmp(const char *, const char *, size_t) __attribute__((__pure__)); int strcasecmp_l (const char *, const char *, locale_t); int strncasecmp_l (const char *, const char *, size_t, locale_t); void * memchr (const void *, int, size_t); int memcmp (const void *, const void *, size_t); void * memcpy (void *restrict, const void *restrict, size_t); void * memmove (void *, const void *, size_t); void * memset (void *, int, size_t); char *strcat (char *restrict, const char *restrict); char *strchr (const char *, int); int strcmp (const char *, const char *); int strcoll (const char *, const char *); char *strcpy (char *restrict, const char *restrict); size_t strcspn (const char *, const char *); char *strerror (int); size_t strlen (const char *); char *strncat (char *restrict, const char *restrict, size_t); int strncmp (const char *, const char *, size_t); char *strncpy (char *restrict, const char *restrict, size_t); char *strpbrk (const char *, const char *); char *strrchr (const char *, int); size_t strspn (const char *, const char *); char *strstr (const char *, const char *); char *strtok (char *restrict, const char *restrict); size_t strxfrm (char *restrict, const char *restrict, size_t); int strcoll_l (const char *, const char *, locale_t); char *strerror_l (int, locale_t); size_t strxfrm_l (char *restrict, const char *restrict, size_t, locale_t); char *strtok_r (char *restrict, const char *restrict, char **restrict); int timingsafe_bcmp (const void *, const void *, size_t); int timingsafe_memcmp (const void *, const void *, size_t); void * memccpy (void *restrict, const void *restrict, int, size_t); char *stpcpy (char *restrict, const char *restrict); char *stpncpy (char *restrict, const char *restrict, size_t); char *strdup (const char *); char *_strdup_r (struct _reent *, const char *); char *strndup (const char *, size_t); char *_strndup_r (struct _reent *, const char *, size_t); int strerror_r (int, char *, size_t) __asm__ ("" "__xpg_strerror_r") ; char * _strerror_r (struct _reent *, int, int, int *); size_t strlcat (char *, const char *, size_t); size_t strlcpy (char *, const char *, size_t); size_t strnlen (const char *, size_t); char *strsep (char **, const char *); char *strnstr(const char *, const char *, size_t) __attribute__((__pure__)); char *strlwr (char *); char *strupr (char *); char *strsignal (int __signo); typedef __int8_t int8_t ; typedef __uint8_t uint8_t ; typedef __int16_t int16_t ; typedef __uint16_t uint16_t ; typedef __int32_t int32_t ; typedef __uint32_t uint32_t ; typedef __int64_t int64_t ; typedef __uint64_t uint64_t ; typedef __intmax_t intmax_t; typedef __uintmax_t uintmax_t; typedef __intptr_t intptr_t; typedef __uintptr_t uintptr_t; typedef __int_least8_t int_least8_t; typedef __uint_least8_t uint_least8_t; typedef __int_least16_t int_least16_t; typedef __uint_least16_t uint_least16_t; typedef __int_least32_t int_least32_t; typedef __uint_least32_t uint_least32_t; typedef __int_least64_t int_least64_t; typedef __uint_least64_t uint_least64_t; typedef int int_fast8_t; typedef unsigned int uint_fast8_t; typedef int int_fast16_t; typedef unsigned int uint_fast16_t; typedef int int_fast32_t; typedef unsigned int uint_fast32_t; typedef long int int_fast64_t; typedef long unsigned int uint_fast64_t; # 56 "random_inc.h" 2 void __assert (const char *, int, const char *) __attribute__ ((__noreturn__)); void __assert_func (const char *, int, const char *, const char *) __attribute__ ((__noreturn__)); typedef __builtin_va_list __gnuc_va_list; typedef __gnuc_va_list va_list; typedef __uint8_t u_int8_t; typedef __uint16_t u_int16_t; typedef __uint32_t u_int32_t; typedef __uint64_t u_int64_t; typedef int register_t; typedef unsigned long __sigset_t; typedef __suseconds_t suseconds_t; typedef long time_t; struct timeval { time_t tv_sec; suseconds_t tv_usec; }; struct timespec { time_t tv_sec; long tv_nsec; }; struct itimerspec { struct timespec it_interval; struct timespec it_value; }; typedef __sigset_t sigset_t; typedef unsigned long fd_mask; typedef struct _types_fd_set { fd_mask fds_bits[(((64)+(((sizeof (fd_mask) * 8))-1))/((sizeof (fd_mask) * 8)))]; } _types_fd_set; int select (int __n, _types_fd_set *__readfds, _types_fd_set *__writefds, _types_fd_set *__exceptfds, struct timeval *__timeout) ; int pselect (int __n, _types_fd_set *__readfds, _types_fd_set *__writefds, _types_fd_set *__exceptfds, const struct timespec *__timeout, const sigset_t *__set) ; typedef __uint32_t in_addr_t; typedef __uint16_t in_port_t; typedef unsigned char u_char; typedef unsigned short u_short; typedef unsigned int u_int; typedef unsigned long u_long; typedef unsigned short ushort; typedef unsigned int uint; typedef unsigned long ulong; typedef __blkcnt_t blkcnt_t; typedef __blksize_t blksize_t; typedef unsigned long clock_t; typedef long daddr_t; typedef char * caddr_t; typedef __fsblkcnt_t fsblkcnt_t; typedef __fsfilcnt_t fsfilcnt_t; typedef __id_t id_t; typedef __ino_t ino_t; typedef __off_t off_t; typedef __dev_t dev_t; typedef __uid_t uid_t; typedef __gid_t gid_t; typedef __pid_t pid_t; typedef __key_t key_t; typedef _ssize_t ssize_t; typedef __mode_t mode_t; typedef __nlink_t nlink_t; typedef __clockid_t clockid_t; typedef __timer_t timer_t; typedef __useconds_t useconds_t; typedef __int64_t sbintime_t; struct sched_param { int sched_priority; }; typedef __uint32_t pthread_t; typedef struct { int is_initialized; void *stackaddr; int stacksize; int contentionscope; int inheritsched; int schedpolicy; struct sched_param schedparam; int detachstate; } pthread_attr_t; typedef __uint32_t pthread_mutex_t; typedef struct { int is_initialized; int recursive; } pthread_mutexattr_t; typedef __uint32_t pthread_cond_t; typedef struct { int is_initialized; clock_t clock; } pthread_condattr_t; typedef __uint32_t pthread_key_t; typedef struct { int is_initialized; int init_executed; } pthread_once_t; typedef __FILE FILE; typedef _fpos_t fpos_t; char * ctermid (char *); FILE * tmpfile (void); char * tmpnam (char *); char * tempnam (const char *, const char *); int fclose (FILE *); int fflush (FILE *); FILE * freopen (const char *restrict, const char *restrict, FILE *restrict); void setbuf (FILE *restrict, char *restrict); int setvbuf (FILE *restrict, char *restrict, int, size_t); int fprintf (FILE *restrict, const char *restrict, ...) __attribute__ ((__format__ (__printf__, 2, 3))); int fscanf (FILE *restrict, const char *restrict, ...) __attribute__ ((__format__ (__scanf__, 2, 3))); int printf (const char *restrict, ...) __attribute__ ((__format__ (__printf__, 1, 2))); int scanf (const char *restrict, ...) __attribute__ ((__format__ (__scanf__, 1, 2))); int sscanf (const char *restrict, const char *restrict, ...) __attribute__ ((__format__ (__scanf__, 2, 3))); int vfprintf (FILE *restrict, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 2, 0))); int vprintf (const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 1, 0))); int vsprintf (char *restrict, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 2, 0))); int fgetc (FILE *); char * fgets (char *restrict, int, FILE *restrict); int fputc (int, FILE *); int fputs (const char *restrict, FILE *restrict); int getc (FILE *); int getchar (void); char * gets (char *); int putc (int, FILE *); int putchar (int); int puts (const char *); int ungetc (int, FILE *); size_t fread (void *restrict, size_t _size, size_t _n, FILE *restrict); size_t fwrite (const void *restrict , size_t _size, size_t _n, FILE *); int fgetpos (FILE *restrict, fpos_t *restrict); int fseek (FILE *, long, int); int fsetpos (FILE *, const fpos_t *); long ftell ( FILE *); void rewind (FILE *); void clearerr (FILE *); int feof (FILE *); int ferror (FILE *); void perror (const char *); FILE * fopen (const char *restrict _name, const char *restrict _type); int sprintf (char *restrict, const char *restrict, ...) __attribute__ ((__format__ (__printf__, 2, 3))); int remove (const char *); int rename (const char *, const char *); int fseeko (FILE *, off_t, int); off_t ftello (FILE *); int snprintf (char *restrict, size_t, const char *restrict, ...) __attribute__ ((__format__ (__printf__, 3, 4))); int vsnprintf (char *restrict, size_t, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 3, 0))); int vfscanf (FILE *restrict, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__scanf__, 2, 0))); int vscanf (const char *, __gnuc_va_list) __attribute__ ((__format__ (__scanf__, 1, 0))); int vsscanf (const char *restrict, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__scanf__, 2, 0))); int asiprintf (char **, const char *, ...) __attribute__ ((__format__ (__printf__, 2, 3))); char * asniprintf (char *, size_t *, const char *, ...) __attribute__ ((__format__ (__printf__, 3, 4))); char * asnprintf (char *restrict, size_t *restrict, const char *restrict, ...) __attribute__ ((__format__ (__printf__, 3, 4))); int diprintf (int, const char *, ...) __attribute__ ((__format__ (__printf__, 2, 3))); int fiprintf (FILE *, const char *, ...) __attribute__ ((__format__ (__printf__, 2, 3))); int fiscanf (FILE *, const char *, ...) __attribute__ ((__format__ (__scanf__, 2, 3))); int iprintf (const char *, ...) __attribute__ ((__format__ (__printf__, 1, 2))); int iscanf (const char *, ...) __attribute__ ((__format__ (__scanf__, 1, 2))); int siprintf (char *, const char *, ...) __attribute__ ((__format__ (__printf__, 2, 3))); int siscanf (const char *, const char *, ...) __attribute__ ((__format__ (__scanf__, 2, 3))); int sniprintf (char *, size_t, const char *, ...) __attribute__ ((__format__ (__printf__, 3, 4))); int vasiprintf (char **, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 2, 0))); char * vasniprintf (char *, size_t *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 3, 0))); char * vasnprintf (char *, size_t *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 3, 0))); int vdiprintf (int, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 2, 0))); int vfiprintf (FILE *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 2, 0))); int vfiscanf (FILE *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__scanf__, 2, 0))); int viprintf (const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 1, 0))); int viscanf (const char *, __gnuc_va_list) __attribute__ ((__format__ (__scanf__, 1, 0))); int vsiprintf (char *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 2, 0))); int vsiscanf (const char *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__scanf__, 2, 0))); int vsniprintf (char *, size_t, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 3, 0))); FILE * fdopen (int, const char *); int fileno (FILE *); int pclose (FILE *); FILE * popen (const char *, const char *); void setbuffer (FILE *, char *, int); int setlinebuf (FILE *); int getw (FILE *); int putw (int, FILE *); int getc_unlocked (FILE *); int getchar_unlocked (void); void flockfile (FILE *); int ftrylockfile (FILE *); void funlockfile (FILE *); int putc_unlocked (int, FILE *); int putchar_unlocked (int); int dprintf (int, const char *restrict, ...) __attribute__ ((__format__ (__printf__, 2, 3))); FILE * fmemopen (void *restrict, size_t, const char *restrict); FILE * open_memstream (char **, size_t *); int vdprintf (int, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 2, 0))); int renameat (int, const char *, int, const char *); int _asiprintf_r (struct _reent *, char **, const char *, ...) __attribute__ ((__format__ (__printf__, 3, 4))); char * _asniprintf_r (struct _reent *, char *, size_t *, const char *, ...) __attribute__ ((__format__ (__printf__, 4, 5))); char * _asnprintf_r (struct _reent *, char *restrict, size_t *restrict, const char *restrict, ...) __attribute__ ((__format__ (__printf__, 4, 5))); int _asprintf_r (struct _reent *, char **restrict, const char *restrict, ...) __attribute__ ((__format__ (__printf__, 3, 4))); int _diprintf_r (struct _reent *, int, const char *, ...) __attribute__ ((__format__ (__printf__, 3, 4))); int _dprintf_r (struct _reent *, int, const char *restrict, ...) __attribute__ ((__format__ (__printf__, 3, 4))); int _fclose_r (struct _reent *, FILE *); int _fcloseall_r (struct _reent *); FILE * _fdopen_r (struct _reent *, int, const char *); int _fflush_r (struct _reent *, FILE *); int _fgetc_r (struct _reent *, FILE *); int _fgetc_unlocked_r (struct _reent *, FILE *); char * _fgets_r (struct _reent *, char *restrict, int, FILE *restrict); char * _fgets_unlocked_r (struct _reent *, char *restrict, int, FILE *restrict); int _fgetpos_r (struct _reent *, FILE *, fpos_t *); int _fsetpos_r (struct _reent *, FILE *, const fpos_t *); int _fiprintf_r (struct _reent *, FILE *, const char *, ...) __attribute__ ((__format__ (__printf__, 3, 4))); int _fiscanf_r (struct _reent *, FILE *, const char *, ...) __attribute__ ((__format__ (__scanf__, 3, 4))); FILE * _fmemopen_r (struct _reent *, void *restrict, size_t, const char *restrict); FILE * _fopen_r (struct _reent *, const char *restrict, const char *restrict); FILE * _freopen_r (struct _reent *, const char *restrict, const char *restrict, FILE *restrict); int _fprintf_r (struct _reent *, FILE *restrict, const char *restrict, ...) __attribute__ ((__format__ (__printf__, 3, 4))); int _fpurge_r (struct _reent *, FILE *); int _fputc_r (struct _reent *, int, FILE *); int _fputc_unlocked_r (struct _reent *, int, FILE *); int _fputs_r (struct _reent *, const char *restrict, FILE *restrict); int _fputs_unlocked_r (struct _reent *, const char *restrict, FILE *restrict); size_t _fread_r (struct _reent *, void *restrict, size_t _size, size_t _n, FILE *restrict); size_t _fread_unlocked_r (struct _reent *, void *restrict, size_t _size, size_t _n, FILE *restrict); int _fscanf_r (struct _reent *, FILE *restrict, const char *restrict, ...) __attribute__ ((__format__ (__scanf__, 3, 4))); int _fseek_r (struct _reent *, FILE *, long, int); int _fseeko_r (struct _reent *, FILE *, _off_t, int); long _ftell_r (struct _reent *, FILE *); _off_t _ftello_r (struct _reent *, FILE *); void _rewind_r (struct _reent *, FILE *); size_t _fwrite_r (struct _reent *, const void *restrict, size_t _size, size_t _n, FILE *restrict); size_t _fwrite_unlocked_r (struct _reent *, const void *restrict, size_t _size, size_t _n, FILE *restrict); int _getc_r (struct _reent *, FILE *); int _getc_unlocked_r (struct _reent *, FILE *); int _getchar_r (struct _reent *); int _getchar_unlocked_r (struct _reent *); char * _gets_r (struct _reent *, char *); int _iprintf_r (struct _reent *, const char *, ...) __attribute__ ((__format__ (__printf__, 2, 3))); int _iscanf_r (struct _reent *, const char *, ...) __attribute__ ((__format__ (__scanf__, 2, 3))); FILE * _open_memstream_r (struct _reent *, char **, size_t *); void _perror_r (struct _reent *, const char *); int _printf_r (struct _reent *, const char *restrict, ...) __attribute__ ((__format__ (__printf__, 2, 3))); int _putc_r (struct _reent *, int, FILE *); int _putc_unlocked_r (struct _reent *, int, FILE *); int _putchar_unlocked_r (struct _reent *, int); int _putchar_r (struct _reent *, int); int _puts_r (struct _reent *, const char *); int _remove_r (struct _reent *, const char *); int _rename_r (struct _reent *, const char *_old, const char *_new); int _scanf_r (struct _reent *, const char *restrict, ...) __attribute__ ((__format__ (__scanf__, 2, 3))); int _siprintf_r (struct _reent *, char *, const char *, ...) __attribute__ ((__format__ (__printf__, 3, 4))); int _siscanf_r (struct _reent *, const char *, const char *, ...) __attribute__ ((__format__ (__scanf__, 3, 4))); int _sniprintf_r (struct _reent *, char *, size_t, const char *, ...) __attribute__ ((__format__ (__printf__, 4, 5))); int _snprintf_r (struct _reent *, char *restrict, size_t, const char *restrict, ...) __attribute__ ((__format__ (__printf__, 4, 5))); int _sprintf_r (struct _reent *, char *restrict, const char *restrict, ...) __attribute__ ((__format__ (__printf__, 3, 4))); int _sscanf_r (struct _reent *, const char *restrict, const char *restrict, ...) __attribute__ ((__format__ (__scanf__, 3, 4))); char * _tempnam_r (struct _reent *, const char *, const char *); FILE * _tmpfile_r (struct _reent *); char * _tmpnam_r (struct _reent *, char *); int _ungetc_r (struct _reent *, int, FILE *); int _vasiprintf_r (struct _reent *, char **, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 3, 0))); char * _vasniprintf_r (struct _reent*, char *, size_t *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 4, 0))); char * _vasnprintf_r (struct _reent*, char *, size_t *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 4, 0))); int _vasprintf_r (struct _reent *, char **, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 3, 0))); int _vdiprintf_r (struct _reent *, int, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 3, 0))); int _vdprintf_r (struct _reent *, int, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 3, 0))); int _vfiprintf_r (struct _reent *, FILE *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 3, 0))); int _vfiscanf_r (struct _reent *, FILE *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__scanf__, 3, 0))); int _vfprintf_r (struct _reent *, FILE *restrict, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 3, 0))); int _vfscanf_r (struct _reent *, FILE *restrict, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__scanf__, 3, 0))); int _viprintf_r (struct _reent *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 2, 0))); int _viscanf_r (struct _reent *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__scanf__, 2, 0))); int _vprintf_r (struct _reent *, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 2, 0))); int _vscanf_r (struct _reent *, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__scanf__, 2, 0))); int _vsiprintf_r (struct _reent *, char *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 3, 0))); int _vsiscanf_r (struct _reent *, const char *, const char *, __gnuc_va_list) __attribute__ ((__format__ (__scanf__, 3, 0))); int _vsniprintf_r (struct _reent *, char *, size_t, const char *, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 4, 0))); int _vsnprintf_r (struct _reent *, char *restrict, size_t, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 4, 0))); int _vsprintf_r (struct _reent *, char *restrict, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__printf__, 3, 0))); int _vsscanf_r (struct _reent *, const char *restrict, const char *restrict, __gnuc_va_list) __attribute__ ((__format__ (__scanf__, 3, 0))); int fpurge (FILE *); ssize_t __getdelim (char **, size_t *, int, FILE *); ssize_t __getline (char **, size_t *, FILE *); void clearerr_unlocked (FILE *); int feof_unlocked (FILE *); int ferror_unlocked (FILE *); int fileno_unlocked (FILE *); int fflush_unlocked (FILE *); int fgetc_unlocked (FILE *); int fputc_unlocked (int, FILE *); size_t fread_unlocked (void *restrict, size_t _size, size_t _n, FILE *restrict); size_t fwrite_unlocked (const void *restrict , size_t _size, size_t _n, FILE *); int __srget_r (struct _reent *, FILE *); int __swbuf_r (struct _reent *, int, FILE *); FILE *funopen (const void *__cookie, int (*__readfn)(void *__cookie, char *__buf, int __n), int (*__writefn)(void *__cookie, const char *__buf, int __n), fpos_t (*__seekfn)(void *__cookie, fpos_t __off, int __whence), int (*__closefn)(void *__cookie)); FILE *_funopen_r (struct _reent *, const void *__cookie, int (*__readfn)(void *__cookie, char *__buf, int __n), int (*__writefn)(void *__cookie, const char *__buf, int __n), fpos_t (*__seekfn)(void *__cookie, fpos_t __off, int __whence), int (*__closefn)(void *__cookie)); static __inline__ int __sputc_r(struct _reent *_ptr, int _c, FILE *_p) { if (--_p->_w >= 0 || (_p->_w >= _p->_lbfsize && (char)_c != '\n')) return (*_p->_p++ = _c); else return (__swbuf_r(_ptr, _c, _p)); } static __inline int _getchar_unlocked(void) { struct _reent *_ptr; _ptr = _impure_ptr; return ((--(((_ptr)->_stdin))->_r < 0 ? __srget_r(_ptr, ((_ptr)->_stdin)) : (int)(*(((_ptr)->_stdin))->_p++))); } static __inline int _putchar_unlocked(int _c) { struct _reent *_ptr; _ptr = _impure_ptr; return (__sputc_r(_ptr, _c, ((_ptr)->_stdout))); } # 41 "platform_generic.h" 2 # 43 "platform_generic.h" static void platform_main_begin(void) { } static void platform_main_end(uint32_t crc, int flag) { printf ("checksum = %X\n", crc); # 117 "platform_generic.h" } # 90 "random_inc.h" 2 # 100 "random_inc.h" # 1 "safe_math.h" 1 # 13 "safe_math.h" static int8_t (safe_unary_minus_func_int8_t_s)(int8_t si ) { return -si; } static int8_t (safe_add_func_int8_t_s_s)(int8_t si1, int8_t si2 ) { return (si1 + si2); } static int8_t (safe_sub_func_int8_t_s_s)(int8_t si1, int8_t si2 ) { return (si1 - si2); } static int8_t (safe_mul_func_int8_t_s_s)(int8_t si1, int8_t si2 ) { return si1 * si2; } static int8_t (safe_mod_func_int8_t_s_s)(int8_t si1, int8_t si2 ) { return ((si2 == 0) || ((si1 == # 75 "safe_math.h" 3 4 (-0x7f - 1) # 75 "safe_math.h" ) && (si2 == (-1)))) ? ((si1)) : (si1 % si2); } static int8_t (safe_div_func_int8_t_s_s)(int8_t si1, int8_t si2 ) { return ((si2 == 0) || ((si1 == # 87 "safe_math.h" 3 4 (-0x7f - 1) # 87 "safe_math.h" ) && (si2 == (-1)))) ? ((si1)) : (si1 / si2); } static int8_t (safe_lshift_func_int8_t_s_s)(int8_t left, int right ) { return ((left < 0) || (((int)right) < 0) || (((int)right) >= 32) || (left > ( # 99 "safe_math.h" 3 4 (0x7f) # 99 "safe_math.h" >> ((int)right)))) ? ((left)) : (left << ((int)right)); } static int8_t (safe_lshift_func_int8_t_s_u)(int8_t left, unsigned int right ) { return ((left < 0) || (((unsigned int)right) >= 32) || (left > ( # 111 "safe_math.h" 3 4 (0x7f) # 111 "safe_math.h" >> ((unsigned int)right)))) ? ((left)) : (left << ((unsigned int)right)); } static int8_t (safe_rshift_func_int8_t_s_s)(int8_t left, int right ) { return ((left < 0) || (((int)right) < 0) || (((int)right) >= 32))? ((left)) : (left >> ((int)right)); } static int8_t (safe_rshift_func_int8_t_s_u)(int8_t left, unsigned int right ) { return ((left < 0) || (((unsigned int)right) >= 32)) ? ((left)) : (left >> ((unsigned int)right)); } static int16_t (safe_unary_minus_func_int16_t_s)(int16_t si ) { return -si; } static int16_t (safe_add_func_int16_t_s_s)(int16_t si1, int16_t si2 ) { return (si1 + si2); } static int16_t (safe_sub_func_int16_t_s_s)(int16_t si1, int16_t si2 ) { return (si1 - si2); } static int16_t (safe_mul_func_int16_t_s_s)(int16_t si1, int16_t si2 ) { return si1 * si2; } static int16_t (safe_mod_func_int16_t_s_s)(int16_t si1, int16_t si2 ) { return ((si2 == 0) || ((si1 == # 205 "safe_math.h" 3 4 (-0x7fff - 1) # 205 "safe_math.h" ) && (si2 == (-1)))) ? ((si1)) : (si1 % si2); } static int16_t (safe_div_func_int16_t_s_s)(int16_t si1, int16_t si2 ) { return ((si2 == 0) || ((si1 == # 217 "safe_math.h" 3 4 (-0x7fff - 1) # 217 "safe_math.h" ) && (si2 == (-1)))) ? ((si1)) : (si1 / si2); } static int16_t (safe_lshift_func_int16_t_s_s)(int16_t left, int right ) { return ((left < 0) || (((int)right) < 0) || (((int)right) >= 32) || (left > ( # 229 "safe_math.h" 3 4 (0x7fff) # 229 "safe_math.h" >> ((int)right)))) ? ((left)) : (left << ((int)right)); } static int16_t (safe_lshift_func_int16_t_s_u)(int16_t left, unsigned int right ) { return ((left < 0) || (((unsigned int)right) >= 32) || (left > ( # 241 "safe_math.h" 3 4 (0x7fff) # 241 "safe_math.h" >> ((unsigned int)right)))) ? ((left)) : (left << ((unsigned int)right)); } static int16_t (safe_rshift_func_int16_t_s_s)(int16_t left, int right ) { return ((left < 0) || (((int)right) < 0) || (((int)right) >= 32))? ((left)) : (left >> ((int)right)); } static int16_t (safe_rshift_func_int16_t_s_u)(int16_t left, unsigned int right ) { return ((left < 0) || (((unsigned int)right) >= 32)) ? ((left)) : (left >> ((unsigned int)right)); } static int32_t (safe_unary_minus_func_int32_t_s)(int32_t si ) { return (si== # 280 "safe_math.h" 3 4 (-0x7fffffff - 1) # 280 "safe_math.h" ) ? ((si)) : -si; } static int32_t (safe_add_func_int32_t_s_s)(int32_t si1, int32_t si2 ) { return (((si1>0) && (si2>0) && (si1 > ( # 294 "safe_math.h" 3 4 (0x7fffffff) # 294 "safe_math.h" -si2))) || ((si1<0) && (si2<0) && (si1 < ( # 294 "safe_math.h" 3 4 (-0x7fffffff - 1) # 294 "safe_math.h" -si2)))) ? ((si1)) : (si1 + si2); } static int32_t (safe_sub_func_int32_t_s_s)(int32_t si1, int32_t si2 ) { return (((si1^si2) & (((si1 ^ ((si1^si2) & (~ # 308 "safe_math.h" 3 4 (0x7fffffff) # 308 "safe_math.h" )))-si2)^si2)) < 0) ? ((si1)) : (si1 - si2); } static int32_t (safe_mul_func_int32_t_s_s)(int32_t si1, int32_t si2 ) { return (((si1 > 0) && (si2 > 0) && (si1 > ( # 322 "safe_math.h" 3 4 (0x7fffffff) # 322 "safe_math.h" / si2))) || ((si1 > 0) && (si2 <= 0) && (si2 < ( # 322 "safe_math.h" 3 4 (-0x7fffffff - 1) # 322 "safe_math.h" / si1))) || ((si1 <= 0) && (si2 > 0) && (si1 < ( # 322 "safe_math.h" 3 4 (-0x7fffffff - 1) # 322 "safe_math.h" / si2))) || ((si1 <= 0) && (si2 <= 0) && (si1 != 0) && (si2 < ( # 322 "safe_math.h" 3 4 (0x7fffffff) # 322 "safe_math.h" / si1)))) ? ((si1)) : si1 * si2; } static int32_t (safe_mod_func_int32_t_s_s)(int32_t si1, int32_t si2 ) { return ((si2 == 0) || ((si1 == # 335 "safe_math.h" 3 4 (-0x7fffffff - 1) # 335 "safe_math.h" ) && (si2 == (-1)))) ? ((si1)) : (si1 % si2); } static int32_t (safe_div_func_int32_t_s_s)(int32_t si1, int32_t si2 ) { return ((si2 == 0) || ((si1 == # 347 "safe_math.h" 3 4 (-0x7fffffff - 1) # 347 "safe_math.h" ) && (si2 == (-1)))) ? ((si1)) : (si1 / si2); } static int32_t (safe_lshift_func_int32_t_s_s)(int32_t left, int right ) { return ((left < 0) || (((int)right) < 0) || (((int)right) >= 32) || (left > ( # 359 "safe_math.h" 3 4 (0x7fffffff) # 359 "safe_math.h" >> ((int)right)))) ? ((left)) : (left << ((int)right)); } static int32_t (safe_lshift_func_int32_t_s_u)(int32_t left, unsigned int right ) { return ((left < 0) || (((unsigned int)right) >= 32) || (left > ( # 371 "safe_math.h" 3 4 (0x7fffffff) # 371 "safe_math.h" >> ((unsigned int)right)))) ? ((left)) : (left << ((unsigned int)right)); } static int32_t (safe_rshift_func_int32_t_s_s)(int32_t left, int right ) { return ((left < 0) || (((int)right) < 0) || (((int)right) >= 32))? ((left)) : (left >> ((int)right)); } static int32_t (safe_rshift_func_int32_t_s_u)(int32_t left, unsigned int right ) { return ((left < 0) || (((unsigned int)right) >= 32)) ? ((left)) : (left >> ((unsigned int)right)); } static int64_t (safe_unary_minus_func_int64_t_s)(int64_t si ) { return (si== # 411 "safe_math.h" 3 4 (-0x7fffffffffffffffL - 1) # 411 "safe_math.h" ) ? ((si)) : -si; } static int64_t (safe_add_func_int64_t_s_s)(int64_t si1, int64_t si2 ) { return (((si1>0) && (si2>0) && (si1 > ( # 425 "safe_math.h" 3 4 (0x7fffffffffffffffL) # 425 "safe_math.h" -si2))) || ((si1<0) && (si2<0) && (si1 < ( # 425 "safe_math.h" 3 4 (-0x7fffffffffffffffL - 1) # 425 "safe_math.h" -si2)))) ? ((si1)) : (si1 + si2); } static int64_t (safe_sub_func_int64_t_s_s)(int64_t si1, int64_t si2 ) { return (((si1^si2) & (((si1 ^ ((si1^si2) & (~ # 439 "safe_math.h" 3 4 (0x7fffffffffffffffL) # 439 "safe_math.h" )))-si2)^si2)) < 0) ? ((si1)) : (si1 - si2); } static int64_t (safe_mul_func_int64_t_s_s)(int64_t si1, int64_t si2 ) { return (((si1 > 0) && (si2 > 0) && (si1 > ( # 453 "safe_math.h" 3 4 (0x7fffffffffffffffL) # 453 "safe_math.h" / si2))) || ((si1 > 0) && (si2 <= 0) && (si2 < ( # 453 "safe_math.h" 3 4 (-0x7fffffffffffffffL - 1) # 453 "safe_math.h" / si1))) || ((si1 <= 0) && (si2 > 0) && (si1 < ( # 453 "safe_math.h" 3 4 (-0x7fffffffffffffffL - 1) # 453 "safe_math.h" / si2))) || ((si1 <= 0) && (si2 <= 0) && (si1 != 0) && (si2 < ( # 453 "safe_math.h" 3 4 (0x7fffffffffffffffL) # 453 "safe_math.h" / si1)))) ? ((si1)) : si1 * si2; } static int64_t (safe_mod_func_int64_t_s_s)(int64_t si1, int64_t si2 ) { return ((si2 == 0) || ((si1 == # 466 "safe_math.h" 3 4 (-0x7fffffffffffffffL - 1) # 466 "safe_math.h" ) && (si2 == (-1)))) ? ((si1)) : (si1 % si2); } static int64_t (safe_div_func_int64_t_s_s)(int64_t si1, int64_t si2 ) { return ((si2 == 0) || ((si1 == # 478 "safe_math.h" 3 4 (-0x7fffffffffffffffL - 1) # 478 "safe_math.h" ) && (si2 == (-1)))) ? ((si1)) : (si1 / si2); } static int64_t (safe_lshift_func_int64_t_s_s)(int64_t left, int right ) { return ((left < 0) || (((int)right) < 0) || (((int)right) >= 32) || (left > ( # 490 "safe_math.h" 3 4 (0x7fffffffffffffffL) # 490 "safe_math.h" >> ((int)right)))) ? ((left)) : (left << ((int)right)); } static int64_t (safe_lshift_func_int64_t_s_u)(int64_t left, unsigned int right ) { return ((left < 0) || (((unsigned int)right) >= 32) || (left > ( # 502 "safe_math.h" 3 4 (0x7fffffffffffffffL) # 502 "safe_math.h" >> ((unsigned int)right)))) ? ((left)) : (left << ((unsigned int)right)); } static int64_t (safe_rshift_func_int64_t_s_s)(int64_t left, int right ) { return ((left < 0) || (((int)right) < 0) || (((int)right) >= 32))? ((left)) : (left >> ((int)right)); } static int64_t (safe_rshift_func_int64_t_s_u)(int64_t left, unsigned int right ) { return ((left < 0) || (((unsigned int)right) >= 32)) ? ((left)) : (left >> ((unsigned int)right)); } static uint8_t (safe_unary_minus_func_uint8_t_u)(uint8_t ui ) { return -ui; } static uint8_t (safe_add_func_uint8_t_u_u)(uint8_t ui1, uint8_t ui2 ) { return ui1 + ui2; } static uint8_t (safe_sub_func_uint8_t_u_u)(uint8_t ui1, uint8_t ui2 ) { return ui1 - ui2; } static uint8_t (safe_mul_func_uint8_t_u_u)(uint8_t ui1, uint8_t ui2 ) { return ((unsigned int)ui1) * ((unsigned int)ui2); } static uint8_t (safe_mod_func_uint8_t_u_u)(uint8_t ui1, uint8_t ui2 ) { return (ui2 == 0) ? ((ui1)) : (ui1 % ui2); } static uint8_t (safe_div_func_uint8_t_u_u)(uint8_t ui1, uint8_t ui2 ) { return (ui2 == 0) ? ((ui1)) : (ui1 / ui2); } static uint8_t (safe_lshift_func_uint8_t_u_s)(uint8_t left, int right ) { return ((((int)right) < 0) || (((int)right) >= 32) || (left > ( # 596 "safe_math.h" 3 4 (0xff) # 596 "safe_math.h" >> ((int)right)))) ? ((left)) : (left << ((int)right)); } static uint8_t (safe_lshift_func_uint8_t_u_u)(uint8_t left, unsigned int right ) { return ((((unsigned int)right) >= 32) || (left > ( # 608 "safe_math.h" 3 4 (0xff) # 608 "safe_math.h" >> ((unsigned int)right)))) ? ((left)) : (left << ((unsigned int)right)); } static uint8_t (safe_rshift_func_uint8_t_u_s)(uint8_t left, int right ) { return ((((int)right) < 0) || (((int)right) >= 32)) ? ((left)) : (left >> ((int)right)); } static uint8_t (safe_rshift_func_uint8_t_u_u)(uint8_t left, unsigned int right ) { return (((unsigned int)right) >= 32) ? ((left)) : (left >> ((unsigned int)right)); } static uint16_t (safe_unary_minus_func_uint16_t_u)(uint16_t ui ) { return -ui; } static uint16_t (safe_add_func_uint16_t_u_u)(uint16_t ui1, uint16_t ui2 ) { return ui1 + ui2; } static uint16_t (safe_sub_func_uint16_t_u_u)(uint16_t ui1, uint16_t ui2 ) { return ui1 - ui2; } static uint16_t (safe_mul_func_uint16_t_u_u)(uint16_t ui1, uint16_t ui2 ) { return ((unsigned int)ui1) * ((unsigned int)ui2); } static uint16_t (safe_mod_func_uint16_t_u_u)(uint16_t ui1, uint16_t ui2 ) { return (ui2 == 0) ? ((ui1)) : (ui1 % ui2); } static uint16_t (safe_div_func_uint16_t_u_u)(uint16_t ui1, uint16_t ui2 ) { return (ui2 == 0) ? ((ui1)) : (ui1 / ui2); } static uint16_t (safe_lshift_func_uint16_t_u_s)(uint16_t left, int right ) { return ((((int)right) < 0) || (((int)right) >= 32) || (left > ( # 698 "safe_math.h" 3 4 (0xffff) # 698 "safe_math.h" >> ((int)right)))) ? ((left)) : (left << ((int)right)); } static uint16_t (safe_lshift_func_uint16_t_u_u)(uint16_t left, unsigned int right ) { return ((((unsigned int)right) >= 32) || (left > ( # 710 "safe_math.h" 3 4 (0xffff) # 710 "safe_math.h" >> ((unsigned int)right)))) ? ((left)) : (left << ((unsigned int)right)); } static uint16_t (safe_rshift_func_uint16_t_u_s)(uint16_t left, int right ) { return ((((int)right) < 0) || (((int)right) >= 32)) ? ((left)) : (left >> ((int)right)); } static uint16_t (safe_rshift_func_uint16_t_u_u)(uint16_t left, unsigned int right ) { return (((unsigned int)right) >= 32) ? ((left)) : (left >> ((unsigned int)right)); } static uint32_t (safe_unary_minus_func_uint32_t_u)(uint32_t ui ) { return -ui; } static uint32_t (safe_add_func_uint32_t_u_u)(uint32_t ui1, uint32_t ui2 ) { return ui1 + ui2; } static uint32_t (safe_sub_func_uint32_t_u_u)(uint32_t ui1, uint32_t ui2 ) { return ui1 - ui2; } static uint32_t (safe_mul_func_uint32_t_u_u)(uint32_t ui1, uint32_t ui2 ) { return ((unsigned int)ui1) * ((unsigned int)ui2); } static uint32_t (safe_mod_func_uint32_t_u_u)(uint32_t ui1, uint32_t ui2 ) { return (ui2 == 0) ? ((ui1)) : (ui1 % ui2); } static uint32_t (safe_div_func_uint32_t_u_u)(uint32_t ui1, uint32_t ui2 ) { return (ui2 == 0) ? ((ui1)) : (ui1 / ui2); } static uint32_t (safe_lshift_func_uint32_t_u_s)(uint32_t left, int right ) { return ((((int)right) < 0) || (((int)right) >= 32) || (left > ( # 800 "safe_math.h" 3 4 (0xffffffffU) # 800 "safe_math.h" >> ((int)right)))) ? ((left)) : (left << ((int)right)); } static uint32_t (safe_lshift_func_uint32_t_u_u)(uint32_t left, unsigned int right ) { return ((((unsigned int)right) >= 32) || (left > ( # 812 "safe_math.h" 3 4 (0xffffffffU) # 812 "safe_math.h" >> ((unsigned int)right)))) ? ((left)) : (left << ((unsigned int)right)); } static uint32_t (safe_rshift_func_uint32_t_u_s)(uint32_t left, int right ) { return ((((int)right) < 0) || (((int)right) >= 32)) ? ((left)) : (left >> ((int)right)); } static uint32_t (safe_rshift_func_uint32_t_u_u)(uint32_t left, unsigned int right ) { return (((unsigned int)right) >= 32) ? ((left)) : (left >> ((unsigned int)right)); } static uint64_t (safe_unary_minus_func_uint64_t_u)(uint64_t ui ) { return -ui; } static uint64_t (safe_add_func_uint64_t_u_u)(uint64_t ui1, uint64_t ui2 ) { return ui1 + ui2; } static uint64_t (safe_sub_func_uint64_t_u_u)(uint64_t ui1, uint64_t ui2 ) { return ui1 - ui2; } static uint64_t (safe_mul_func_uint64_t_u_u)(uint64_t ui1, uint64_t ui2 ) { return ((unsigned long long int)ui1) * ((unsigned long long int)ui2); } static uint64_t (safe_mod_func_uint64_t_u_u)(uint64_t ui1, uint64_t ui2 ) { return (ui2 == 0) ? ((ui1)) : (ui1 % ui2); } static uint64_t (safe_div_func_uint64_t_u_u)(uint64_t ui1, uint64_t ui2 ) { return (ui2 == 0) ? ((ui1)) : (ui1 / ui2); } static uint64_t (safe_lshift_func_uint64_t_u_s)(uint64_t left, int right ) { return ((((int)right) < 0) || (((int)right) >= 32) || (left > ( # 903 "safe_math.h" 3 4 (0xffffffffffffffffUL) # 903 "safe_math.h" >> ((int)right)))) ? ((left)) : (left << ((int)right)); } static uint64_t (safe_lshift_func_uint64_t_u_u)(uint64_t left, unsigned int right ) { return ((((unsigned int)right) >= 32) || (left > ( # 915 "safe_math.h" 3 4 (0xffffffffffffffffUL) # 915 "safe_math.h" >> ((unsigned int)right)))) ? ((left)) : (left << ((unsigned int)right)); } static uint64_t (safe_rshift_func_uint64_t_u_s)(uint64_t left, int right ) { return ((((int)right) < 0) || (((int)right) >= 32)) ? ((left)) : (left >> ((int)right)); } static uint64_t (safe_rshift_func_uint64_t_u_u)(uint64_t left, unsigned int right ) { return (((unsigned int)right) >= 32) ? ((left)) : (left >> ((unsigned int)right)); } # 101 "random_inc.h" 2 # 44 "csmith.h" 2 static uint32_t crc32_tab[256]; static uint32_t crc32_context = 0xFFFFFFFFUL; static void crc32_gentab (void) { uint32_t crc; const uint32_t poly = 0xEDB88320UL; int i, j; for (i = 0; i < 256; i++) { crc = i; for (j = 8; j > 0; j--) { if (crc & 1) { crc = (crc >> 1) ^ poly; } else { crc >>= 1; } } crc32_tab[i] = crc; } } static void crc32_byte (uint8_t b) { crc32_context = ((crc32_context >> 8) & 0x00FFFFFF) ^ crc32_tab[(crc32_context ^ b) & 0xFF]; } # 94 "csmith.h" static void crc32_8bytes (uint64_t val) { crc32_byte ((val>>0) & 0xff); crc32_byte ((val>>8) & 0xff); crc32_byte ((val>>16) & 0xff); crc32_byte ((val>>24) & 0xff); crc32_byte ((val>>32) & 0xff); crc32_byte ((val>>40) & 0xff); crc32_byte ((val>>48) & 0xff); crc32_byte ((val>>56) & 0xff); } static void transparent_crc (uint64_t val, char* vname, int flag) { crc32_8bytes(val); if (flag) { printf("...checksum after hashing %s : %lX\n", vname, crc32_context ^ 0xFFFFFFFFUL); } } # 11 "gh.c" 2 static long __undefined; static volatile uint8_t g_25[1][10] = {{250UL,0x6DL,250UL,250UL,0x6DL,250UL,250UL,0x6DL,250UL,250UL}}; static int32_t g_27[3] = {0x3072C02AL,0x3072C02AL,0x3072C02AL}; static int32_t *g_26 = &g_27[1]; static int32_t g_63 = 0xD0EE3B00L; static uint16_t g_85 = 65526UL; static int16_t g_131 = 6L; static uint16_t g_133 = 0x0E6BL; static uint64_t g_134 = 0UL; static int32_t g_135[6][10][4] = {{{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L}},{{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L}},{{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L}},{{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L}},{{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L}},{{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L},{0x6884AE36L,0xEDC84E98L,0x6884AE36L,9L},{0x6884AE36L,9L,0x6884AE36L,0xEDC84E98L}}}; static uint8_t g_138 = 0x24L; static int32_t g_140 = 0L; static int32_t *g_139 = &g_140; static int64_t g_160 = 0L; static int8_t g_168 = (-5L); static uint16_t *g_186 = &g_85; static int32_t **g_217 = (void*)0; static int32_t ** const *g_216 = &g_217; static int32_t ** const **g_215 = &g_216; static int32_t ** volatile g_258 = &g_26; static int32_t ** volatile g_323[8][3][2] = {{{&g_139,&g_139},{&g_139,&g_139},{&g_139,&g_139}},{{(void*)0,(void*)0},{(void*)0,&g_139},{&g_139,&g_139}},{{&g_139,&g_139},{&g_139,&g_139},{(void*)0,(void*)0}},{{(void*)0,&g_139},{&g_139,&g_139},{&g_139,&g_139}},{{&g_139,&g_139},{(void*)0,(void*)0},{(void*)0,&g_139}},{{&g_139,&g_139},{&g_139,&g_139},{&g_139,&g_139}},{{(void*)0,(void*)0},{(void*)0,&g_139},{&g_139,&g_139}},{{&g_139,&g_139},{&g_139,&g_139},{(void*)0,(void*)0}}}; static uint32_t g_340 = 0xEFC9F5F1L; static const int32_t *g_343 = &g_27[0]; static const int32_t ** volatile g_342[7][8][1] = {{{&g_343},{&g_343},{&g_343},{&g_343},{&g_343},{&g_343},{&g_343},{&g_343}},{{&g_343},{(void*)0},{(void*)0},{(void*)0},{(void*)0},{&g_343},{&g_343},{&g_343}},{{&g_343},{&g_343},{&g_343},{&g_343},{&g_343},{&g_343},{&g_343},{&g_343}},{{&g_343},{&g_343},{(void*)0},{(void*)0},{(void*)0},{(void*)0},{&g_343},{&g_343}},{{&g_343},{&g_343},{&g_343},{&g_343},{&g_343},{&g_343},{&g_343},{&g_343}},{{&g_343},{&g_343},{&g_343},{(void*)0},{(void*)0},{(void*)0},{(void*)0},{&g_343}},{{&g_343},{&g_343},{&g_343},{&g_343},{&g_343},{&g_343},{&g_343},{&g_343}}}; static uint64_t g_429 = 0x9F5BE769D06E20DDLL; static int32_t ** volatile g_442 = &g_139; static uint64_t *g_478 = (void*)0; static uint64_t **g_477[6][7][5] = {{{&g_478,(void*)0,&g_478,&g_478,&g_478},{&g_478,&g_478,&g_478,(void*)0,&g_478},{&g_478,&g_478,(void*)0,&g_478,&g_478},{&g_478,&g_478,(void*)0,(void*)0,&g_478},{&g_478,(void*)0,(void*)0,(void*)0,&g_478},{(void*)0,&g_478,(void*)0,(void*)0,&g_478},{&g_478,&g_478,&g_478,(void*)0,(void*)0}},{{&g_478,&g_478,&g_478,&g_478,&g_478},{(void*)0,(void*)0,(void*)0,&g_478,&g_478},{(void*)0,&g_478,&g_478,&g_478,&g_478},{&g_478,&g_478,&g_478,&g_478,&g_478},{&g_478,&g_478,(void*)0,&g_478,&g_478},{&g_478,&g_478,&g_478,(void*)0,(void*)0},{&g_478,&g_478,&g_478,(void*)0,&g_478}},{{&g_478,&g_478,&g_478,&g_478,&g_478},{&g_478,&g_478,&g_478,&g_478,&g_478},{&g_478,&g_478,(void*)0,&g_478,(void*)0},{&g_478,&g_478,&g_478,&g_478,&g_478},{(void*)0,&g_478,&g_478,&g_478,&g_478},{&g_478,&g_478,&g_478,(void*)0,(void*)0},{(void*)0,&g_478,&g_478,&g_478,&g_478}},{{&g_478,&g_478,(void*)0,&g_478,&g_478},{(void*)0,&g_478,(void*)0,&g_478,&g_478},{&g_478,&g_478,&g_478,&g_478,&g_478},{(void*)0,&g_478,(void*)0,&g_478,&g_478},{&g_478,&g_478,(void*)0,&g_478,&g_478},{&g_478,&g_478,(void*)0,&g_478,(void*)0},{&g_478,&g_478,&g_478,(void*)0,&g_478}},{{&g_478,&g_478,&g_478,&g_478,&g_478},{(void*)0,&g_478,(void*)0,&g_478,&g_478},{&g_478,&g_478,&g_478,(void*)0,&g_478},{&g_478,&g_478,&g_478,&g_478,(void*)0},{(void*)0,&g_478,&g_478,&g_478,&g_478},{&g_478,&g_478,&g_478,(void*)0,&g_478},{&g_478,&g_478,&g_478,&g_478,&g_478}},{{&g_478,&g_478,(void*)0,&g_478,&g_478},{(void*)0,&g_478,&g_478,(void*)0,&g_478},{&g_478,&g_478,&g_478,(void*)0,&g_478},{&g_478,&g_478,(void*)0,(void*)0,&g_478},{&g_478,&g_478,(void*)0,(void*)0,&g_478},{&g_478,(void*)0,(void*)0,&g_478,(void*)0},{(void*)0,&g_478,&g_478,&g_478,(void*)0}}}; static int16_t g_505 = 1L; static uint32_t g_508 = 1UL; static int32_t * volatile g_530[10][7] = {{(void*)0,&g_140,&g_140,&g_63,&g_63,&g_63,&g_63},{&g_140,(void*)0,&g_140,(void*)0,&g_140,&g_140,&g_63},{(void*)0,&g_63,&g_140,&g_63,&g_140,&g_63,(void*)0},{&g_140,&g_63,&g_140,&g_63,(void*)0,(void*)0,&g_140},{&g_140,(void*)0,&g_63,&g_140,&g_63,&g_63,&g_140},{&g_140,&g_140,&g_140,&g_63,&g_63,&g_63,&g_140},{(void*)0,(void*)0,&g_140,&g_63,&g_63,&g_140,&g_140},{&g_63,&g_63,&g_63,&g_140,&g_140,(void*)0,&g_140},{&g_140,&g_140,&g_140,&g_140,&g_63,&g_63,&g_63},{&g_63,&g_140,&g_140,&g_63,&g_140,&g_63,(void*)0}}; static int32_t * volatile g_531 = &g_140; static uint64_t g_593 = 0x9D22A369EEDF23FCLL; static uint8_t g_616 = 253UL; static const uint8_t g_626 = 4UL; static uint32_t g_640 = 0xE0DD2C72L; static uint32_t *g_639[2][3][6] = {{{&g_640,&g_640,(void*)0,&g_640,&g_640,(void*)0},{&g_640,&g_640,(void*)0,&g_640,&g_640,(void*)0},{&g_640,&g_640,(void*)0,&g_640,&g_640,(void*)0}},{{&g_640,&g_640,(void*)0,&g_640,&g_640,(void*)0},{&g_640,&g_640,(void*)0,&g_640,&g_640,(void*)0},{&g_640,&g_640,(void*)0,&g_640,&g_640,(void*)0}}}; static uint32_t **g_643 = &g_639[1][1][2]; static int64_t g_694 = 0xAB60689D0A387DEFLL; static int8_t g_743 = 0x3BL; static volatile uint64_t g_744 = 0UL; static const int32_t * volatile * volatile **g_759 = (void*)0; static uint16_t **g_785 = &g_186; static uint16_t *** volatile g_784[1][10][7] = {{{&g_785,&g_785,&g_785,&g_785,&g_785,&g_785,&g_785},{(void*)0,&g_785,&g_785,&g_785,(void*)0,&g_785,&g_785},{&g_785,&g_785,&g_785,&g_785,&g_785,(void*)0,&g_785},{&g_785,&g_785,&g_785,(void*)0,(void*)0,&g_785,&g_785},{&g_785,&g_785,&g_785,&g_785,&g_785,&g_785,&g_785},{(void*)0,(void*)0,(void*)0,&g_785,&g_785,(void*)0,&g_785},{&g_785,&g_785,&g_785,&g_785,&g_785,&g_785,&g_785},{&g_785,&g_785,(void*)0,(void*)0,&g_785,&g_785,&g_785},{&g_785,(void*)0,&g_785,&g_785,&g_785,(void*)0,&g_785},{&g_785,&g_785,(void*)0,&g_785,&g_785,&g_785,&g_785}}}; static uint16_t *** volatile g_786[1][6][2] = {{{&g_785,(void*)0},{&g_785,&g_785},{(void*)0,&g_785},{&g_785,(void*)0},{&g_785,&g_785},{(void*)0,&g_785}}}; static uint16_t *** volatile g_787 = &g_785; static uint8_t *g_800 = &g_616; static uint8_t * volatile * volatile g_799 = &g_800; static volatile int32_t g_828 = 1L; static const uint32_t ** volatile g_1019 = (void*)0; static volatile int16_t g_1095 = 0x524FL; static uint32_t *g_1127 = &g_508; static volatile uint64_t *** volatile * volatile g_1245 = (void*)0; static volatile uint64_t *g_1250 = &g_744; static volatile uint64_t **g_1249 = &g_1250; static volatile uint64_t *** volatile g_1248 = &g_1249; static const int32_t g_1297 = 0xADDD049EL; static const int32_t g_1299[4][10] = {{3L,0xF99C144FL,0xAE18D686L,1L,0xF99C144FL,0x6FA02721L,0L,0xAE18D686L,0xAE18D686L,0L},{0x6FA02721L,0L,0xAE18D686L,0xAE18D686L,0L,0x6FA02721L,0xF99C144FL,1L,0xAE18D686L,0xF99C144FL},{3L,0L,0x4F08E25AL,1L,0L,(-1L),0L,1L,0x4F08E25AL,0L},{3L,0xF99C144FL,0xAE18D686L,1L,0xF99C144FL,0x6FA02721L,0L,0xAE18D686L,0xAE18D686L,0L}}; static int16_t *g_1323 = &g_131; static int32_t *g_1327 = &g_135[3][7][2]; static int32_t ** volatile g_1326 = &g_1327; static const uint16_t *g_1422[4] = {&g_133,&g_133,&g_133,&g_133}; static const uint16_t * const *g_1421 = &g_1422[0]; static uint64_t g_1485[2] = {0xAF8F6984A0E4B2A4LL,0xAF8F6984A0E4B2A4LL}; static volatile uint8_t g_1556 = 0x7EL; static int32_t g_1572 = 0x67899668L; static uint64_t ***g_1606 = &g_477[3][4][0]; static uint64_t ****g_1605 = &g_1606; static uint32_t g_1618 = 18446744073709551609UL; static int8_t *g_1633[3] = {&g_168,&g_168,&g_168}; static int8_t ** const g_1632 = &g_1633[2]; static int64_t g_1655 = 0x90FA6A9EF3114AE2LL; static int8_t **g_1716 = &g_1633[0]; static int8_t ***g_1715 = &g_1716; static int8_t ***g_1718 = &g_1716; static int16_t g_1752[3][1] = {{2L},{2L},{2L}}; static uint64_t ***** volatile g_1899 = (void*)0; static uint64_t ***** volatile g_1900 = &g_1605; static volatile uint32_t g_1973 = 0x4DF73C99L; static volatile uint32_t * volatile g_1972 = &g_1973; static volatile uint32_t * volatile *g_1971 = &g_1972; static volatile uint32_t * volatile * volatile *g_1970 = &g_1971; static volatile uint32_t * volatile * volatile * volatile * volatile g_1969 = &g_1970; static uint8_t *** const **g_1982 = (void*)0; static int64_t g_2181[6] = {0xCCB4F7BC72EA1289LL,0L,2L,2L,0xCCB4F7BC72EA1289LL,2L}; static int32_t ***g_2188 = &g_217; static int32_t ****g_2187 = &g_2188; static uint32_t g_2306[2][1] = {{0xF5C7731CL},{0xF5C7731CL}}; static int8_t g_2365 = 0x5EL; static int32_t *g_2366 = (void*)0; static int64_t g_2385 = 3L; static uint16_t g_2398 = 0xAFCFL; static volatile uint16_t * const **g_2401 = (void*)0; static volatile uint16_t * const ** volatile *g_2400 = &g_2401; static volatile uint16_t * const ** volatile * volatile *g_2399[8] = {&g_2400,&g_2400,&g_2400,&g_2400,&g_2400,&g_2400,&g_2400,&g_2400}; static uint16_t ***g_2425 = &g_785; static uint8_t **g_2446 = &g_800; static uint8_t ***g_2445 = &g_2446; static uint8_t ****g_2444 = &g_2445; static uint8_t ***** const volatile g_2443 = &g_2444; static int8_t g_2547[8][9][3] = {{{9L,0x9EL,8L},{(-1L),0xA6L,0x71L},{0x29L,0xEFL,0x99L},{0L,0x23L,0x39L},{0xB4L,0x77L,9L},{0x5EL,0x39L,7L},{(-10L),0x40L,0x5EL},{0x84L,0xB4L,0L},{0x98L,2L,(-1L)}},{{0x32L,0xBDL,9L},{(-2L),0x20L,7L},{0L,7L,0L},{0x55L,2L,(-3L)},{0x44L,0x55L,0L},{(-1L),0xAFL,(-1L)},{0x3EL,(-3L),1L},{1L,0x20L,0xA6L},{(-1L),0x1FL,0xFAL}},{{0xDCL,7L,0x9EL},{(-1L),(-1L),0x40L},{1L,(-1L),(-5L)},{0x3EL,0xD5L,0x69L},{(-1L),2L,(-1L)},{0x44L,0x2DL,(-10L)},{0x55L,0xABL,0x06L},{0L,(-10L),9L},{(-2L),0xC0L,0xAEL}},{{0x32L,0x7BL,(-5L)},{0x98L,0x84L,0x42L},{0x84L,0xDCL,0x9CL},{(-10L),0L,0x77L},{0x5EL,0x06L,0L},{0xB4L,0x86L,(-4L)},{0L,0L,2L},{0x29L,0x24L,2L},{(-1L),0x10L,0xE8L}},{{9L,0x10L,(-10L)},{9L,0x24L,(-10L)},{0x40L,0L,1L},{0x93L,0x86L,2L},{7L,0x06L,2L},{0x76L,0L,0x7BL},{0x9EL,0xDCL,0x2DL},{0xABL,0x84L,0xCFL},{0x9CL,0x7BL,0L}},{{0xF6L,0xC0L,(-3L)},{(-10L),(-10L),0x29L},{(-1L),0xABL,0L},{0x0DL,0x2DL,0xBDL},{0xA9L,2L,0x3EL},{0xD5L,0xD5L,0xB6L},{0xFAL,(-1L),0x09L},{0x1FL,(-1L),0x76L},{0xC0L,7L,0x98L}},{{(-5L),0x1FL,0x76L},{0x06L,0x20L,0x09L},{0x9DL,(-3L),0xB6L},{7L,0xAFL,0x3EL},{2L,0x55L,0xBDL},{0L,2L,0xB6L},{0x44L,0xE8L,0x97L},{9L,1L,0x7BL},{0xABL,(-1L),0x8CL}},{{2L,0L,0x90L},{7L,0x76L,0xF6L},{0x29L,(-8L),9L},{0x7BL,0xFAL,9L},{8L,0x24L,2L},{(-5L),0x7FL,0x23L},{(-4L),0xABL,0x24L},{0xB6L,0x23L,0x9EL},{0xDCL,0x84L,0L}}}; static volatile int16_t g_2562 = 1L; static uint32_t **g_2574 = &g_1127; static uint32_t ***g_2573 = &g_2574; static volatile int32_t g_2625 = (-3L); static const int32_t ** volatile g_2692 = &g_343; static uint32_t g_2713 = 3UL; static const int16_t g_2778 = 0x085FL; static uint16_t ****g_2805 = &g_2425; static uint16_t *****g_2804 = &g_2805; static const int32_t ** volatile g_2814[4] = {&g_343,&g_343,&g_343,&g_343}; static const int32_t ** volatile g_2815 = &g_343; static uint16_t g_2844 = 0x3A68L; static int32_t ** volatile g_2845[8][7] = {{&g_2366,&g_139,&g_26,&g_139,&g_2366,&g_139,&g_139},{&g_139,&g_139,&g_26,&g_139,&g_139,&g_2366,&g_26},{&g_26,&g_139,&g_26,&g_26,&g_2366,&g_2366,(void*)0},{&g_139,&g_139,&g_2366,(void*)0,&g_2366,&g_139,&g_139},{&g_2366,&g_139,&g_26,&g_139,&g_139,&g_139,&g_26},{&g_26,&g_139,(void*)0,&g_26,(void*)0,&g_26,&g_139},{&g_26,&g_139,&g_26,&g_2366,&g_139,&g_2366,&g_26},{&g_139,&g_139,&g_2366,&g_2366,&g_2366,&g_26,&g_2366}}; static int32_t ** const volatile g_2847 = &g_139; static int16_t g_2867 = 0x6782L; static uint64_t g_2869 = 18446744073709551615UL; static volatile int32_t g_3028[9] = {(-1L),(-1L),0L,(-1L),(-1L),0L,(-1L),(-1L),0L}; static int32_t ** volatile *g_3067 = &g_1326; static int32_t ** volatile ** volatile g_3066 = &g_3067; static int32_t g_3108[5] = {0x0FD82E12L,0x0FD82E12L,0x0FD82E12L,0x0FD82E12L,0x0FD82E12L}; static volatile uint8_t g_3115 = 0xEFL; static const int32_t g_3201 = 0xC5A37E13L; static uint64_t *****g_3206[9][9][3] = {{{(void*)0,&g_1605,&g_1605},{&g_1605,&g_1605,(void*)0},{&g_1605,&g_1605,(void*)0},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{(void*)0,&g_1605,&g_1605}},{{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,(void*)0},{&g_1605,(void*)0,(void*)0},{&g_1605,(void*)0,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605}},{{&g_1605,&g_1605,&g_1605},{(void*)0,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{(void*)0,&g_1605,(void*)0}},{{&g_1605,(void*)0,(void*)0},{&g_1605,(void*)0,&g_1605},{(void*)0,&g_1605,&g_1605},{&g_1605,&g_1605,(void*)0},{(void*)0,(void*)0,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,(void*)0,&g_1605},{(void*)0,(void*)0,&g_1605},{(void*)0,&g_1605,(void*)0}},{{&g_1605,&g_1605,&g_1605},{(void*)0,(void*)0,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,(void*)0},{&g_1605,&g_1605,(void*)0},{&g_1605,&g_1605,&g_1605},{(void*)0,&g_1605,&g_1605}},{{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{(void*)0,(void*)0,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,(void*)0},{(void*)0,&g_1605,(void*)0},{&g_1605,&g_1605,&g_1605}},{{&g_1605,&g_1605,&g_1605},{&g_1605,(void*)0,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,(void*)0},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605}},{{&g_1605,(void*)0,(void*)0},{(void*)0,&g_1605,&g_1605},{(void*)0,(void*)0,&g_1605},{&g_1605,&g_1605,(void*)0},{&g_1605,&g_1605,(void*)0},{(void*)0,&g_1605,&g_1605},{(void*)0,&g_1605,(void*)0},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,(void*)0}},{{&g_1605,&g_1605,&g_1605},{&g_1605,(void*)0,(void*)0},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{(void*)0,&g_1605,&g_1605},{&g_1605,&g_1605,&g_1605},{(void*)0,&g_1605,&g_1605}}}; static uint8_t func_1(void); static int32_t * func_2(uint32_t p_3, int32_t * p_4); static int32_t * func_6(int32_t * p_7, uint16_t p_8); static int32_t * func_9(int32_t * p_10, uint64_t p_11, uint8_t p_12); static int64_t func_14(int32_t * p_15, int32_t * p_16); static int32_t * func_17(uint32_t p_18, int32_t p_19, uint16_t p_20, int32_t p_21, int32_t * p_22); static const uint64_t func_30(int32_t p_31, int32_t * p_32, uint64_t p_33); static const uint32_t func_41(uint32_t p_42, int32_t p_43, int32_t * p_44, int64_t p_45); static uint16_t func_50(uint32_t p_51, const int32_t * p_52, int32_t * p_53, int32_t * p_54); static const int32_t * func_55(int32_t * p_56, uint32_t p_57, int32_t * p_58); # 161 "gh.c" static uint8_t func_1(void) { int32_t l_5[10][10] = {{2L,6L,(-3L),(-1L),0x0693009CL,2L,(-1L),1L,(-1L),2L},{0x0693009CL,6L,(-3L),6L,0x0693009CL,0x9D568D52L,6L,1L,0x45625132L,0x0693009CL},{0x0693009CL,(-1L),(-3L),6L,2L,0x45625132L,0x4D513C61L,0L,(-4L),(-1L)},{0x45625132L,0x4D513C61L,0L,(-4L),(-1L),0x45625132L,(-4L),0x48C443EBL,(-4L),0x45625132L},{(-1L),0x4D513C61L,0x11738AB6L,0x4D513C61L,(-1L),6L,0x4D513C61L,0x48C443EBL,0x8588D0D3L,(-1L)},{(-1L),(-4L),0L,0x4D513C61L,0x45625132L,0x45625132L,0x4D513C61L,0L,(-4L),(-1L)},{0x45625132L,0x4D513C61L,0L,(-4L),(-1L),0x45625132L,(-4L),0x48C443EBL,(-4L),0x45625132L},{(-1L),0x4D513C61L,0x11738AB6L,0x4D513C61L,(-1L),6L,0x4D513C61L,0x48C443EBL,0x8588D0D3L,(-1L)},{(-1L),(-4L),0L,0x4D513C61L,0x45625132L,0x45625132L,0x4D513C61L,0L,(-4L),(-1L)},{0x45625132L,0x4D513C61L,0L,(-4L),(-1L),0x45625132L,(-4L),0x48C443EBL,(-4L),0x45625132L}}; int32_t *l_13 = (void*)0; uint8_t *l_137 = &g_138; uint16_t l_3270 = 7UL; int32_t l_3271[2]; int8_t l_3272[8] = {0x56L,0x56L,0x56L,0x56L,0x56L,0x56L,0x56L,0x56L}; uint32_t l_3273 = 0UL; int32_t **l_3274 = &g_26; int i, j; for (i = 0; i < 2; i++) l_3271[i] = 0x0; l_13 = func_2(l_5[3][2], func_6(func_9(l_13, (func_14(func_17((safe_mod_func_uint32_t_u_u(((g_25[0][1] , (g_26 == &g_27[1])) || (safe_mod_func_uint64_t_u_u(func_30((safe_mod_func_uint8_t_u_u(((*l_137) = (safe_mod_func_uint16_t_u_u((~(safe_add_func_uint32_t_u_u(func_41(l_5[3][2], (safe_mul_func_int8_t_s_s(g_25[0][1], (safe_mod_func_uint16_t_u_u(func_50(g_27[1], func_55(&g_27[0], g_27[2], &g_27[0]), &l_5[6][4], &g_27[2]), g_135[1][7][3])))), &l_5[3][2], g_135[1][7][3]), 0x86A65F44L))), g_135[1][7][3]))), g_135[1][7][3])), g_139, g_140), g_140))), 0x783B51D9L)), (*g_139), g_140, l_5[1][3], &l_5[3][2]), &l_5[1][8]) == l_5[6][3]), l_5[3][2]), l_5[6][5])); (*l_3274) = func_6(&l_5[4][6], (((255UL && (((((*g_139) ^= (safe_div_func_int16_t_s_s((((safe_mul_func_uint8_t_u_u((***g_2445), (safe_rshift_func_uint16_t_u_u((safe_mul_func_int16_t_s_s((safe_mod_func_uint32_t_u_u((0x170FB8DAF270ED14LL < (0xDBL && (**g_1716))), (safe_rshift_func_uint8_t_u_s((safe_lshift_func_uint16_t_u_u(((!((safe_lshift_func_uint8_t_u_u((safe_mod_func_uint8_t_u_u((l_3270 , l_3271[0]), l_3272[6])), 5)) | 0x7AL)) >= (**g_258)), l_3272[6])), (***g_1715))))), (*g_1323))), (***g_2425))))) != (***g_2445)) , (*g_1323)), (**g_785)))) != (**g_2574)) && l_3273) , (**g_2446))) > l_3273) < (**g_2446))); return (*g_800); } static int32_t * func_2(uint32_t p_3, int32_t * p_4) { int32_t l_2529 = 0L; int32_t l_2532 = 0L; int64_t *l_2549[10] = {(void*)0,(void*)0,(void*)0,(void*)0,(void*)0,(void*)0,(void*)0,(void*)0,(void*)0,(void*)0}; int64_t l_2560 = 0x003F100ACFC79905LL; int32_t l_2561 = 0x9849C498L; int32_t l_2563 = 1L; int32_t l_2564 = (-6L); int32_t l_2565 = 0x9884255DL; int32_t l_2566[6] = {1L,1L,1L,1L,1L,1L}; uint16_t l_2567 = 0x8982L; uint16_t ***l_2689 = &g_785; volatile uint32_t * volatile * volatile * volatile * volatile *l_2746 = &g_1969; uint16_t *****l_2806 = &g_2805; uint32_t l_2812[5] = {4294967295UL,4294967295UL,4294967295UL,4294967295UL,4294967295UL}; int8_t *l_2818 = &g_2547[6][3][2]; int16_t * const *l_2863 = &g_1323; uint8_t l_2915 = 255UL; const uint16_t l_2932[3][10] = {{65534UL,1UL,65528UL,1UL,65528UL,1UL,65534UL,0x2705L,1UL,1UL},{65534UL,1UL,3UL,0xB7CEL,0xB7CEL,3UL,1UL,65534UL,1UL,0x2705L},{3UL,1UL,65534UL,1UL,0x2705L,1UL,65534UL,1UL,3UL,0xB7CEL}}; int32_t l_3031 = 8L; const uint64_t l_3107 = 0x1FFC779A4AC333F7LL; int32_t * const l_3141 = (void*)0; int32_t *l_3163 = &g_3108[1]; uint8_t **l_3217 = &g_800; int i, j; if (((l_2532 = 9L) | g_1299[2][0])) { uint16_t ****l_2551[8]; uint16_t *****l_2550 = &l_2551[4]; int32_t l_2552 = 0x251325A8L; int32_t l_2557 = 0xE51A943FL; int32_t *l_2558 = &l_2552; int32_t *l_2559[5][1] = {{&g_27[1]},{(void*)0},{&g_27[1]},{(void*)0},{&g_27[1]}}; uint32_t ***l_2575 = &g_2574; int8_t ****l_2579[3][10][8] = {{{&g_1718,&g_1718,&g_1718,(void*)0,&g_1715,(void*)0,&g_1715,(void*)0},{&g_1715,&g_1718,&g_1718,&g_1718,&g_1715,(void*)0,&g_1715,&g_1718},{&g_1715,&g_1718,(void*)0,&g_1715,&g_1718,(void*)0,(void*)0,&g_1718},{&g_1715,&g_1718,(void*)0,&g_1715,(void*)0,&g_1715,&g_1715,&g_1718},{&g_1718,&g_1718,&g_1718,&g_1718,&g_1715,&g_1715,&g_1715,&g_1715},{(void*)0,&g_1718,&g_1718,(void*)0,&g_1718,&g_1715,&g_1718,&g_1715},{&g_1715,&g_1718,&g_1718,&g_1715,(void*)0,&g_1715,(void*)0,&g_1715},{&g_1715,(void*)0,&g_1718,&g_1718,(void*)0,&g_1718,&g_1718,&g_1718},{&g_1718,&g_1718,&g_1718,&g_1715,&g_1715,&g_1718,&g_1718,&g_1718},{&g_1718,&g_1718,&g_1718,(void*)0,&g_1718,&g_1718,&g_1715,&g_1718}},{{&g_1718,(void*)0,&g_1718,(void*)0,(void*)0,&g_1718,&g_1718,&g_1715},{&g_1718,&g_1718,(void*)0,&g_1715,(void*)0,&g_1718,(void*)0,&g_1715},{&g_1715,&g_1718,&g_1718,&g_1715,&g_1715,&g_1718,(void*)0,&g_1715},{&g_1715,(void*)0,&g_1718,&g_1718,&g_1715,&g_1715,&g_1718,&g_1715},{&g_1715,&g_1718,&g_1715,&g_1718,&g_1718,&g_1718,&g_1715,(void*)0},{(void*)0,&g_1715,(void*)0,&g_1718,&g_1715,&g_1715,&g_1715,&g_1718},{&g_1718,&g_1715,&g_1718,&g_1715,&g_1718,&g_1715,&g_1718,&g_1718},{&g_1718,(void*)0,&g_1715,&g_1715,&g_1718,(void*)0,&g_1718,(void*)0},{&g_1718,(void*)0,(void*)0,(void*)0,&g_1718,&g_1715,&g_1718,&g_1718},{&g_1718,&g_1715,&g_1718,&g_1715,&g_1715,&g_1718,(void*)0,&g_1715}},{{(void*)0,&g_1718,&g_1715,(void*)0,&g_1718,&g_1718,(void*)0,&g_1718},{&g_1715,&g_1718,(void*)0,&g_1715,&g_1715,&g_1718,(void*)0,&g_1715},{&g_1715,&g_1718,&g_1715,&g_1715,&g_1715,&g_1718,&g_1715,&g_1715},{&g_1715,(void*)0,&g_1718,&g_1718,(void*)0,&g_1715,&g_1718,&g_1715},{&g_1718,&g_1715,&g_1715,&g_1718,(void*)0,&g_1715,&g_1715,&g_1715},{&g_1718,&g_1715,&g_1718,&g_1718,&g_1718,(void*)0,&g_1715,&g_1715},{&g_1718,&g_1718,&g_1715,&g_1718,&g_1715,&g_1718,&g_1715,&g_1715},{&g_1718,&g_1715,&g_1715,&g_1715,(void*)0,&g_1715,&g_1718,&g_1715},{&g_1715,&g_1715,(void*)0,&g_1715,(void*)0,&g_1718,&g_1715,&g_1718},{&g_1715,&g_1715,(void*)0,(void*)0,&g_1718,&g_1715,&g_1715,&g_1715}}}; int8_t *****l_2578 = &l_2579[0][6][7]; uint32_t ***l_2589 = &g_2574; const int16_t l_2590 = 1L; uint8_t *l_2591 = &g_138; int i, j, k; for (i = 0; i < 8; i++) l_2551[i] = &g_2425; (**g_442) = (((*l_2591) &= (safe_sub_func_uint64_t_u_u((((!(l_2560 > ((((l_2575 = g_2573) != (((((*l_2578) = &g_1718) != (void*)0) <= (((*g_1127) = (safe_lshift_func_uint16_t_u_u((0UL < ((((safe_lshift_func_uint8_t_u_s((((***g_2425) &= ((*l_2558) = (!(((safe_rshift_func_int16_t_s_s(0L, 14)) ^ (l_2566[5] &= (0x7D15100DL == ((p_3 , ((safe_add_func_int16_t_s_s((*g_1323), 0xA98EL)) | l_2565)) ^ p_3)))) ^ p_3)))) && l_2532), 1)) , p_3) ^ 65535UL) != (**g_799))), l_2529))) > l_2561)) , l_2589)) < l_2590) , 0x39F0F953L))) == 1UL) || 0xD9F7L), 18446744073709551615UL))) & 0x52L); } return p_4; } static int32_t * func_6(int32_t * p_7, uint16_t p_8) { const uint32_t *l_2466 = &g_2306[1][0]; const uint32_t **l_2465 = &l_2466; int32_t l_2472 = 0x756A63D8L; int16_t *l_2482 = &g_1752[0][0]; uint8_t * const *l_2484 = (void*)0; uint8_t * const **l_2483 = &l_2484; int32_t l_2485 = 0x324DE21BL; int32_t l_2486[3][1][4] = {{{0x5B6543DAL,0x5B6543DAL,0x98335532L,0x5B6543DAL}},{{0x5B6543DAL,(-9L),(-9L),0x5B6543DAL}},{{(-9L),0x5B6543DAL,(-9L),(-9L)}}}; int32_t * const *l_2519 = &g_2366; int32_t * const **l_2518 = &l_2519; int32_t * const ***l_2517[8] = {&l_2518,&l_2518,&l_2518,&l_2518,&l_2518,&l_2518,&l_2518,&l_2518}; int32_t * const ****l_2520 = &l_2517[4]; const int32_t ****l_2521 = (void*)0; const int32_t *****l_2522 = (void*)0; const int32_t *****l_2523 = &l_2521; int32_t l_2524 = 9L; int i, j, k; l_2486[1][0][1] |= ((safe_mod_func_uint16_t_u_u(((!((((((safe_lshift_func_int8_t_s_s((safe_mul_func_int8_t_s_s(((safe_mod_func_int8_t_s_s((safe_sub_func_int32_t_s_s(((safe_sub_func_uint32_t_u_u((((*g_1323) != ((safe_sub_func_uint8_t_u_u(((safe_add_func_int32_t_s_s((l_2465 == &l_2466), (***g_1970))) & (safe_sub_func_uint8_t_u_u(((safe_sub_func_int32_t_s_s((((safe_unary_minus_func_int64_t_s((l_2472 = p_8))) , (safe_rshift_func_uint16_t_u_u((***g_2425), (((safe_lshift_func_uint8_t_u_u((safe_mod_func_int8_t_s_s((((safe_unary_minus_func_int8_t_s((((safe_rshift_func_uint16_t_u_u((((*l_2482) = (-5L)) , p_8), (((void*)0 != l_2483) & 0x04A1L))) <= l_2472) <= 0xE3L))) , 0x791ECC3AL) , 0L), l_2472)), (*g_800))) > 0x0F66L) & p_8)))) == l_2485), l_2485)) & (**g_1421)), (**g_1716)))), l_2485)) != (-1L))) != 0x0CB4F071L), (*g_139))) > p_8), l_2485)), 0xD0L)) & (*g_186)), p_8)), (**g_1716))) && 4UL) > l_2485) , p_8) <= (*g_800)) , l_2485)) , p_8), (*g_1323))) | 0UL); return p_7; } static int32_t * func_9(int32_t * p_10, uint64_t p_11, uint8_t p_12) { return 0; } static int64_t func_14(int32_t * p_15, int32_t * p_16) { return 0; } static int32_t * func_17(uint32_t p_18, int32_t p_19, uint16_t p_20, int32_t p_21, int32_t * p_22) { return 0; } static const uint64_t func_30(int32_t p_31, int32_t * p_32, uint64_t p_33) { return 0; } static const uint32_t func_41(uint32_t p_42, int32_t p_43, int32_t * p_44, int64_t p_45) { return 0; } static uint16_t func_50(uint32_t p_51, const int32_t * p_52, int32_t * p_53, int32_t * p_54) { return 0; } static const int32_t * func_55(int32_t * p_56, uint32_t p_57, int32_t * p_58) { return 0; } int main (int argc, char* argv[]) { int i, j, k; func_1(); return 0; }