git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@1983 35acf78f-673a-0410-8e92-d51de3d6d3f4
This commit is contained in:
parent
4ee7918764
commit
b2db83ef52
|
@ -1,5 +1,5 @@
|
|||
|
||||
<ApplicationBuild Header="ch" Extern=".\ch.rapp" Path=".\ch.rapp" OutputFile="..\STM8S-STM8S208-RC/bin\ch.aof" sate="98" >
|
||||
<ApplicationBuild Header="ch" Extern=".\ch.rapp" Path=".\ch.rapp" OutputFile="..\STM8S-STM8S208-RC/bin\ch.aof" sate="96" >
|
||||
<Group Header="kernel" Marker="-1" OutputFile="" sate="0" >
|
||||
<NodeC Path="..\..\os\kernel\src\chcond.c" Header="chcond.c" Marker="-1" OutputFile="..\STM8S-STM8S208-RC/bin\chcond.obj" sate="0" />
|
||||
<NodeC Path="..\..\os\kernel\src\chdebug.c" Header="chdebug.c" Marker="-1" OutputFile="..\STM8S-STM8S208-RC/bin\chdebug.obj" sate="0" />
|
||||
|
@ -28,20 +28,8 @@
|
|||
<NodeC Path="..\..\os\kernel\src\chmtx.c" Header="chmtx.c" Marker="-1" OutputFile="..\STM8S-STM8S208-RC/bin\chmtx.obj" sate="0" />
|
||||
<NodeC Path="..\..\os\kernel\src\chqueues.c" Header="chqueues.c" Marker="-1" OutputFile="..\STM8S-STM8S208-RC/bin\chqueues.obj" sate="0" />
|
||||
<NodeC Path="..\..\os\kernel\src\chregistry.c" Header="chregistry.c" Marker="-1" OutputFile="..\STM8S-STM8S208-RC/bin\chregistry.obj" sate="0" />
|
||||
<NodeC Path="..\..\os\kernel\src\chschd.c" Header="chschd.c" Marker="0" OutputFile="..\STM8S-STM8S208-RC/bin\chschd.obj" sate="0" >
|
||||
<Options>
|
||||
<Config Header="Standard" >
|
||||
<Set Header="RCST7" >
|
||||
<Section Header="Model" >
|
||||
<Property Header="GlobalMemory" Value="" Removable="1" />
|
||||
|
||||
</Section>
|
||||
|
||||
</Set>
|
||||
|
||||
</Config>
|
||||
|
||||
</Options>
|
||||
<NodeC Path="..\..\os\kernel\src\chschd.c" Header="chschd.c" Marker="-1" OutputFile="..\STM8S-STM8S208-RC/bin\chschd.obj" sate="0" >
|
||||
<Options/>
|
||||
|
||||
</NodeC>
|
||||
<NodeC Path="..\..\os\kernel\src\chsem.c" Header="chsem.c" Marker="-1" OutputFile="..\STM8S-STM8S208-RC/bin\chsem.obj" sate="0" />
|
||||
|
@ -84,7 +72,7 @@
|
|||
<NodeC Path="..\..\os\ports\RC\STM8\chcore.c" Header="chcore.c" Marker="-1" OutputFile="..\STM8S-STM8S208-RC/bin\chcore.obj" sate="0" />
|
||||
|
||||
</Group>
|
||||
<Group Header="hal" Marker="-1" OutputFile="" sate="96" >
|
||||
<Group Header="hal" Marker="-1" OutputFile="" sate="0" >
|
||||
<NodeC Path="..\..\os\hal\src\adc.c" Header="adc.c" Marker="-1" OutputFile="..\STM8S-STM8S208-RC/bin\adc.obj" sate="0" />
|
||||
<NodeC Path="..\..\os\hal\src\can.c" Header="can.c" Marker="-1" OutputFile="..\STM8S-STM8S208-RC/bin\can.obj" sate="0" />
|
||||
<NodeC Path="..\..\os\hal\src\hal.c" Header="hal.c" Marker="-1" OutputFile="..\STM8S-STM8S208-RC/bin\hal.obj" sate="0" />
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
|
||||
<Project Header="Project 'ch'" Path=".\ch.rprj" Project="Yes" OutputFile="" sate="96" ActiveApp="ch" >
|
||||
<ApplicationBuild Header="ch" Extern=".\ch.rapp" Path=".\ch.rapp" OutputFile="..\STM8S-STM8S208-RC/bin\ch.aof" sate="98" />
|
||||
<Project Header="Project 'ch'" Path=".\ch.rprj" Project="Yes" OutputFile="" sate="98" ActiveApp="ch" >
|
||||
<ApplicationBuild Header="ch" Extern=".\ch.rapp" Path=".\ch.rapp" OutputFile="..\STM8S-STM8S208-RC/bin\ch.aof" sate="96" />
|
||||
</Project>
|
|
@ -6,7 +6,7 @@ Compiler: Raisonance RKit-STM8_2.28.10.0092
|
|||
|
||||
*** ChibiOS/RT test suite
|
||||
***
|
||||
*** Kernel: 1.5.7unstable
|
||||
*** Kernel: 1.5.9unstable
|
||||
*** Architecture: STM8
|
||||
*** Platform: STM8x
|
||||
*** Test Board: Raisonance REva V3 + STM8S208RB
|
||||
|
@ -67,31 +67,31 @@ Compiler: Raisonance RKit-STM8_2.28.10.0092
|
|||
--- Result: SUCCESS
|
||||
----------------------------------------------------------------------------
|
||||
--- Test Case 11.1 (Benchmark, messages #1)
|
||||
--- Score : 31156 msgs/S, 62312 ctxswc/S
|
||||
--- Score : 31277 msgs/S, 62554 ctxswc/S
|
||||
--- Result: SUCCESS
|
||||
----------------------------------------------------------------------------
|
||||
--- Test Case 11.2 (Benchmark, messages #2)
|
||||
--- Score : 24035 msgs/S, 48070 ctxswc/S
|
||||
--- Score : 24107 msgs/S, 48214 ctxswc/S
|
||||
--- Result: SUCCESS
|
||||
----------------------------------------------------------------------------
|
||||
--- Test Case 11.3 (Benchmark, messages #3)
|
||||
--- Score : 24035 msgs/S, 48070 ctxswc/S
|
||||
--- Score : 24107 msgs/S, 48214 ctxswc/S
|
||||
--- Result: SUCCESS
|
||||
----------------------------------------------------------------------------
|
||||
--- Test Case 11.4 (Benchmark, context switch)
|
||||
--- Score : 108456 ctxswc/S
|
||||
--- Score : 108544 ctxswc/S
|
||||
--- Result: SUCCESS
|
||||
----------------------------------------------------------------------------
|
||||
--- Test Case 11.5 (Benchmark, threads, full cycle)
|
||||
--- Score : 17186 threads/S
|
||||
--- Score : 17261 threads/S
|
||||
--- Result: SUCCESS
|
||||
----------------------------------------------------------------------------
|
||||
--- Test Case 11.6 (Benchmark, threads, create only)
|
||||
--- Score : 26073 threads/S
|
||||
--- Score : 26116 threads/S
|
||||
--- Result: SUCCESS
|
||||
----------------------------------------------------------------------------
|
||||
--- Test Case 11.7 (Benchmark, mass reschedule, 5 threads)
|
||||
--- Score : 6884 reschedules/S, 41304 ctxswc/S
|
||||
--- Score : 6919 reschedules/S, 41514 ctxswc/S
|
||||
--- Result: SUCCESS
|
||||
----------------------------------------------------------------------------
|
||||
--- Test Case 11.8 (Benchmark, round robin context switching)
|
||||
|
@ -99,19 +99,19 @@ Compiler: Raisonance RKit-STM8_2.28.10.0092
|
|||
--- Result: SUCCESS
|
||||
----------------------------------------------------------------------------
|
||||
--- Test Case 11.9 (Benchmark, I/O Queues throughput)
|
||||
--- Score : 65072 bytes/S
|
||||
--- Score : 64416 bytes/S
|
||||
--- Result: SUCCESS
|
||||
----------------------------------------------------------------------------
|
||||
--- Test Case 11.10 (Benchmark, virtual timers set/reset)
|
||||
--- Score : 55670 timers/S
|
||||
--- Score : 55770 timers/S
|
||||
--- Result: SUCCESS
|
||||
----------------------------------------------------------------------------
|
||||
--- Test Case 11.11 (Benchmark, semaphores wait/signal)
|
||||
--- Score : 220452 wait+signal/S
|
||||
--- Score : 211692 wait+signal/S
|
||||
--- Result: SUCCESS
|
||||
----------------------------------------------------------------------------
|
||||
--- Test Case 11.12 (Benchmark, RAM footprint)
|
||||
--- System: 179 bytes
|
||||
--- System: 177 bytes
|
||||
--- Thread: 29 bytes
|
||||
--- Timer : 10 bytes
|
||||
--- Semaph: 6 bytes
|
||||
|
|
|
@ -28,6 +28,8 @@
|
|||
|
||||
#include "ch.h"
|
||||
|
||||
page0 ReadyList rlist;
|
||||
|
||||
/**
|
||||
* @brief Performs a context switch between two threads.
|
||||
*
|
||||
|
@ -38,12 +40,10 @@ void _port_switch(Thread *otp) {
|
|||
(void)otp;
|
||||
/* Asm because unoptimal code would generated by using _getSP_().*/
|
||||
#pragma ASM
|
||||
EXTRN PAGE0(rlist)
|
||||
|
||||
LDW Y,SP ; old context pointer
|
||||
LDW (005H,X),Y ; SP saved in otp->p_ctx.sp
|
||||
LDW X,rlist + 0DH ; r_current (currp) field
|
||||
LDW X,(005H,X) ; currp->p_ctx.sp
|
||||
LDW (5,X),Y ; SP saved in otp->p_ctx.sp
|
||||
LDW X,rlist + 5 ; r_current (currp) field
|
||||
LDW X,(5,X) ; currp->p_ctx.sp
|
||||
LDW SP,X ; new context pointer
|
||||
#pragma ENDASM
|
||||
}
|
||||
|
|
|
@ -273,6 +273,30 @@ extern "C" {
|
|||
}
|
||||
#endif
|
||||
|
||||
/*===========================================================================*/
|
||||
/* Scheduler captured code. */
|
||||
/*===========================================================================*/
|
||||
|
||||
#define PORT_OPTIMIZED_RLIST_VAR
|
||||
#define PORT_OPTIMIZED_RLIST_EXT
|
||||
#define PORT_OPTIMIZED_READYLIST_STRUCT
|
||||
|
||||
typedef struct {
|
||||
ThreadsQueue r_queue;
|
||||
tprio_t r_prio;
|
||||
Thread *r_current;
|
||||
#if CH_USE_REGISTRY
|
||||
Thread *r_newer;
|
||||
Thread *r_older;
|
||||
#endif
|
||||
/* End of the fields shared with the Thread structure.*/
|
||||
#if CH_TIME_QUANTUM > 0
|
||||
cnt_t r_preempt;
|
||||
#endif
|
||||
} ReadyList;
|
||||
|
||||
extern page0 ReadyList rlist;
|
||||
|
||||
#endif /* _CHCORE_H_ */
|
||||
|
||||
/** @} */
|
||||
|
|
Loading…
Reference in New Issue