source: rtems/c/src/tests/sptests/spsize/size.c @ c3bb68a1

4.104.114.84.95
Last change on this file since c3bb68a1 was c3bb68a1, checked in by Joel Sherrill <joel.sherrill@…>, on 07/04/02 at 16:23:52

2002-07-04 Joel Sherrill <joel@…>

  • Jump table for single entry point removed.
  • spsize/size.c: Modified to reflect above.
  • Property mode set to 100644
File size: 21.4 KB
Line 
1/*  main
2 *
3 *  This program is run to determine the data space and work space
4 *  requirements of the current version of RTEMS.
5 *
6 *  COPYRIGHT (c) 1989-1999.
7 *  On-Line Applications Research Corporation (OAR).
8 *
9 *  The license and distribution terms for this file may be
10 *  found in the file LICENSE in this distribution or at
11 *  http://www.OARcorp.com/rtems/license.html.
12 *
13 *  $Id$
14 */
15
16#include <rtems/system.h>
17#include <rtems/config.h>
18#include <rtems/score/apiext.h>
19#include <rtems/score/copyrt.h>
20#include <rtems/rtems/clock.h>
21#include <rtems/rtems/tasks.h>
22#include <rtems/rtems/dpmem.h>
23#include <rtems/rtems/event.h>
24#include <rtems/extension.h>
25#include <rtems/fatal.h>
26#include <rtems/init.h>
27#include <rtems/score/isr.h>
28#include <rtems/rtems/intr.h>
29#include <rtems/io.h>
30#include <rtems/rtems/message.h>
31#if defined(RTEMS_MULTIPROCESSING)
32#include <rtems/rtems/mp.h>
33#include <rtems/score/mpci.h>
34#endif
35#include <rtems/rtems/part.h>
36#include <rtems/score/priority.h>
37#include <rtems/rtems/ratemon.h>
38#include <rtems/rtems/region.h>
39#include <rtems/rtems/sem.h>
40#include <rtems/rtems/signal.h>
41#include <rtems/score/sysstate.h>
42#include <rtems/score/thread.h>
43#include <rtems/rtems/timer.h>
44#include <rtems/score/tod.h>
45#include <rtems/score/userext.h>
46#include <rtems/score/wkspace.h>
47
48#include <stdlib.h>
49
50/* These are always defined by the executive.
51 *
52 * #include <rtems/copyrt.h>
53 * #include <rtems/tables.h>
54 * #include <rtems/sptables.h>
55 */
56#define  HEAP_OVHD        16    /* wasted heap space per task stack */
57#define  NAME_PTR_SIZE     8    /* size of name and pointer table entries */
58#define  READYCHAINS_SIZE  \
59    ((RTEMS_MAXIMUM_PRIORITY + 1) * sizeof(Chain_Control ))
60
61#define PER_TASK      \
62     (long) (sizeof (Thread_Control) + \
63      NAME_PTR_SIZE + HEAP_OVHD + sizeof( RTEMS_API_Control ))
64#define PER_SEMAPHORE \
65     (long) (sizeof (Semaphore_Control) + NAME_PTR_SIZE)
66#define PER_TIMER     \
67     (long) (sizeof (Timer_Control) + NAME_PTR_SIZE)
68#define PER_MSGQ      \
69     (long) (sizeof (Message_queue_Control) + NAME_PTR_SIZE)
70#define PER_REGN      \
71     (long) (sizeof (Region_Control) + NAME_PTR_SIZE)
72#define PER_PART      \
73     (long) (sizeof (Partition_Control) + NAME_PTR_SIZE)
74#define PER_PERIOD      \
75     (long) (sizeof (Rate_monotonic_Control) + NAME_PTR_SIZE)
76#define PER_PORT      \
77     (long) (sizeof (Dual_ported_memory_Control) + NAME_PTR_SIZE)
78#define PER_EXTENSION     \
79     (long) (sizeof (Extension_Control) + NAME_PTR_SIZE)
80
81#define PER_DRV       (long) (0)
82#define PER_FPTASK    (long) (CONTEXT_FP_SIZE)
83#define PER_GOBTBL    (long) (sizeof (Chain_Control)*4)
84#define PER_NODE      (long) PER_GOBTBL
85#if defined(RTEMS_MULTIPROCESSING)
86#define PER_GOBJECT   (long) (sizeof (Objects_MP_Control))
87#else
88#define PER_GOBJECT   (long) 0
89#endif
90#define PER_PROXY     (long) (sizeof (Thread_Proxy_control))
91
92#if !defined(RTEMS_MULTIPROCESSING) || (CPU_ALL_TASKS_ARE_FP != TRUE)
93#define MPCI_RECEIVE_SERVER_FP (long) 0
94#else
95#define MPCI_RECEIVE_SERVER_FP (long) (sizeof( Context_Control_fp ))
96#endif
97
98#if (CPU_IDLE_TASK_IS_FP == TRUE)
99#define SYSTEM_IDLE_FP (long) (sizeof( Context_Control_fp ))
100#else
101#define SYSTEM_IDLE_FP (long) 0
102#endif
103
104#if !defined(RTEMS_MULTIPROCESSING)
105#define MPCI_RECEIVE_SERVER_STACK_SIZE 0
106#endif
107
108#if defined(RTEMS_MULTIPROCESSING)
109#define MP_SYSTEM_TASKS \
110   (MPCI_RECEIVE_SERVER_STACK_SIZE + \
111    sizeof(Thread_Control) + \
112    MPCI_RECEIVE_SERVER_FP)
113#else
114#define MP_SYSTEM_TASKS 0
115#endif
116
117/*
118 *  Idle and the MPCI Receive Server Threads
119 */
120
121#define SYSTEM_TASKS  \
122    (STACK_MINIMUM_SIZE + sizeof(Thread_Control) + SYSTEM_IDLE_FP + \
123     MP_SYSTEM_TASKS)
124
125#define rtems_unsigned32 unsigned32
126
127rtems_unsigned32 sys_req;
128
129/* to avoid warnings */
130int puts();
131int printf();
132int getint();
133#undef getchar
134int getchar();
135void help_size();
136void print_formula();
137
138void size_rtems(
139  int mode
140)
141{
142int uninitialized = 0;
143int initialized = 0;
144
145/*
146 *  The following data is allocated for each Manager:
147 *
148 *    + Per Manager Object Information
149 *      - local pointer table
150 *      - local name table
151 *      - the object's control blocks
152 *      - global name chains
153 *
154 *  The following is the data allocate from the RTEMS Workspace Area.
155 *  The order indicates the order in which RTEMS allocates it.
156 *
157 *    + Object MP
158 *      - Global Object CB's
159 *    + Thread
160 *      - Ready Chain
161 *    + Thread MP
162 *      - Proxies Chain
163 *    + Interrupt Manager
164 *      - Interrupt Stack
165 *    + Timer Manager
166 *      - per Manager Object Data
167 *    + Extension Manager
168 *      - per Manager Object Data
169 *    + Message Queue Manager
170 *      - per Manager Object Data
171 *      - Message Buffers
172 *    + Semaphore Manager
173 *      - per Manager Object Data
174 *    + Partition Manager
175 *      - per Manager Object Data
176 *    + Region Manager
177 *      - per Manager Object Data
178 *    + Dual Ported Memory Manager
179 *      - per Manager Object Data
180 *    + Rate Monotonic Manager
181 *      - per Manager Object Data
182 *    + Internal Threads Handler
183 *      - MPCI Receive Server Thread TCB
184 *      - IDLE Thread TCB
185 *      - MPCI Receive Server Thread stack
186 *      - MPCI Receive Server Thread FP area (if CPU requires this)
187 *      - IDLE Thread stack
188 *      - IDLE Thread FP area (if CPU requires this)
189 *
190 *  This does not take into account any CPU dependent alignment requirements.
191 *
192 *  The following calculates the overhead needed by RTEMS from the
193 *  Workspace Area.
194 */
195sys_req = SYSTEM_TASKS     +     /* MPCI Receive Server and IDLE */
196          NAME_PTR_SIZE    +     /* Task Overhead */
197          READYCHAINS_SIZE +     /* Ready Chains */
198          NAME_PTR_SIZE    +     /* Timer Overhead */
199          NAME_PTR_SIZE    +     /* Semaphore Overhead */
200          NAME_PTR_SIZE    +     /* Message Queue Overhead */
201          NAME_PTR_SIZE    +     /* Region Overhead */
202          NAME_PTR_SIZE    +     /* Partition Overhead */
203          NAME_PTR_SIZE    +     /* Dual-Ported Memory Overhead */
204          NAME_PTR_SIZE    +     /* Rate Monotonic Overhead */
205          NAME_PTR_SIZE    +     /* Extension Overhead */
206          PER_NODE;              /* Extra Gobject Table */
207
208uninitialized =
209/*address.h*/   0                                         +
210
211/*apiext.h*/    (sizeof _API_extensions_List)             +
212
213/*asr.h*/       0                                         +
214
215/*attr.h*/      0                                         +
216
217/*bitfield.h*/  0                                         +
218
219/*chain.h*/     0                                         +
220
221/*clock.h*/     0                                         +
222
223/*config.h*/    (sizeof _Configuration_Table)             +
224                (sizeof _Configuration_MP_table)          +
225
226/*context.h*/   (sizeof _Context_Switch_necessary)        +
227
228/*copyrt.h*/    0                                         +
229
230/*debug.h*/     (sizeof _Debug_Level)                     +
231
232/*dpmem.h*/     (sizeof _Dual_ported_memory_Information)  +
233
234/*event.h*/     (sizeof _Event_Sync_state)                +
235
236#if defined(RTEMS_MULTIPROCESSING)
237/*eventmp.h*/   0                                         +
238#endif
239
240/*eventset.h*/  0                                         +
241
242/*extension.h*/ (sizeof _Extension_Information)           +
243
244/*fatal.h*/     0                                         +
245
246/*heap.h*/      0                                         +
247
248/*init.h*/      0                                         +
249
250/*interr.h*/    (sizeof Internal_errors_What_happened)    +
251
252/*intr.h*/      0                                         +
253
254/*io.h*/        (sizeof _IO_Number_of_drivers)            +
255                (sizeof _IO_Driver_address_table)         +
256                (sizeof _IO_Number_of_devices)            +
257                (sizeof _IO_Driver_name_table)            +
258
259/*isr.h*/       (sizeof _ISR_Nest_level)                  +
260                (sizeof _ISR_Vector_table)                +
261                (sizeof _ISR_Signals_to_thread_executing) +
262
263/*message.h*/   (sizeof _Message_queue_Information)       +
264
265/*modes.h*/     0                                         +
266
267#if defined(RTEMS_MULTIPROCESSING)
268/*mp.h*/        0                                         +
269#endif
270
271#if defined(RTEMS_MULTIPROCESSING)
272/*mpci.h*/      (sizeof _MPCI_Remote_blocked_threads)     +
273                (sizeof _MPCI_Semaphore)                  +
274                (sizeof _MPCI_table)                      +
275                (sizeof _MPCI_Receive_server_tcb)         +
276                (sizeof _MPCI_Packet_processors)          +
277#endif
278
279#if defined(RTEMS_MULTIPROCESSING)
280/*mppkt.h*/     0                                         +
281#endif
282
283#if defined(RTEMS_MULTIPROCESSING)
284/*mptables.h*/  0                                         +
285#endif
286
287#if defined(RTEMS_MULTIPROCESSING)
288/*msgmp.h*/     0                                         +
289#endif
290
291/*object.h*/    (sizeof _Objects_Local_node)              +
292                (sizeof _Objects_Maximum_nodes)           +
293                (sizeof _Objects_Information_table)       +
294
295#if defined(RTEMS_MULTIPROCESSING)
296/*objectmp.h*/  (sizeof _Objects_MP_Maximum_global_objects) +
297                (sizeof _Objects_MP_Inactive_global_objects) +
298#endif
299
300/*options.h*/   0                                         +
301
302/*part.h*/      (sizeof _Partition_Information)           +
303
304#if defined(RTEMS_MULTIPROCESSING)
305/*partmp.h*/    0                                         +
306#endif
307
308/*priority.h*/  (sizeof _Priority_Major_bit_map)          +
309                (sizeof _Priority_Bit_map)                +
310
311/*ratemon.h*/   (sizeof _Rate_monotonic_Information)      +
312
313/*region.h*/    (sizeof _Region_Information)              +
314
315#if defined(RTEMS_MULTIPROCESSING)
316/*regionmp.h*/  0                                         +
317#endif
318
319/*rtems.h*/     /* Not applicable */
320
321/*sem.h*/       (sizeof _Semaphore_Information)           +
322
323#if defined(RTEMS_MULTIPROCESSING)
324/*semmp.h*/     0                                         +
325#endif
326
327/*signal.h*/    0                                         +
328
329/*signalmp.h*/  0                                         +
330
331/*stack.h*/     0                                         +
332
333/*states.h*/    0                                         +
334
335/*status.h*/    0                                         +
336
337/*sysstate.h*/  (sizeof _System_state_Is_multiprocessing) +
338                (sizeof _System_state_Current)            +
339
340/*system.h*/    (sizeof _CPU_Table)                       +
341
342#if defined(RTEMS_MULTIPROCESSING)
343/*taskmp.h*/    0                                         +
344#endif
345
346/*tasks.h*/     (sizeof _RTEMS_tasks_Information)         +
347                (sizeof _RTEMS_tasks_User_initialization_tasks) +
348                (sizeof _RTEMS_tasks_Number_of_initialization_tasks) +
349
350/*thread.h*/    (sizeof _Thread_BSP_context)              +
351                (sizeof _Thread_Dispatch_disable_level)   +
352                (sizeof _Thread_Do_post_task_switch_extension) +
353                (sizeof _Thread_Maximum_extensions)       +
354                (sizeof _Thread_Ticks_per_timeslice)      +
355                (sizeof _Thread_Ready_chain)              +
356                (sizeof _Thread_Executing)                +
357                (sizeof _Thread_Heir)                     +
358#if (CPU_HARDWARE_FP == 1) || (CPU_SOFTWARE_FP == 1)
359                (sizeof _Thread_Allocated_fp)             +
360#endif
361                (sizeof _Thread_Internal_information)     +
362                (sizeof _Thread_Idle)                     +
363
364#if defined(RTEMS_MULTIPROCESSING)
365/*threadmp.h*/  (sizeof _Thread_MP_Receive)               +
366                (sizeof _Thread_MP_Active_proxies)        +
367                (sizeof _Thread_MP_Inactive_proxies)      +
368#endif
369
370/*threadq.h*/
371
372/*timer.h*/     (sizeof _Timer_Information)               +
373
374/*tod.h*/       (sizeof _TOD_Current)                     +
375                (sizeof _TOD_Seconds_since_epoch)         +
376                (sizeof _TOD_Microseconds_per_tick)       +
377                (sizeof _TOD_Ticks_per_second)            +
378                (sizeof _TOD_Seconds_watchdog)            +
379
380/*tqdata.h*/    0                                         +
381
382/*types.h*/     0                                         +
383
384/*userext.h*/   (sizeof _User_extensions_List)            +
385
386/*watchdog.h*/  (sizeof _Watchdog_Sync_level)             +
387                (sizeof _Watchdog_Sync_count)             +
388                (sizeof _Watchdog_Ticks_since_boot)       +
389                (sizeof _Watchdog_Ticks_chain)            +
390                (sizeof _Watchdog_Seconds_chain)          +
391
392/*wkspace.h*/   (sizeof _Workspace_Area);
393
394uninitialized = 0;
395
396#ifndef unix  /* make sure this is not a native compile */
397
398#ifdef __i386__
399
400/* cpu.h */
401uninitialized += (sizeof _CPU_Null_fp_context) +
402                 (sizeof _CPU_Interrupt_stack_low) +
403                 (sizeof _CPU_Interrupt_stack_high);
404
405#endif
406
407#ifdef __i960__
408
409/* cpu.h */
410uninitialized += (sizeof _CPU_Interrupt_stack_low) +
411                 (sizeof _CPU_Interrupt_stack_high);
412
413#endif
414
415#ifdef __hppa__
416
417/* cpu.h */
418uninitialized += (sizeof _CPU_Null_fp_context) +
419#if !defined(RTEMS_UNIX)
420                 (sizeof _CPU_Default_gr27) +
421#endif
422                 (sizeof _CPU_Interrupt_stack_low) +
423                 (sizeof _CPU_Interrupt_stack_high);
424#endif
425
426#ifdef __mc68000__
427
428/* cpu.h */
429uninitialized += (sizeof _CPU_Interrupt_stack_low) +
430                 (sizeof _CPU_Interrupt_stack_high);
431
432#endif
433
434#ifdef __sparc__
435 
436/* cpu.h */
437uninitialized += (sizeof _CPU_Interrupt_stack_low) +
438                 (sizeof _CPU_Interrupt_stack_high) +
439                 (sizeof _CPU_Null_fp_context);
440
441#endif
442
443
444#ifdef no_cpu
445
446/* cpu.h */
447uninitialized += (sizeof _CPU_Null_fp_context) +
448                 (sizeof _CPU_Interrupt_stack_low) +
449                 (sizeof _CPU_Interrupt_stack_high) +
450                 (sizeof _CPU_Thread_dispatch_pointer);
451
452#endif
453
454#ifdef __PPC__
455
456/* cpu.h */
457uninitialized += (sizeof _CPU_Interrupt_stack_low) +
458                 (sizeof _CPU_Interrupt_stack_high) +
459                 (sizeof _CPU_IRQ_info);
460
461#endif
462#endif /* !unix */
463
464initialized +=
465/*copyrt.h*/    (strlen(_Copyright_Notice)+1)             +
466
467/*sptables.h*/  (sizeof _Initialization_Default_multiprocessing_table)  +
468                (strlen(_RTEMS_version)+1)      +
469
470
471/*tod.h*/       (sizeof _TOD_Days_per_month)    +
472                (sizeof _TOD_Days_to_date)      +
473                (sizeof _TOD_Days_since_last_leap_year);
474
475#ifndef unix /* make sure this is not native */
476#ifdef __sparc__
477
478initialized +=  (sizeof _CPU_Trap_slot_template);
479
480#endif
481#endif /* !unix */
482
483puts( "" );
484
485  if ( mode == 0 ) help_size();
486  else             print_formula();
487
488printf( "\n" );
489printf( "RTEMS uninitialized data consumes %d bytes\n", uninitialized );
490printf( "RTEMS intialized data consumes %d bytes\n", initialized );
491
492}
493
494void help_size()
495{
496int c = '\0';
497int break_loop;
498int total_size;
499int task_stacks;
500int interrupt_stack;
501int maximum_tasks, size_tasks;
502int maximum_sems, size_sems;
503int maximum_timers, size_timers;
504int maximum_msgqs, size_msgqs;
505int maximum_msgs, size_msgs_overhead;
506int maximum_regns, size_regns;
507int maximum_parts, size_parts;
508int maximum_ports, size_ports;
509int maximum_periods, size_periods;
510int maximum_extensions, size_extensions;
511int maximum_drvs, size_drvs;
512int maximum_fps, size_fps;
513int maximum_nodes, size_nodes;
514int maximum_gobjs, size_gobjs;
515int maximum_proxies, size_proxies;
516
517total_size = sys_req;    /* Fixed Overhead */
518printf( "What is maximum_tasks? " );
519maximum_tasks = getint();
520size_tasks = PER_TASK * maximum_tasks;
521total_size += size_tasks;
522
523printf( "What is maximum_semaphores? " );
524maximum_sems = getint();
525size_sems = PER_SEMAPHORE * maximum_sems;
526total_size += size_sems;
527
528printf( "What is maximum_timers? " );
529maximum_timers = getint();
530size_timers = PER_TIMER * maximum_timers;
531total_size += size_timers;
532
533printf( "What is maximum_message_queues? " );
534maximum_msgqs = getint();
535size_msgqs = PER_MSGQ * maximum_msgqs;
536total_size += size_msgqs;
537
538printf( "What is maximum_messages?  XXXX " );
539maximum_msgs = getint();
540size_msgs_overhead = 0;
541total_size += size_msgs_overhead;
542
543printf( "What is maximum_regions? " );
544maximum_regns = getint();
545size_regns = PER_REGN * maximum_regns;
546total_size += size_regns;
547
548printf( "What is maximum_partitions? " );
549maximum_parts = getint();
550size_parts = PER_PART * maximum_parts;
551total_size += size_parts;
552
553printf( "What is maximum_ports? " );
554maximum_ports = getint();
555size_ports = PER_PORT * maximum_ports;
556total_size += size_ports;
557
558printf( "What is maximum_periods? " );
559maximum_periods = getint();
560size_periods = PER_PORT * maximum_periods;
561total_size += size_periods;
562
563printf( "What is maximum_extensions? " );
564maximum_extensions = getint();
565size_extensions = PER_EXTENSION * maximum_extensions;
566total_size += size_extensions;
567
568printf( "What is number_of_device_drivers? " );
569maximum_drvs = getint();
570size_drvs = PER_DRV  * maximum_drvs;
571total_size += size_drvs;
572
573printf( "What will be total stack requirement for all tasks? " );
574task_stacks = getint();
575total_size += task_stacks;
576
577printf( "What is the size of the interrupt stack? " );
578interrupt_stack = getint();
579total_size += interrupt_stack;
580
581printf( "How many tasks will be created with the FP flag? " );
582maximum_fps = getint();
583size_fps = PER_FPTASK  * maximum_fps;
584total_size += size_fps;
585
586printf( "Is this a single processor system? " );
587for ( break_loop=0 ; !break_loop; c = getchar() ) {
588  switch ( c ) {
589    case 'Y':  case 'y':
590    case 'N':  case 'n':
591      break_loop = 1;
592      break;
593  }
594}
595printf( "%c\n", c );
596if ( c == 'n' || c == 'N' ) {
597  printf( "What is maximum_nodes? " );
598  maximum_nodes = getint();
599  size_nodes = PER_NODE * maximum_nodes;
600  total_size += size_nodes;
601  printf( "What is maximum_global_objects? " );
602  maximum_gobjs = getint();
603  size_gobjs = PER_GOBJECT * maximum_gobjs;
604  total_size += size_gobjs;
605  printf( "What is maximum_proxies? " );
606  maximum_proxies = getint();
607  size_proxies = PER_PROXY * maximum_proxies;
608  total_size += size_proxies;
609} else {
610  maximum_nodes = 0;
611  size_nodes = PER_NODE * 0;
612  maximum_gobjs = 0;
613  size_gobjs = PER_GOBJECT * 0;
614  maximum_proxies = 0;
615  size_proxies = PER_PROXY * 0;
616}
617
618printf( "\n\n" );
619printf( " ************** EXECUTIVE WORK SPACE REQUIRED **************\n" );
620printf( " Tasks                - %03d * %03ld            =  %ld\n",
621          maximum_tasks, PER_TASK, (long) size_tasks );
622printf( " Semaphores           - %03d * %03ld            =  %ld\n",
623          maximum_sems, PER_SEMAPHORE, (long) size_sems );
624printf( " Timers               - %03d * %03ld            =  %ld\n",
625          maximum_timers, PER_TIMER, (long) size_timers );
626printf( " Msg Queues           - %03d * %03ld            =  %ld\n",
627          maximum_msgqs, PER_MSGQ, (long) size_msgqs );
628printf( " Messages Overhead    - %03d * %03d            =  %ld\n",
629          maximum_msgs, 0 /* PER_MSG_OVERHEAD */, (long) size_msgs_overhead );
630printf( " Regions              - %03d * %03ld            =  %ld\n",
631          maximum_regns, PER_REGN, (long) size_regns);
632printf( " Partitions           - %03d * %03ld            =  %ld\n",
633          maximum_parts, PER_PART, (long) size_parts );
634printf( " Periods              - %03d * %03ld            =  %ld\n",
635          maximum_periods, PER_PERIOD, (long) size_periods );
636printf( " Extensions           - %03d * %03ld            =  %ld\n",
637          maximum_extensions, PER_EXTENSION, (long) size_extensions );
638printf( " Device Drivers       - %03d * %03ld            =  %ld\n",
639          maximum_drvs, PER_DRV, (long) size_drvs );
640
641printf( " System Requirements  - %04d                 =  %d\n",
642          sys_req, sys_req );
643
644printf( " Floating Point Tasks - %03d * %03ld            =  %ld\n",
645          maximum_fps, PER_FPTASK, (long) size_fps );
646printf( " Application Task Stacks -                     =  %d\n",
647          task_stacks );
648printf( " Interrupt Stacks -                            =  %d\n",
649          task_stacks );
650printf( " \n" );
651printf( " Global object tables - %03d * %03ld            =  %ld\n",
652          maximum_nodes, PER_NODE, (long) size_nodes );
653printf( " Global objects       - %03d * %03ld            =  %ld\n",
654          maximum_gobjs, PER_GOBJECT, (long) size_gobjs );
655printf( " Proxies              - %03d * %03ld            =  %ld\n",
656          maximum_proxies, PER_PROXY, (long) size_proxies );
657printf( "\n\n" );
658printf( " TOTAL                                       = %d bytes\n",
659      total_size );
660}
661
662void print_formula()
663{
664printf( " ************** EXECUTIVE WORK SPACE FORMULA **************\n" );
665printf( " Tasks                - maximum_tasks * %ld\n",      PER_TASK );
666printf( " Timers               - maximum_timers * %ld\n",     PER_TIMER );
667printf( " Semaphores           - maximum_semaphores * %ld\n", PER_SEMAPHORE);
668printf( " Message Queues       - maximum_message_queues * %ld\n", PER_MSGQ );
669printf( " Messages             -\n");
670printf( " Regions              - maximum_regions * %ld\n",    PER_REGN );
671printf( " Partitions           - maximum_partitions * %ld\n", PER_PART );
672printf( " Ports                - maximum_ports * %ld\n",      PER_PORT );
673printf( " Periods              - maximum_periods * %ld\n",    PER_PORT );
674printf( " Extensions           - maximum_extensions * %ld\n", PER_EXTENSION );
675printf( " Device Drivers       - number_of_device_drivers * %ld\n", PER_DRV);
676printf( " System Requirements  - %d\n",                       sys_req );
677printf( " Floating Point Tasks - FPMASK Tasks * %ld\n",       PER_FPTASK );
678printf( " User's Tasks' Stacks -\n" );
679printf( " Interrupt Stack      -\n" );
680printf( " \n" );
681printf( " Global object tables - maximum_nodes * %ld\n",          PER_NODE );
682printf( " Global objects       - maximum_global_objects * %ld\n", PER_GOBJECT );
683printf( " Proxies              - maximum_proxies * %ld\n",        PER_PROXY );
684}
Note: See TracBrowser for help on using the repository browser.