Subversion Repositories HelenOS

Rev

Rev 2028 | Rev 2050 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 2028 Rev 2042
Line 88... Line 88...
88
       
88
       
89
        printf("Creating %d consumers and %d producers...", consumers, producers);
89
        printf("Creating %d consumers and %d producers...", consumers, producers);
90
   
90
   
91
        for (j = 0; j < (CONSUMERS + PRODUCERS) / 2; j++) {
91
        for (j = 0; j < (CONSUMERS + PRODUCERS) / 2; j++) {
92
            for (k = 0; k < i; k++) {
92
            for (k = 0; k < i; k++) {
93
                thrd = thread_create(consumer, NULL, TASK, 0, "consumer");
93
                thrd = thread_create(consumer, NULL, TASK, 0, "consumer", false);
94
                if (thrd)
94
                if (thrd)
95
                    thread_ready(thrd);
95
                    thread_ready(thrd);
96
                else
96
                else
97
                    printf("could not create consumer %d\n", i);
97
                    printf("could not create consumer %d\n", i);
98
            }
98
            }
99
            for (k = 0; k < (4 - i); k++) {
99
            for (k = 0; k < (4 - i); k++) {
100
                thrd = thread_create(producer, NULL, TASK, 0, "producer");
100
                thrd = thread_create(producer, NULL, TASK, 0, "producer", false);
101
                if (thrd)
101
                if (thrd)
102
                    thread_ready(thrd);
102
                    thread_ready(thrd);
103
                else
103
                else
104
                    printf("could not create producer %d\n", i);
104
                    printf("could not create producer %d\n", i);
105
            }
105
            }