git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@223 35acf78f-673a-0410-8e92-d51de3d6d3f4
This commit is contained in:
parent
88c256ae52
commit
869cacb3d4
|
@ -65,6 +65,8 @@ AVR-AT90CANx-GCC - Port on AVR AT90CAN128, not tested on hardware yet.
|
||||||
*** 0.6.1 ***
|
*** 0.6.1 ***
|
||||||
- Removed some redundant checks from the scheduler code: improved threads
|
- Removed some redundant checks from the scheduler code: improved threads
|
||||||
flyback time.
|
flyback time.
|
||||||
|
- Manual optimization in chSchReadyI(), it seems GCC is missing some obvious
|
||||||
|
code optimizations here. Both code size and speed improved.
|
||||||
- Removed the -falign-functions=16 option from the AT91SAM7X demo makefiles,
|
- Removed the -falign-functions=16 option from the AT91SAM7X demo makefiles,
|
||||||
the Atmel chip does not require it, the option is still present on the
|
the Atmel chip does not require it, the option is still present on the
|
||||||
LPC21xx demos. This saves significant ROM space.
|
LPC21xx demos. This saves significant ROM space.
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
|
|
||||||
#include <ch.h>
|
#include <ch.h>
|
||||||
|
|
||||||
/** @cond never*/
|
/** @cond never */
|
||||||
ReadyList rlist;
|
ReadyList rlist;
|
||||||
/** @endcond */
|
/** @endcond */
|
||||||
|
|
||||||
|
@ -58,10 +58,11 @@ INLINE void chSchReadyI(Thread *tp, msg_t msg) {
|
||||||
#else
|
#else
|
||||||
void chSchReadyI(Thread *tp, msg_t msg) {
|
void chSchReadyI(Thread *tp, msg_t msg) {
|
||||||
#endif
|
#endif
|
||||||
Thread *cp = rlist.r_queue.p_next;
|
Thread *cp;
|
||||||
|
|
||||||
tp->p_state = PRREADY;
|
tp->p_state = PRREADY;
|
||||||
tp->p_rdymsg = msg;
|
tp->p_rdymsg = msg;
|
||||||
|
cp = rlist.r_queue.p_next;
|
||||||
while (cp->p_prio >= tp->p_prio)
|
while (cp->p_prio >= tp->p_prio)
|
||||||
cp = cp->p_next;
|
cp = cp->p_next;
|
||||||
/* Insertion on p_prev.*/
|
/* Insertion on p_prev.*/
|
||||||
|
|
|
@ -107,30 +107,28 @@ struct Thread {
|
||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
/** Thread state: Reserved.*/
|
/** Thread state: Thread in the ready list.*/
|
||||||
#define PRFREE 0
|
#define PRREADY 0
|
||||||
/** Thread state: Current.*/
|
/** Thread state: Current.*/
|
||||||
#define PRCURR 1
|
#define PRCURR 1
|
||||||
/** Thread state: Thread in the ready list.*/
|
|
||||||
#define PRREADY 2
|
|
||||||
/** Thread state: Thread created in suspended state.*/
|
/** Thread state: Thread created in suspended state.*/
|
||||||
#define PRSUSPENDED 3
|
#define PRSUSPENDED 2
|
||||||
/** Thread state: Waiting on a semaphore.*/
|
/** Thread state: Waiting on a semaphore.*/
|
||||||
#define PRWTSEM 4
|
#define PRWTSEM 3
|
||||||
/** Thread state: Waiting on a mutex.*/
|
/** Thread state: Waiting on a mutex.*/
|
||||||
#define PRWTMTX 5
|
#define PRWTMTX 4
|
||||||
/** Thread state: Waiting in \p chThdSleep() or \p chThdSleepUntil().*/
|
/** Thread state: Waiting in \p chThdSleep() or \p chThdSleepUntil().*/
|
||||||
#define PRSLEEP 6
|
#define PRSLEEP 5
|
||||||
/** Thread state: Waiting in \p chThdWait().*/
|
/** Thread state: Waiting in \p chThdWait().*/
|
||||||
#define PRWAIT 7
|
#define PRWAIT 6
|
||||||
/** Thread state: Waiting in \p chEvtWait().*/
|
/** Thread state: Waiting in \p chEvtWait().*/
|
||||||
#define PRWTEVENT 8
|
#define PRWTEVENT 7
|
||||||
/** Thread state: Waiting in \p chMsgSend().*/
|
/** Thread state: Waiting in \p chMsgSend().*/
|
||||||
#define PRSNDMSG 9
|
#define PRSNDMSG 8
|
||||||
/** Thread state: Waiting in \p chMsgWait().*/
|
/** Thread state: Waiting in \p chMsgWait().*/
|
||||||
#define PRWTMSG 10
|
#define PRWTMSG 9
|
||||||
/** Thread state: After termination.*/
|
/** Thread state: After termination.*/
|
||||||
#define PREXIT 11
|
#define PREXIT 10
|
||||||
|
|
||||||
#ifdef CH_USE_TERMINATE
|
#ifdef CH_USE_TERMINATE
|
||||||
/** Thread option: Termination requested flag.*/
|
/** Thread option: Termination requested flag.*/
|
||||||
|
|
Loading…
Reference in New Issue