source: rtems/testsuites/sptests/spsize/size.c @ e1598a6

4.115
Last change on this file since e1598a6 was e1598a6, checked in by Sebastian Huber <sebastian.huber@…>, on 04/04/14 at 08:56:36

score: Static scheduler configuration

Do not allocate the scheduler control structures from the workspace.
This is a preparation step for configuration of clustered/partitioned
schedulers on SMP.

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