// This file is part of the SV-Benchmarks collection of verification tasks: // https://gitlab.com/sosy-lab/benchmarking/sv-benchmarks // // SPDX-FileCopyrightText: 2013 Carnegie Mellon University // SPDX-FileCopyrightText: 2014-2021 The SV-Benchmarks Community // SPDX-FileCopyrightText: 2018 Marie-Christine Jakobs, LMU Munich // // SPDX-License-Identifier: LicenseRef-BSD-3-Clause-Attribution-CMU-LMU int __return_main; void abort(void); extern void __assert_fail(const char *, const char *, unsigned int, const char *) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); void reach_error() { __assert_fail("0", "pals_lcr-var-start-time.5.ufo.BOUNDED-10.pals.c.v+nlh-reducer.c", 4, "reach_error"); } _Bool __VERIFIER_nondet_bool(); char __VERIFIER_nondet_char(); void assert(_Bool arg); void abort(void); void assume_abort_if_not(int cond) { if(!cond) {abort();} } typedef char msg_t; typedef int port_t; void read(port_t p, msg_t m); void write(port_t p, msg_t m); msg_t nomsg = (msg_t )-1; char r1 = '\x0'; port_t p1 = 0; char p1_old = '\x0'; char p1_new = '\x0'; char id1 = '\x0'; char st1 = '\x0'; msg_t send1 = '\x0'; _Bool mode1 = 0; _Bool alive1 = 0; port_t p2 = 0; char p2_old = '\x0'; char p2_new = '\x0'; char id2 = '\x0'; char st2 = '\x0'; msg_t send2 = '\x0'; _Bool mode2 = 0; _Bool alive2 = 0; port_t p3 = 0; char p3_old = '\x0'; char p3_new = '\x0'; char id3 = '\x0'; char st3 = '\x0'; msg_t send3 = '\x0'; _Bool mode3 = 0; _Bool alive3 = 0; port_t p4 = 0; char p4_old = '\x0'; char p4_new = '\x0'; char id4 = '\x0'; char st4 = '\x0'; msg_t send4 = '\x0'; _Bool mode4 = 0; _Bool alive4 = 0; port_t p5 = 0; char p5_old = '\x0'; char p5_new = '\x0'; char id5 = '\x0'; char st5 = '\x0'; msg_t send5 = '\x0'; _Bool mode5 = 0; _Bool alive5 = 0; void node1(); void node2(); void node3(); void node4(); void node5(); void (*nodes[5])() = { &node1, &node2, &node3, &node4, &node5 }; int init(); int check(); int main(); int __return_59281; int __return_59401; int __tmp_59560_0; int __return_59592; int __return_59606; int main() { int main__c1; int main__i2; main__c1 = 0; r1 = __VERIFIER_nondet_char(); id1 = __VERIFIER_nondet_char(); st1 = __VERIFIER_nondet_char(); send1 = __VERIFIER_nondet_char(); mode1 = __VERIFIER_nondet_bool(); alive1 = __VERIFIER_nondet_bool(); id2 = __VERIFIER_nondet_char(); st2 = __VERIFIER_nondet_char(); send2 = __VERIFIER_nondet_char(); mode2 = __VERIFIER_nondet_bool(); alive2 = __VERIFIER_nondet_bool(); id3 = __VERIFIER_nondet_char(); st3 = __VERIFIER_nondet_char(); send3 = __VERIFIER_nondet_char(); mode3 = __VERIFIER_nondet_bool(); alive3 = __VERIFIER_nondet_bool(); id4 = __VERIFIER_nondet_char(); st4 = __VERIFIER_nondet_char(); send4 = __VERIFIER_nondet_char(); mode4 = __VERIFIER_nondet_bool(); alive4 = __VERIFIER_nondet_bool(); id5 = __VERIFIER_nondet_char(); st5 = __VERIFIER_nondet_char(); send5 = __VERIFIER_nondet_char(); mode5 = __VERIFIER_nondet_bool(); alive5 = __VERIFIER_nondet_bool(); { int init__tmp; if (((int)r1) == 0) { if (((((((int)alive1) + ((int)alive2)) + ((int)alive3)) + ((int)alive4)) + ((int)alive5)) >= 1) { if (((int)id1) >= 0) { if (((int)st1) == 0) { if (((int)send1) == ((int)id1)) { if (((int)mode1) == 0) { if (((int)id2) >= 0) { if (((int)st2) == 0) { if (((int)send2) == ((int)id2)) { if (((int)mode2) == 0) { if (((int)id3) >= 0) { if (((int)st3) == 0) { if (((int)send3) == ((int)id3)) { if (((int)mode3) == 0) { if (((int)id4) >= 0) { if (((int)st4) == 0) { if (((int)send4) == ((int)id4)) { if (((int)mode4) == 0) { if (((int)id5) >= 0) { if (((int)st5) == 0) { if (((int)send5) == ((int)id5)) { if (((int)mode5) == 0) { if (((int)id1) != ((int)id2)) { if (((int)id1) != ((int)id3)) { if (((int)id1) != ((int)id4)) { if (((int)id1) != ((int)id5)) { if (((int)id2) != ((int)id3)) { if (((int)id2) != ((int)id4)) { if (((int)id2) != ((int)id5)) { if (((int)id3) != ((int)id4)) { if (((int)id3) != ((int)id5)) { if (((int)id4) != ((int)id5)) { init__tmp = 1; __return_59281 = init__tmp; main__i2 = __return_59281; if (main__i2 != 0) { p1_old = nomsg; p1_new = nomsg; p2_old = nomsg; p2_new = nomsg; p3_old = nomsg; p3_new = nomsg; p4_old = nomsg; p4_new = nomsg; p5_old = nomsg; p5_new = nomsg; main__i2 = 0; if (main__i2 < 10) { { msg_t node1__m1; node1__m1 = nomsg; if (!(mode1 == 0)) { return __return_main; } else { if (!(alive1 == 0)) { int node1____CPAchecker_TMP_0; if (send1 != nomsg) { if (p1_new == nomsg) { node1____CPAchecker_TMP_0 = send1; label_59308:; p1_new = node1____CPAchecker_TMP_0; label_59310:; mode1 = 1; { msg_t node2__m2; node2__m2 = nomsg; if (!(mode2 == 0)) { return __return_main; } else { if (!(alive2 == 0)) { int node2____CPAchecker_TMP_0; if (send2 != nomsg) { if (p2_new == nomsg) { node2____CPAchecker_TMP_0 = send2; label_59325:; p2_new = node2____CPAchecker_TMP_0; label_59327:; mode2 = 1; { msg_t node3__m3; node3__m3 = nomsg; if (!(mode3 == 0)) { return __return_main; } else { if (!(alive3 == 0)) { int node3____CPAchecker_TMP_0; if (send3 != nomsg) { if (p3_new == nomsg) { node3____CPAchecker_TMP_0 = send3; label_59342:; p3_new = node3____CPAchecker_TMP_0; label_59344:; mode3 = 1; { msg_t node4__m4; node4__m4 = nomsg; if (!(mode4 == 0)) { return __return_main; } else { if (!(alive4 == 0)) { int node4____CPAchecker_TMP_0; if (send4 != nomsg) { if (p4_new == nomsg) { node4____CPAchecker_TMP_0 = send4; label_59359:; p4_new = node4____CPAchecker_TMP_0; label_59361:; mode4 = 1; { msg_t node5__m5; node5__m5 = nomsg; if (!(mode5 == 0)) { return __return_main; } else { if (!(alive5 == 0)) { int node5____CPAchecker_TMP_0; if (send5 != nomsg) { if (p5_new == nomsg) { node5____CPAchecker_TMP_0 = send5; label_59376:; p5_new = node5____CPAchecker_TMP_0; label_59378:; mode5 = 1; p1_old = p1_new; p1_new = nomsg; p2_old = p2_new; p2_new = nomsg; p3_old = p3_new; p3_new = nomsg; p4_old = p4_new; p4_new = nomsg; p5_old = p5_new; p5_new = nomsg; { int check__tmp; if (((((((int)st1) + ((int)st2)) + ((int)st3)) + ((int)st4)) + ((int)st5)) <= 1) { if (((int)r1) < 5) { check__tmp = 1; __return_59401 = check__tmp; main__c1 = __return_59401; { _Bool __tmp_1; __tmp_1 = main__c1; _Bool assert__arg; assert__arg = __tmp_1; if (assert__arg == 0) { return __return_main; } else { int main____CPAchecker_TMP_0 = main__i2; main__i2 = main__i2 + 1; if (main__i2 < 10) { { msg_t node1__m1; node1__m1 = nomsg; if (!(mode1 == 0)) { r1 = (char)(((int)r1) + 1); node1__m1 = p5_old; p5_old = nomsg; if (((int)node1__m1) != ((int)nomsg)) { if (!(alive1 == 0)) { if (((int)node1__m1) > ((int)id1)) { send1 = node1__m1; label_59807:; label_59421:; mode1 = 0; { msg_t node2__m2; node2__m2 = nomsg; if (!(mode2 == 0)) { node2__m2 = p1_old; p1_old = nomsg; if (((int)node2__m2) != ((int)nomsg)) { if (!(alive2 == 0)) { if (((int)node2__m2) > ((int)id2)) { send2 = node2__m2; label_59891:; label_59433:; mode2 = 0; { msg_t node3__m3; node3__m3 = nomsg; if (!(mode3 == 0)) { node3__m3 = p2_old; p2_old = nomsg; if (((int)node3__m3) != ((int)nomsg)) { if (!(alive3 == 0)) { if (((int)node3__m3) > ((int)id3)) { send3 = node3__m3; label_59871:; label_59445:; mode3 = 0; { msg_t node4__m4; node4__m4 = nomsg; if (!(mode4 == 0)) { node4__m4 = p3_old; p3_old = nomsg; if (((int)node4__m4) != ((int)nomsg)) { if (!(alive4 == 0)) { if (((int)node4__m4) > ((int)id4)) { send4 = node4__m4; label_59851:; label_59457:; mode4 = 0; __tmp_59560_0 = main____CPAchecker_TMP_0; label_59560:; main____CPAchecker_TMP_0 = __tmp_59560_0; { msg_t node5__m5; node5__m5 = nomsg; if (!(mode5 == 0)) { node5__m5 = p4_old; p4_old = nomsg; if (((int)node5__m5) != ((int)nomsg)) { if (!(alive5 == 0)) { if (((int)node5__m5) > ((int)id5)) { send5 = node5__m5; label_59665:; label_59570:; mode5 = 0; label_59572:; p1_old = p1_new; p1_new = nomsg; p2_old = p2_new; p2_new = nomsg; p3_old = p3_new; p3_new = nomsg; p4_old = p4_new; p4_new = nomsg; p5_old = p5_new; p5_new = nomsg; { int check__tmp; if (((((((int)st1) + ((int)st2)) + ((int)st3)) + ((int)st4)) + ((int)st5)) <= 1) { if (((int)r1) < 5) { check__tmp = 1; label_59656:; label_59591:; __return_59592 = check__tmp; main__c1 = __return_59592; { _Bool __tmp_2; __tmp_2 = main__c1; _Bool assert__arg; assert__arg = __tmp_2; if (assert__arg == 0) { {reach_error();} return __return_main; } else { int main____CPAchecker_TMP_0 = main__i2; main__i2 = main__i2 + 1; if (main__i2 < 10) { { msg_t node1__m1; node1__m1 = nomsg; if (!(mode1 == 0)) { r1 = (char)(((int)r1) + 1); node1__m1 = p5_old; p5_old = nomsg; if (((int)node1__m1) != ((int)nomsg)) { if (!(alive1 == 0)) { if (((int)node1__m1) > ((int)id1)) { send1 = node1__m1; label_59627:; label_59617:; mode1 = 0; label_59619:; { msg_t node2__m2; node2__m2 = nomsg; if (!(mode2 == 0)) { node2__m2 = p1_old; p1_old = nomsg; if (((int)node2__m2) != ((int)nomsg)) { if (!(alive2 == 0)) { if (((int)node2__m2) > ((int)id2)) { send2 = node2__m2; label_59749:; label_59528:; mode2 = 0; label_59530:; { msg_t node3__m3; node3__m3 = nomsg; if (!(mode3 == 0)) { node3__m3 = p2_old; p2_old = nomsg; if (((int)node3__m3) != ((int)nomsg)) { if (!(alive3 == 0)) { if (((int)node3__m3) > ((int)id3)) { send3 = node3__m3; label_59721:; label_59542:; mode3 = 0; label_59544:; { msg_t node4__m4; node4__m4 = nomsg; if (!(mode4 == 0)) { node4__m4 = p3_old; p3_old = nomsg; if (((int)node4__m4) != ((int)nomsg)) { if (!(alive4 == 0)) { if (((int)node4__m4) > ((int)id4)) { send4 = node4__m4; label_59693:; label_59556:; mode4 = 0; label_59558:; __tmp_59560_0 = main____CPAchecker_TMP_0; goto label_59560; } else { if (((int)node4__m4) == ((int)id4)) { st4 = 1; goto label_59693; } else { goto label_59693; } } } else { send4 = node4__m4; goto label_59556; } } else { goto label_59556; } } else { if (!(alive4 == 0)) { int node4____CPAchecker_TMP_0; if (send4 != nomsg) { if (p4_new == nomsg) { node4____CPAchecker_TMP_0 = send4; label_59702:; p4_new = node4____CPAchecker_TMP_0; label_59704:; mode4 = 1; goto label_59558; } else { label_59701:; node4____CPAchecker_TMP_0 = p4_new; goto label_59702; } } else { goto label_59701; } } else { if (((int)send4) != ((int)id4)) { int node4____CPAchecker_TMP_1; if (send4 != nomsg) { if (p4_new == nomsg) { node4____CPAchecker_TMP_1 = send4; label_59712:; p4_new = node4____CPAchecker_TMP_1; goto label_59704; } else { label_59711:; node4____CPAchecker_TMP_1 = p4_new; goto label_59712; } } else { goto label_59711; } } else { goto label_59704; } } } } } else { if (((int)node3__m3) == ((int)id3)) { st3 = 1; goto label_59721; } else { goto label_59721; } } } else { send3 = node3__m3; goto label_59542; } } else { goto label_59542; } } else { if (!(alive3 == 0)) { int node3____CPAchecker_TMP_0; if (send3 != nomsg) { if (p3_new == nomsg) { node3____CPAchecker_TMP_0 = send3; label_59730:; p3_new = node3____CPAchecker_TMP_0; label_59732:; mode3 = 1; goto label_59544; } else { label_59729:; node3____CPAchecker_TMP_0 = p3_new; goto label_59730; } } else { goto label_59729; } } else { if (((int)send3) != ((int)id3)) { int node3____CPAchecker_TMP_1; if (send3 != nomsg) { if (p3_new == nomsg) { node3____CPAchecker_TMP_1 = send3; label_59740:; p3_new = node3____CPAchecker_TMP_1; goto label_59732; } else { label_59739:; node3____CPAchecker_TMP_1 = p3_new; goto label_59740; } } else { goto label_59739; } } else { goto label_59732; } } } } } else { if (((int)node2__m2) == ((int)id2)) { st2 = 1; goto label_59749; } else { goto label_59749; } } } else { send2 = node2__m2; goto label_59528; } } else { goto label_59528; } } else { if (!(alive2 == 0)) { int node2____CPAchecker_TMP_0; if (send2 != nomsg) { if (p2_new == nomsg) { node2____CPAchecker_TMP_0 = send2; label_59758:; p2_new = node2____CPAchecker_TMP_0; label_59760:; mode2 = 1; goto label_59530; } else { label_59757:; node2____CPAchecker_TMP_0 = p2_new; goto label_59758; } } else { goto label_59757; } } else { if (((int)send2) != ((int)id2)) { int node2____CPAchecker_TMP_1; if (send2 != nomsg) { if (p2_new == nomsg) { node2____CPAchecker_TMP_1 = send2; label_59768:; p2_new = node2____CPAchecker_TMP_1; goto label_59760; } else { label_59767:; node2____CPAchecker_TMP_1 = p2_new; goto label_59768; } } else { goto label_59767; } } else { goto label_59760; } } } } } else { if (((int)node1__m1) == ((int)id1)) { st1 = 1; goto label_59627; } else { goto label_59627; } } } else { send1 = node1__m1; goto label_59617; } } else { goto label_59617; } } else { if (!(alive1 == 0)) { int node1____CPAchecker_TMP_0; if (send1 != nomsg) { if (p1_new == nomsg) { node1____CPAchecker_TMP_0 = send1; label_59636:; p1_new = node1____CPAchecker_TMP_0; label_59638:; mode1 = 1; goto label_59619; } else { label_59635:; node1____CPAchecker_TMP_0 = p1_new; goto label_59636; } } else { goto label_59635; } } else { if (((int)send1) != ((int)id1)) { int node1____CPAchecker_TMP_1; if (send1 != nomsg) { if (p1_new == nomsg) { node1____CPAchecker_TMP_1 = send1; label_59646:; p1_new = node1____CPAchecker_TMP_1; goto label_59638; } else { label_59645:; node1____CPAchecker_TMP_1 = p1_new; goto label_59646; } } else { goto label_59645; } } else { goto label_59638; } } } } } else { __return_59606 = 0; return __return_59606; } } } } else { if (((((((int)st1) + ((int)st2)) + ((int)st3)) + ((int)st4)) + ((int)st5)) == 1) { check__tmp = 1; goto label_59656; } else { check__tmp = 0; goto label_59656; } } } else { check__tmp = 0; goto label_59591; } } } else { if (((int)node5__m5) == ((int)id5)) { st5 = 1; goto label_59665; } else { goto label_59665; } } } else { send5 = node5__m5; goto label_59570; } } else { goto label_59570; } } else { if (!(alive5 == 0)) { int node5____CPAchecker_TMP_0; if (send5 != nomsg) { if (p5_new == nomsg) { node5____CPAchecker_TMP_0 = send5; label_59674:; p5_new = node5____CPAchecker_TMP_0; label_59676:; mode5 = 1; goto label_59572; } else { label_59673:; node5____CPAchecker_TMP_0 = p5_new; goto label_59674; } } else { goto label_59673; } } else { if (((int)send5) != ((int)id5)) { int node5____CPAchecker_TMP_1; if (send5 != nomsg) { if (p5_new == nomsg) { node5____CPAchecker_TMP_1 = send5; label_59684:; p5_new = node5____CPAchecker_TMP_1; goto label_59676; } else { label_59683:; node5____CPAchecker_TMP_1 = p5_new; goto label_59684; } } else { goto label_59683; } } else { goto label_59676; } } } } } else { if (((int)node4__m4) == ((int)id4)) { st4 = 1; goto label_59851; } else { goto label_59851; } } } else { send4 = node4__m4; goto label_59457; } } else { goto label_59457; } } else { return __return_main; } } } else { if (((int)node3__m3) == ((int)id3)) { st3 = 1; goto label_59871; } else { goto label_59871; } } } else { send3 = node3__m3; goto label_59445; } } else { goto label_59445; } } else { return __return_main; } } } else { if (((int)node2__m2) == ((int)id2)) { st2 = 1; goto label_59891; } else { goto label_59891; } } } else { send2 = node2__m2; goto label_59433; } } else { goto label_59433; } } else { return __return_main; } } } else { if (((int)node1__m1) == ((int)id1)) { st1 = 1; goto label_59807; } else { goto label_59807; } } } else { send1 = node1__m1; goto label_59421; } } else { goto label_59421; } } else { return __return_main; } } } else { return __return_main; } } } } else { return __return_main; } } else { return __return_main; } } } else { return __return_main; } } else { node5____CPAchecker_TMP_0 = p5_new; goto label_59376; } } else { if (((int)send5) != ((int)id5)) { int node5____CPAchecker_TMP_1; if (send5 != nomsg) { if (p5_new == nomsg) { node5____CPAchecker_TMP_1 = send5; label_59816:; p5_new = node5____CPAchecker_TMP_1; goto label_59378; } else { return __return_main; } } else { node5____CPAchecker_TMP_1 = p5_new; goto label_59816; } } else { goto label_59378; } } } } } else { return __return_main; } } else { node4____CPAchecker_TMP_0 = p4_new; goto label_59359; } } else { if (((int)send4) != ((int)id4)) { int node4____CPAchecker_TMP_1; if (send4 != nomsg) { if (p4_new == nomsg) { node4____CPAchecker_TMP_1 = send4; label_59840:; p4_new = node4____CPAchecker_TMP_1; goto label_59361; } else { return __return_main; } } else { node4____CPAchecker_TMP_1 = p4_new; goto label_59840; } } else { goto label_59361; } } } } } else { return __return_main; } } else { node3____CPAchecker_TMP_0 = p3_new; goto label_59342; } } else { if (((int)send3) != ((int)id3)) { int node3____CPAchecker_TMP_1; if (send3 != nomsg) { if (p3_new == nomsg) { node3____CPAchecker_TMP_1 = send3; label_59860:; p3_new = node3____CPAchecker_TMP_1; goto label_59344; } else { return __return_main; } } else { node3____CPAchecker_TMP_1 = p3_new; goto label_59860; } } else { goto label_59344; } } } } } else { return __return_main; } } else { node2____CPAchecker_TMP_0 = p2_new; goto label_59325; } } else { if (((int)send2) != ((int)id2)) { int node2____CPAchecker_TMP_1; if (send2 != nomsg) { if (p2_new == nomsg) { node2____CPAchecker_TMP_1 = send2; label_59880:; p2_new = node2____CPAchecker_TMP_1; goto label_59327; } else { return __return_main; } } else { node2____CPAchecker_TMP_1 = p2_new; goto label_59880; } } else { goto label_59327; } } } } } else { return __return_main; } } else { node1____CPAchecker_TMP_0 = p1_new; goto label_59308; } } else { if (((int)send1) != ((int)id1)) { int node1____CPAchecker_TMP_1; if (send1 != nomsg) { if (p1_new == nomsg) { node1____CPAchecker_TMP_1 = send1; label_59919:; p1_new = node1____CPAchecker_TMP_1; goto label_59310; } else { return __return_main; } } else { node1____CPAchecker_TMP_1 = p1_new; goto label_59919; } } else { goto label_59310; } } } } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } else { return __return_main; } } }