diff options
author | Joel Sherrill <joel.sherrill@oarcorp.com> | 2015-03-14 10:52:24 -0500 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@oarcorp.com> | 2015-03-17 10:05:07 -0500 |
commit | e334edd1715abe7a82fea118ef1efc57806e1fe9 (patch) | |
tree | c2eb3ccd14d8dd88d16576ab46a57c7b38d45feb /testsuites/tmtests | |
parent | Disable deprecated warning on implementation of deprecated methods (diff) | |
download | rtems-e334edd1715abe7a82fea118ef1efc57806e1fe9.tar.bz2 |
tests misc: Disable deprecated method usage warning when intentional
These tests intentionally use the deprecated method. Eventually
this code in the sections can be deleted.
Diffstat (limited to 'testsuites/tmtests')
-rw-r--r-- | testsuites/tmtests/tm08/task1.c | 62 |
1 files changed, 37 insertions, 25 deletions
diff --git a/testsuites/tmtests/tm08/task1.c b/testsuites/tmtests/tm08/task1.c index f26931f627..6d42de9900 100644 --- a/testsuites/tmtests/tm08/task1.c +++ b/testsuites/tmtests/tm08/task1.c @@ -186,31 +186,43 @@ rtems_task test_task( benchmark_timer_initialize(); (void) rtems_task_mode( RTEMS_PREEMPT, RTEMS_PREEMPT_MASK, &old_mode ); - benchmark_timer_initialize(); - for ( index=1 ; index <= OPERATION_COUNT ; index++ ) - (void) rtems_task_set_note( Test_task_id, 8, 10 ); - end_time = benchmark_timer_read(); - - put_time( - "rtems_task_set_note: only case", - end_time, - OPERATION_COUNT, - overhead, - CALLING_OVERHEAD_TASK_SET_NOTE - ); - - benchmark_timer_initialize(); - for ( index=1 ; index <= OPERATION_COUNT ; index++ ) - (void) rtems_task_get_note( Test_task_id, 8, &old_note ); - end_time = benchmark_timer_read(); - - put_time( - "rtems_task_get_note: only case", - end_time, - OPERATION_COUNT, - overhead, - CALLING_OVERHEAD_TASK_GET_NOTE - ); + /** START OF NOTEPAD TESTS **/ + + /* + * We know this is deprecated and don't want a warning on every BSP built. + */ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + + benchmark_timer_initialize(); + for ( index=1 ; index <= OPERATION_COUNT ; index++ ) + (void) rtems_task_set_note( Test_task_id, 8, 10 ); + end_time = benchmark_timer_read(); + + put_time( + "rtems_task_set_note: only case", + end_time, + OPERATION_COUNT, + overhead, + CALLING_OVERHEAD_TASK_SET_NOTE + ); + + benchmark_timer_initialize(); + for ( index=1 ; index <= OPERATION_COUNT ; index++ ) + (void) rtems_task_get_note( Test_task_id, 8, &old_note ); + end_time = benchmark_timer_read(); + + put_time( + "rtems_task_get_note: only case", + end_time, + OPERATION_COUNT, + overhead, + CALLING_OVERHEAD_TASK_GET_NOTE + ); + + #pragma GCC diagnostic pop + + /** END OF NOTEPAD TESTS **/ build_time( &time, 1, 1, 1988, 0, 0, 0, 0 ); |