Changeset f8700f77 in rtems for testsuites/sptests/spsize


Ignore:
Timestamp:
Apr 7, 1997, 9:33:28 PM (23 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, master
Children:
bed475e
Parents:
de4f281
Message:

corrected printf specifications and added casts as necessary to eliminate
warnings.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • testsuites/sptests/spsize/size.c

    rde4f281 rf8700f77  
    6060
    6161#define PER_TASK      \
    62      (sizeof (Thread_Control) + \
     62     (long) (sizeof (Thread_Control) + \
    6363      NAME_PTR_SIZE + HEAP_OVHD + sizeof( RTEMS_API_Control ))
    6464#define PER_SEMAPHORE \
    65      (sizeof (Semaphore_Control) + NAME_PTR_SIZE)
     65     (long) (sizeof (Semaphore_Control) + NAME_PTR_SIZE)
    6666#define PER_TIMER     \
    67      (sizeof (Timer_Control) + NAME_PTR_SIZE)
     67     (long) (sizeof (Timer_Control) + NAME_PTR_SIZE)
    6868#define PER_MSGQ      \
    69      (sizeof (Message_queue_Control) + NAME_PTR_SIZE)
     69     (long) (sizeof (Message_queue_Control) + NAME_PTR_SIZE)
    7070#define PER_REGN      \
    71      (sizeof (Region_Control) + NAME_PTR_SIZE)
     71     (long) (sizeof (Region_Control) + NAME_PTR_SIZE)
    7272#define PER_PART      \
    73      (sizeof (Partition_Control) + NAME_PTR_SIZE)
     73     (long) (sizeof (Partition_Control) + NAME_PTR_SIZE)
    7474#define PER_PERIOD      \
    75      (sizeof (Rate_monotonic_Control) + NAME_PTR_SIZE)
     75     (long) (sizeof (Rate_monotonic_Control) + NAME_PTR_SIZE)
    7676#define PER_PORT      \
    77      (sizeof (Dual_ported_memory_Control) + NAME_PTR_SIZE)
     77     (long) (sizeof (Dual_ported_memory_Control) + NAME_PTR_SIZE)
    7878#define PER_EXTENSION     \
    79      (sizeof (Extension_Control) + NAME_PTR_SIZE)
    80 
    81 #define PER_DRV       (0)
    82 #define PER_FPTASK    (CONTEXT_FP_SIZE)
    83 #define PER_GOBTBL    (sizeof (Chain_Control)*4)
    84 #define PER_NODE      PER_GOBTBL
    85 #define PER_GOBJECT   (sizeof (Objects_MP_Control))
    86 #define PER_PROXY     (sizeof (Thread_Proxy_control))
     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#define PER_GOBJECT   (long) (sizeof (Objects_MP_Control))
     86#define PER_PROXY     (long) (sizeof (Thread_Proxy_control))
    8787
    8888#if (CPU_ALL_TASKS_ARE_FP == TRUE)
    89 #define MPCI_RECEIVE_SERVER_FP (sizeof( Context_Control_fp ))
     89#define MPCI_RECEIVE_SERVER_FP (long) (sizeof( Context_Control_fp ))
    9090#else
    91 #define MPCI_RECEIVE_SERVER_FP 0
     91#define MPCI_RECEIVE_SERVER_FP (long) 0
    9292#endif
    9393
    9494#if (CPU_IDLE_TASK_IS_FP == TRUE)
    95 #define SYSTEM_IDLE_FP (sizeof( Context_Control_fp ))
     95#define SYSTEM_IDLE_FP (long) (sizeof( Context_Control_fp ))
    9696#else
    97 #define SYSTEM_IDLE_FP 0
     97#define SYSTEM_IDLE_FP (long) 0
    9898#endif
    9999
     
    585585printf( "\n\n" );
    586586printf( " ************** EXECUTIVE WORK SPACE REQUIRED **************\n" );
    587 printf( " Tasks                - %03d * %03d            =  %d\n",
    588           maximum_tasks, PER_TASK, size_tasks );
    589 printf( " Semaphores           - %03d * %03d            =  %d\n",
    590           maximum_sems, PER_SEMAPHORE, size_sems );
    591 printf( " Timers               - %03d * %03d            =  %d\n",
    592           maximum_timers, PER_TIMER, size_timers );
    593 printf( " Msg Queues           - %03d * %03d            =  %d\n",
    594           maximum_msgqs, PER_MSGQ, size_msgqs );
    595 printf( " Messages Overhead    - %03d * %03d            =  %d\n",
    596           maximum_msgs, 0 /* PER_MSG_OVERHEAD */, size_msgs_overhead );
    597 printf( " Regions              - %03d * %03d            =  %d\n",
    598           maximum_regns, PER_REGN, size_regns);
    599 printf( " Partitions           - %03d * %03d            =  %d\n",
    600           maximum_parts, PER_PART, size_parts );
    601 printf( " Periods              - %03d * %03d            =  %d\n",
    602           maximum_periods, PER_PERIOD, size_periods );
    603 printf( " Extensions           - %03d * %03d            =  %d\n",
    604           maximum_extensions, PER_EXTENSION, size_extensions );
    605 printf( " Device Drivers       - %03d * %03d            =  %d\n",
    606           maximum_drvs, PER_DRV, size_drvs );
     587printf( " Tasks                - %03d * %03ld            =  %ld\n",
     588          maximum_tasks, PER_TASK, (long) size_tasks );
     589printf( " Semaphores           - %03d * %03ld            =  %ld\n",
     590          maximum_sems, PER_SEMAPHORE, (long) size_sems );
     591printf( " Timers               - %03d * %03ld            =  %ld\n",
     592          maximum_timers, PER_TIMER, (long) size_timers );
     593printf( " Msg Queues           - %03d * %03ld            =  %ld\n",
     594          maximum_msgqs, PER_MSGQ, (long) size_msgqs );
     595printf( " Messages Overhead    - %03d * %03d            =  %ld\n",
     596          maximum_msgs, 0 /* PER_MSG_OVERHEAD */, (long) size_msgs_overhead );
     597printf( " Regions              - %03d * %03ld            =  %ld\n",
     598          maximum_regns, PER_REGN, (long) size_regns);
     599printf( " Partitions           - %03d * %03ld            =  %ld\n",
     600          maximum_parts, PER_PART, (long) size_parts );
     601printf( " Periods              - %03d * %03ld            =  %ld\n",
     602          maximum_periods, PER_PERIOD, (long) size_periods );
     603printf( " Extensions           - %03d * %03ld            =  %ld\n",
     604          maximum_extensions, PER_EXTENSION, (long) size_extensions );
     605printf( " Device Drivers       - %03d * %03ld            =  %ld\n",
     606          maximum_drvs, PER_DRV, (long) size_drvs );
    607607
    608608printf( " System Requirements  - %04d                 =  %d\n",
    609609          sys_req, sys_req );
    610610
    611 printf( " Floating Point Tasks - %03d * %03d            =  %d\n",
    612           maximum_fps, PER_FPTASK, size_fps );
     611printf( " Floating Point Tasks - %03d * %03ld            =  %ld\n",
     612          maximum_fps, PER_FPTASK, (long) size_fps );
    613613printf( " Application Task Stacks -                     =  %d\n",
    614614          task_stacks );
     
    616616          task_stacks );
    617617printf( " \n" );
    618 printf( " Global object tables - %03d * %03d            =  %d\n",
    619           maximum_nodes, PER_NODE, size_nodes );
    620 printf( " Global objects       - %03d * %03d            =  %d\n",
    621           maximum_gobjs, PER_GOBJECT, size_gobjs );
    622 printf( " Proxies              - %03d * %03d            =  %d\n",
    623           maximum_proxies, PER_PROXY, size_proxies );
     618printf( " Global object tables - %03d * %03ld            =  %ld\n",
     619          maximum_nodes, PER_NODE, (long) size_nodes );
     620printf( " Global objects       - %03d * %03ld            =  %ld\n",
     621          maximum_gobjs, PER_GOBJECT, (long) size_gobjs );
     622printf( " Proxies              - %03d * %03ld            =  %ld\n",
     623          maximum_proxies, PER_PROXY, (long) size_proxies );
    624624printf( "\n\n" );
    625625printf( " TOTAL                                       = %d bytes\n",
     
    630630{
    631631printf( " ************** EXECUTIVE WORK SPACE FORMULA **************\n" );
    632 printf( " Tasks                - maximum_tasks * %d\n",      PER_TASK );
    633 printf( " Timers               - maximum_timers * %d\n",     PER_TIMER );
    634 printf( " Semaphores           - maximum_semaphores * %d\n", PER_SEMAPHORE);
    635 printf( " Message Queues       - maximum_message_queues * %d\n", PER_MSGQ );
     632printf( " Tasks                - maximum_tasks * %ld\n",      PER_TASK );
     633printf( " Timers               - maximum_timers * %ld\n",     PER_TIMER );
     634printf( " Semaphores           - maximum_semaphores * %ld\n", PER_SEMAPHORE);
     635printf( " Message Queues       - maximum_message_queues * %ld\n", PER_MSGQ );
    636636printf( " Messages             -\n");
    637 printf( " Regions              - maximum_regions * %d\n",    PER_REGN );
    638 printf( " Partitions           - maximum_partitions * %d\n", PER_PART );
    639 printf( " Ports                - maximum_ports * %d\n",      PER_PORT );
    640 printf( " Periods              - maximum_periods * %d\n",    PER_PORT );
    641 printf( " Extensions           - maximum_extensions * %d\n", PER_EXTENSION );
    642 printf( " Device Drivers       - number_of_device_drivers * %d\n", PER_DRV);
    643 printf( " System Requirements  - %d\n",                      sys_req );
    644 printf( " Floating Point Tasks - FPMASK Tasks * %d\n",       CONTEXT_FP_SIZE );
     637printf( " Regions              - maximum_regions * %ld\n",    PER_REGN );
     638printf( " Partitions           - maximum_partitions * %ld\n", PER_PART );
     639printf( " Ports                - maximum_ports * %ld\n",      PER_PORT );
     640printf( " Periods              - maximum_periods * %ld\n",    PER_PORT );
     641printf( " Extensions           - maximum_extensions * %ld\n", PER_EXTENSION );
     642printf( " Device Drivers       - number_of_device_drivers * %ld\n", PER_DRV);
     643printf( " System Requirements  - %d\n",                       sys_req );
     644printf( " Floating Point Tasks - FPMASK Tasks * %ld\n",       PER_FPTASK );
    645645printf( " User's Tasks' Stacks -\n" );
    646646printf( " Interrupt Stack      -\n" );
    647647printf( " \n" );
    648 printf( " Global object tables - maximum_nodes * %d\n",          PER_NODE );
    649 printf( " Global objects       - maximum_global_objects * %d\n", PER_GOBJECT );
    650 printf( " Proxies              - maximum_proxies * %d\n",        PER_PROXY );
     648printf( " Global object tables - maximum_nodes * %ld\n",          PER_NODE );
     649printf( " Global objects       - maximum_global_objects * %ld\n", PER_GOBJECT );
     650printf( " Proxies              - maximum_proxies * %ld\n",        PER_PROXY );
    651651}
Note: See TracChangeset for help on using the changeset viewer.