mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-10-26 23:36:32 -04:00
Update VeriFast proofs (#836)
* Undo syntax changes preventing VeriFast parsing * Update proofs inline with source changes Outstanding: - xQueueGenericReset return code - Not using prvIncrementQueueTxLock or prvIncrementQueueRxLock macros * Remove git hash check * Document new changes between proven code and implementation * Update copyright header * VeriFast proofs: turn off uncrustify checks Uncrustify requires formatting of comments that is at odds with VeriFast's proof annotations, which are contained within comments. * Update ci.yml Co-authored-by: Joseph Julicher <jjulicher@mac.com> Co-authored-by: Aniruddha Kanhere <60444055+AniruddhaKanhere@users.noreply.github.com>
This commit is contained in:
parent
4e0fecaadd
commit
4f87f485d5
32 changed files with 1877 additions and 1864 deletions
|
|
@ -24,24 +24,25 @@
|
|||
*
|
||||
*/
|
||||
|
||||
/* *INDENT-OFF* */
|
||||
|
||||
#include "proof/queue.h"
|
||||
#define configSUPPORT_DYNAMIC_ALLOCATION 1
|
||||
#define configSUPPORT_STATIC_ALLOCATION 0
|
||||
|
||||
void vQueueDelete( QueueHandle_t xQueue )
|
||||
|
||||
/*@requires queue(xQueue, ?Storage, ?N, ?M, ?W, ?R, ?K, ?is_locked, ?abs) &*&
|
||||
* queuelists(xQueue) &*&
|
||||
* xQueue->irqMask |-> _ &*&
|
||||
* xQueue->schedulerSuspend |-> _ &*&
|
||||
* xQueue->locked |-> _;@*/
|
||||
queuelists(xQueue) &*&
|
||||
xQueue->irqMask |-> _ &*&
|
||||
xQueue->schedulerSuspend |-> _ &*&
|
||||
xQueue->locked |-> _;@*/
|
||||
/*@ensures true;@*/
|
||||
{
|
||||
#ifdef VERIFAST /*< const pointer declaration */
|
||||
Queue_t * pxQueue = xQueue;
|
||||
#else
|
||||
Queue_t * const pxQueue = xQueue;
|
||||
#endif
|
||||
#ifdef VERIFAST /*< const pointer declaration */
|
||||
Queue_t * pxQueue = xQueue;
|
||||
#else
|
||||
Queue_t * const pxQueue = xQueue;
|
||||
#endif
|
||||
|
||||
configASSERT( pxQueue );
|
||||
traceQUEUE_DELETE( pxQueue );
|
||||
|
|
@ -57,10 +58,10 @@ void vQueueDelete( QueueHandle_t xQueue )
|
|||
/* The queue can only have been allocated dynamically - free it
|
||||
* again. */
|
||||
vPortFree( pxQueue );
|
||||
#ifdef VERIFAST /*< leak ghost state on deletion */
|
||||
/*@leak buffer(_, _, _, _);@*/
|
||||
/*@leak malloc_block(_, _);@*/
|
||||
#endif
|
||||
#ifdef VERIFAST /*< leak ghost state on deletion */
|
||||
/*@leak buffer(_, _, _, _);@*/
|
||||
/*@leak malloc_block(_, _);@*/
|
||||
#endif
|
||||
}
|
||||
#elif ( ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) && ( configSUPPORT_STATIC_ALLOCATION == 1 ) )
|
||||
{
|
||||
|
|
@ -83,3 +84,5 @@ void vQueueDelete( QueueHandle_t xQueue )
|
|||
}
|
||||
#endif /* configSUPPORT_DYNAMIC_ALLOCATION */
|
||||
}
|
||||
|
||||
/* *INDENT-ON* */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue