Check-in [1e3df2a217]
Not logged in

Overview
Comment: Corrected a problem in removing items from the delayed event queue where expired events were not taken into account. family | ancestors | trunk files | file ages | folders 1e3df2a2175bd64870b5520fe07f1543f4652c37 andrewm 2017-05-09 23:30:14
Context
 2017-05-09 23:30 Corrected a problem in removing items from the delayed event queue where expired events were not taken into account. Leaf check-in: 1e3df2a217 user: andrewm tags: trunk 2016-11-06 20:09 Build of pycca and tack for macosx. check-in: 15694b418d user: andrewm tags: trunk
Changes

Changes to mechs/code/cortex-m3/mechs.c.

 1 2 3 4 5 6 7 8 9 10 ... 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.7 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files. ................................................................................ eventQueueInsert(ecb, iter) ; /* * Since we have stored a reference to the ECB we do * the bookkeeping. */ mechEventIncrRef(ecb) ; } static void removeFromDelayedQueue( MechEcb ecb) { /* * If we are not at the end of the queue, all the delay * from the removed entry is accumulated on the next * entry in the queue. */ if (ecb->next != eventQueueEnd(&delayedEventQueue)) { ecb->next->delay += ecb->delay ; } /* * Remove the ECB from the delayed queue. */ eventQueueRemove(ecb) ; /* * Return the ECB back to the pool. */ mechEventDelete(ecb) ; } #define MECH_DELAY_EXPIRED UINT32_MAX static MechEcb expireDelayedEvents(void) { /* * Iterate along the delayed event queue. */ for (MechEcb iter = eventQueueBegin(&delayedEventQueue) ; | > > | < 1 2 3 4 5 6 7 8 9 10 ... 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.8 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files. ................................................................................ eventQueueInsert(ecb, iter) ; /* * Since we have stored a reference to the ECB we do * the bookkeeping. */ mechEventIncrRef(ecb) ; } #define MECH_DELAY_EXPIRED UINT32_MAX static void removeFromDelayedQueue( MechEcb ecb) { /* * If we are not at the end of the queue, all the delay * from the removed entry is accumulated on the next * entry in the queue. */ if (!(ecb->delay == MECH_DELAY_EXPIRED || ecb->next == eventQueueEnd(&delayedEventQueue))) { ecb->next->delay += ecb->delay ; } /* * Remove the ECB from the delayed queue. */ eventQueueRemove(ecb) ; /* * Return the ECB back to the pool. */ mechEventDelete(ecb) ; } static MechEcb expireDelayedEvents(void) { /* * Iterate along the delayed event queue. */ for (MechEcb iter = eventQueueBegin(&delayedEventQueue) ;

Changes to mechs/code/cortex-m3/mechs.h.

 1 2 3 4 5 6 7 8 9 10 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.7 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files. | 1 2 3 4 5 6 7 8 9 10 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.8 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files.

Changes to mechs/code/msp430/mechs.c.

 1 2 3 4 5 6 7 8 9 10 ... 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.7 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files. ................................................................................ eventQueueInsert(ecb, iter) ; /* * Since we have stored a reference to the ECB we do * the bookkeeping. */ mechEventIncrRef(ecb) ; } static void removeFromDelayedQueue( MechEcb ecb) { /* * If we are not at the end of the queue, all the delay * from the removed entry is accumulated on the next * entry in the queue. */ if (ecb->next != eventQueueEnd(&delayedEventQueue)) { ecb->next->delay += ecb->delay ; } /* * Remove the ECB from the delayed queue. */ eventQueueRemove(ecb) ; /* * Return the ECB back to the pool. */ mechEventDelete(ecb) ; } #define MECH_DELAY_EXPIRED UINT32_MAX static MechEcb expireDelayedEvents(void) { /* * Iterate along the delayed event queue. */ for (MechEcb iter = eventQueueBegin(&delayedEventQueue) ; | > > | < 1 2 3 4 5 6 7 8 9 10 ... 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.8 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files. ................................................................................ eventQueueInsert(ecb, iter) ; /* * Since we have stored a reference to the ECB we do * the bookkeeping. */ mechEventIncrRef(ecb) ; } #define MECH_DELAY_EXPIRED UINT32_MAX static void removeFromDelayedQueue( MechEcb ecb) { /* * If we are not at the end of the queue, all the delay * from the removed entry is accumulated on the next * entry in the queue. */ if (!(ecb->delay == MECH_DELAY_EXPIRED || ecb->next == eventQueueEnd(&delayedEventQueue))) { ecb->next->delay += ecb->delay ; } /* * Remove the ECB from the delayed queue. */ eventQueueRemove(ecb) ; /* * Return the ECB back to the pool. */ mechEventDelete(ecb) ; } static MechEcb expireDelayedEvents(void) { /* * Iterate along the delayed event queue. */ for (MechEcb iter = eventQueueBegin(&delayedEventQueue) ;

Changes to mechs/code/msp430/mechs.h.

 1 2 3 4 5 6 7 8 9 10 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.7 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files. | 1 2 3 4 5 6 7 8 9 10 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.8 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files.

Changes to mechs/code/msp430/platform.c.

 1 2 3 4 5 6 7 8 9 10 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.7 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files. | 1 2 3 4 5 6 7 8 9 10 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.8 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files.

Changes to mechs/code/posix/mechs.c.

 1 2 3 4 5 6 7 8 9 10 ... 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.7 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files. ................................................................................ eventQueueInsert(ecb, iter) ; /* * Since we have stored a reference to the ECB we do * the bookkeeping. */ mechEventIncrRef(ecb) ; } static void removeFromDelayedQueue( MechEcb ecb) { /* * If we are not at the end of the queue, all the delay * from the removed entry is accumulated on the next * entry in the queue. */ if (ecb->next != eventQueueEnd(&delayedEventQueue)) { ecb->next->delay += ecb->delay ; } /* * Remove the ECB from the delayed queue. */ eventQueueRemove(ecb) ; /* * Return the ECB back to the pool. */ mechEventDelete(ecb) ; } #define MECH_DELAY_EXPIRED UINT32_MAX static MechEcb expireDelayedEvents(void) { /* * Iterate along the delayed event queue. */ for (MechEcb iter = eventQueueBegin(&delayedEventQueue) ; | > > | < 1 2 3 4 5 6 7 8 9 10 ... 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.8 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files. ................................................................................ eventQueueInsert(ecb, iter) ; /* * Since we have stored a reference to the ECB we do * the bookkeeping. */ mechEventIncrRef(ecb) ; } #define MECH_DELAY_EXPIRED UINT32_MAX static void removeFromDelayedQueue( MechEcb ecb) { /* * If we are not at the end of the queue, all the delay * from the removed entry is accumulated on the next * entry in the queue. */ if (!(ecb->delay == MECH_DELAY_EXPIRED || ecb->next == eventQueueEnd(&delayedEventQueue))) { ecb->next->delay += ecb->delay ; } /* * Remove the ECB from the delayed queue. */ eventQueueRemove(ecb) ; /* * Return the ECB back to the pool. */ mechEventDelete(ecb) ; } static MechEcb expireDelayedEvents(void) { /* * Iterate along the delayed event queue. */ for (MechEcb iter = eventQueueBegin(&delayedEventQueue) ;

Changes to mechs/code/posix/mechs.h.

 1 2 3 4 5 6 7 8 9 10 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.7 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files. | 1 2 3 4 5 6 7 8 9 10 /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT IT. * This file corresponds to Version 1.8 of the STSA literate * program. */ /* * This software is copyrighted 2007 - 2014 by G. Andrew * Mangogna. The following terms apply to all files associated * with the software unless explicitly disclaimed in individual * files.

Changes to mechs/doc/mechs.pdf.

cannot compute difference between binary files

Changes to mechs/src/mechs.nw.

 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 .. 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 core_cm3.c\ log.c\ coreclock.c\ $(NULL) OBJS =$(patsubst %.c,%.o,$(SRCS)) INCLS =$(patsubst %,-I%,$(VPATH)) CC = arm-stellaris-eabi-gcc CPPFLAGS =\ -DMECH_TEST\ -DCM3_USE_SYSTICK\ -I$(CURDIR)\ $(INCLS)\$(NULL) CFLAGS +=\ -std=c99\ -O3\ -g3\ ................................................................................ -mthumb\ -T lm3s811-rom-hosted.ld\ $(NULL) all : mechstest mechstest :$(OBJS) $(CC)$(LDFLAGS) -o mechstest $(OBJS) mechstest.o : mechstest.c mechs.h td.h td.o : td.c td.h mechs.o : mechs.c mechs.h core_cm3.h log.o : log.c log.h core_cm3.o : core_cm3.c core_cm3.h mechs.h : core_cm3.h | > > | 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 .. 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 core_cm3.c\ log.c\ coreclock.c\$(NULL) OBJS = $(patsubst %.c,%.o,$(SRCS)) INCLS = $(patsubst %,-I%,$(VPATH)) CC = arm-none-eabi-gcc CPPFLAGS =\ -DMECH_TEST\ -DCM3_USE_SYSTICK\ -mcpu=cortex-m3\ -march=armv7-m\ -I$(CURDIR)\$(INCLS)\ $(NULL) CFLAGS +=\ -std=c99\ -O3\ -g3\ ................................................................................ -mthumb\ -T lm3s811-rom-hosted.ld\$(NULL) all : mechstest mechstest : $(OBJS) -$(CC) $(LDFLAGS) -o mechstest$(OBJS) mechstest.o : mechstest.c mechs.h td.h td.o : td.c td.h mechs.o : mechs.c mechs.h core_cm3.h log.o : log.c log.h core_cm3.o : core_cm3.c core_cm3.h mechs.h : core_cm3.h