From 52c033d27e37a0726604a7e4f69f6d1469a9d25f Mon Sep 17 00:00:00 2001 From: gdisirio Date: Sat, 8 Jan 2011 16:45:56 +0000 Subject: [PATCH] Cortex-M0 RCTV port. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@2619 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- demos/ARMCM0-LPC1114-LPCXPRESSO/keil/ch.uvopt | 274 +++++++++--------- docs/reports/LPC1114-48-RVCT.txt | 162 +++++++++++ docs/reports/LPC1114-48.txt | 2 +- docs/reports/LPC1343-72-IAR.txt | 2 +- docs/reports/LPC1343-72-RVCT.txt | 2 +- os/ports/IAR/ARMCMx/chcoreasm_v6m.s | 8 +- os/ports/RVCT/ARMCMx/chcoreasm_v6m.s | 2 +- 7 files changed, 307 insertions(+), 145 deletions(-) create mode 100644 docs/reports/LPC1114-48-RVCT.txt diff --git a/demos/ARMCM0-LPC1114-LPCXPRESSO/keil/ch.uvopt b/demos/ARMCM0-LPC1114-LPCXPRESSO/keil/ch.uvopt index ad6bc133e..0d1c92fbf 100644 --- a/demos/ARMCM0-LPC1114-LPCXPRESSO/keil/ch.uvopt +++ b/demos/ARMCM0-LPC1114-LPCXPRESSO/keil/ch.uvopt @@ -189,7 +189,7 @@ 0 0 0 - 1 + 0 0 @@ -204,7 +204,7 @@ 0 1 - 0 + 1 1 0 0 @@ -218,7 +218,7 @@ 1 - 0 + 2 5 0 0 @@ -245,19 +245,19 @@ 0 26 0 - 61 - 76 + 0 + 0 0 ..\..\..\os\ports\RVCT\ARMCMx\cstartup.s cstartup.s 2 - 5 + 4 1 0 0 - 0 + 1 0 0 0 @@ -267,7 +267,7 @@ 2 - 7 + 5 1 0 0 @@ -281,7 +281,7 @@ 2 - 8 + 6 5 0 0 @@ -295,7 +295,7 @@ 2 - 10 + 7 5 0 0 @@ -309,7 +309,7 @@ 2 - 11 + 8 5 0 0 @@ -323,11 +323,11 @@ 2 - 0 + 9 1 0 0 - 0 + 3 0 0 0 @@ -337,35 +337,35 @@ 2 - 0 + 10 5 0 0 0 0 - 221 - 251 + 0 + 0 0 ..\..\..\os\ports\RVCT\ARMCMx\chcore_v6m.h chcore_v6m.h 2 - 0 + 11 2 0 0 - 19 + 32 0 - 101 - 127 + 0 + 0 0 ..\..\..\os\ports\RVCT\ARMCMx\chcoreasm_v6m.s chcoreasm_v6m.s 2 - 0 + 12 5 0 0 @@ -379,11 +379,11 @@ 2 - 0 + 13 2 0 0 - 0 + 37 0 0 0 @@ -400,7 +400,7 @@ 0 3 - 13 + 14 1 0 0 @@ -414,7 +414,7 @@ 3 - 14 + 15 1 0 0 @@ -428,7 +428,7 @@ 3 - 15 + 16 1 0 0 @@ -442,7 +442,7 @@ 3 - 16 + 17 1 0 0 @@ -456,7 +456,7 @@ 3 - 17 + 18 1 0 0 @@ -470,7 +470,7 @@ 3 - 18 + 19 1 0 0 @@ -484,7 +484,7 @@ 3 - 19 + 20 1 0 0 @@ -498,7 +498,7 @@ 3 - 20 + 21 1 0 0 @@ -512,7 +512,7 @@ 3 - 21 + 22 1 0 0 @@ -526,7 +526,7 @@ 3 - 22 + 23 1 0 0 @@ -540,7 +540,7 @@ 3 - 23 + 24 1 0 0 @@ -554,7 +554,7 @@ 3 - 24 + 25 1 0 0 @@ -568,7 +568,7 @@ 3 - 25 + 26 1 0 0 @@ -582,11 +582,11 @@ 3 - 26 + 27 1 0 0 - 11 + 0 0 0 0 @@ -596,7 +596,7 @@ 3 - 27 + 28 1 0 0 @@ -610,11 +610,11 @@ 3 - 28 + 29 1 0 0 - 21 + 30 0 0 0 @@ -624,7 +624,7 @@ 3 - 29 + 30 1 0 0 @@ -638,7 +638,7 @@ 3 - 30 + 31 1 0 0 @@ -652,7 +652,7 @@ 3 - 31 + 32 5 0 0 @@ -666,7 +666,7 @@ 3 - 32 + 33 5 0 0 @@ -680,7 +680,7 @@ 3 - 33 + 34 5 0 0 @@ -694,7 +694,7 @@ 3 - 34 + 35 5 0 0 @@ -708,7 +708,7 @@ 3 - 35 + 36 5 0 0 @@ -722,7 +722,7 @@ 3 - 36 + 37 5 0 0 @@ -736,7 +736,7 @@ 3 - 37 + 38 5 0 0 @@ -750,7 +750,7 @@ 3 - 38 + 39 5 0 0 @@ -764,7 +764,7 @@ 3 - 39 + 40 5 0 0 @@ -778,7 +778,7 @@ 3 - 40 + 41 5 0 0 @@ -792,7 +792,7 @@ 3 - 41 + 42 5 0 0 @@ -806,7 +806,7 @@ 3 - 42 + 43 5 0 0 @@ -820,7 +820,7 @@ 3 - 43 + 44 5 0 0 @@ -834,7 +834,7 @@ 3 - 44 + 45 5 0 0 @@ -848,7 +848,7 @@ 3 - 45 + 46 5 0 0 @@ -862,7 +862,7 @@ 3 - 46 + 47 5 0 0 @@ -876,7 +876,7 @@ 3 - 47 + 48 5 0 0 @@ -890,7 +890,7 @@ 3 - 48 + 49 5 0 0 @@ -904,7 +904,7 @@ 3 - 49 + 50 5 0 0 @@ -918,7 +918,7 @@ 3 - 50 + 51 5 0 0 @@ -932,7 +932,7 @@ 3 - 51 + 52 5 0 0 @@ -946,7 +946,7 @@ 3 - 52 + 53 5 0 0 @@ -960,7 +960,7 @@ 3 - 53 + 54 5 0 0 @@ -974,7 +974,7 @@ 3 - 54 + 55 5 0 0 @@ -995,11 +995,11 @@ 0 4 - 55 + 56 1 0 0 - 13 + 0 0 0 0 @@ -1009,11 +1009,11 @@ 4 - 56 + 57 1 0 0 - 68 + 0 0 0 0 @@ -1023,7 +1023,7 @@ 4 - 57 + 58 1 0 0 @@ -1037,11 +1037,11 @@ 4 - 58 + 59 1 0 0 - 58 + 0 0 0 0 @@ -1051,7 +1051,7 @@ 4 - 59 + 60 1 0 0 @@ -1065,11 +1065,11 @@ 4 - 60 + 61 1 0 0 - 1 + 0 0 0 0 @@ -1079,7 +1079,7 @@ 4 - 61 + 62 1 0 0 @@ -1093,11 +1093,11 @@ 4 - 62 + 63 1 0 0 - 56 + 0 0 0 0 @@ -1107,11 +1107,11 @@ 4 - 63 + 64 1 0 0 - 32 + 0 0 0 0 @@ -1121,7 +1121,7 @@ 4 - 64 + 65 1 0 0 @@ -1135,7 +1135,7 @@ 4 - 65 + 66 1 0 0 @@ -1149,7 +1149,7 @@ 4 - 66 + 67 5 0 0 @@ -1163,7 +1163,7 @@ 4 - 67 + 68 5 0 0 @@ -1177,7 +1177,7 @@ 4 - 68 + 69 5 0 0 @@ -1191,7 +1191,7 @@ 4 - 69 + 70 5 0 0 @@ -1205,7 +1205,7 @@ 4 - 70 + 71 5 0 0 @@ -1219,7 +1219,7 @@ 4 - 71 + 72 5 0 0 @@ -1233,11 +1233,11 @@ 4 - 72 + 73 5 0 0 - 55 + 0 0 0 0 @@ -1247,7 +1247,7 @@ 4 - 73 + 74 5 0 0 @@ -1261,7 +1261,7 @@ 4 - 74 + 75 5 0 0 @@ -1275,7 +1275,7 @@ 4 - 75 + 76 5 0 0 @@ -1289,7 +1289,7 @@ 4 - 76 + 77 5 0 0 @@ -1303,7 +1303,7 @@ 4 - 77 + 78 5 0 0 @@ -1324,7 +1324,7 @@ 0 5 - 0 + 79 5 0 0 @@ -1338,7 +1338,7 @@ 5 - 0 + 80 1 0 0 @@ -1352,7 +1352,7 @@ 5 - 0 + 81 5 0 0 @@ -1366,7 +1366,7 @@ 5 - 0 + 82 5 0 0 @@ -1380,7 +1380,7 @@ 5 - 0 + 83 1 0 0 @@ -1394,7 +1394,7 @@ 5 - 0 + 84 5 0 0 @@ -1408,7 +1408,7 @@ 5 - 0 + 85 1 0 0 @@ -1422,7 +1422,7 @@ 5 - 0 + 86 5 0 0 @@ -1436,7 +1436,7 @@ 5 - 0 + 87 1 0 0 @@ -1450,7 +1450,7 @@ 5 - 0 + 88 5 0 0 @@ -1464,7 +1464,7 @@ 5 - 0 + 89 5 0 0 @@ -1485,7 +1485,7 @@ 0 6 - 89 + 90 1 0 0 @@ -1499,7 +1499,7 @@ 6 - 90 + 91 1 0 0 @@ -1513,7 +1513,7 @@ 6 - 91 + 92 1 0 0 @@ -1527,7 +1527,7 @@ 6 - 92 + 93 1 0 0 @@ -1541,7 +1541,7 @@ 6 - 93 + 94 1 0 0 @@ -1555,7 +1555,7 @@ 6 - 94 + 95 1 0 0 @@ -1569,7 +1569,7 @@ 6 - 95 + 96 1 0 0 @@ -1583,7 +1583,7 @@ 6 - 96 + 97 1 0 0 @@ -1597,7 +1597,7 @@ 6 - 97 + 98 1 0 0 @@ -1611,7 +1611,7 @@ 6 - 98 + 99 1 0 0 @@ -1625,7 +1625,7 @@ 6 - 99 + 100 1 0 0 @@ -1639,7 +1639,7 @@ 6 - 100 + 101 1 0 0 @@ -1653,7 +1653,7 @@ 6 - 101 + 102 5 0 0 @@ -1667,7 +1667,7 @@ 6 - 102 + 103 5 0 0 @@ -1681,7 +1681,7 @@ 6 - 103 + 104 5 0 0 @@ -1695,7 +1695,7 @@ 6 - 104 + 105 5 0 0 @@ -1709,7 +1709,7 @@ 6 - 105 + 106 5 0 0 @@ -1723,7 +1723,7 @@ 6 - 106 + 107 5 0 0 @@ -1737,7 +1737,7 @@ 6 - 107 + 108 5 0 0 @@ -1751,7 +1751,7 @@ 6 - 108 + 109 5 0 0 @@ -1765,7 +1765,7 @@ 6 - 109 + 110 5 0 0 @@ -1779,7 +1779,7 @@ 6 - 110 + 111 5 0 0 @@ -1793,7 +1793,7 @@ 6 - 111 + 112 5 0 0 @@ -1807,7 +1807,7 @@ 6 - 112 + 113 5 0 0 @@ -1823,12 +1823,12 @@ demo - 1 + 0 0 0 7 - 113 + 114 1 0 0 @@ -1842,7 +1842,7 @@ 7 - 114 + 115 5 0 0 @@ -1856,7 +1856,7 @@ 7 - 115 + 116 5 0 0 @@ -1870,7 +1870,7 @@ 7 - 116 + 117 5 0 0 diff --git a/docs/reports/LPC1114-48-RVCT.txt b/docs/reports/LPC1114-48-RVCT.txt new file mode 100644 index 000000000..17df988de --- /dev/null +++ b/docs/reports/LPC1114-48-RVCT.txt @@ -0,0 +1,162 @@ +*************************************************************************** +Options: -O3 -Otime --apcs=interwork +Settings: CLK=48, (2 wait states) +Compiler: RealView C/C++ Compiler V4.1.0.561 [Evaluation]. +*************************************************************************** + +*** ChibiOS/RT test suite +*** +*** Kernel: 2.1.7unstable +*** Architecture: ARMv6-M +*** Core Variant: Cortex-M0 +*** Platform: LPC11xx +*** Test Board: Embedded Artists LPCXpresso Base Board + LPC1114 + +---------------------------------------------------------------------------- +--- Test Case 1.1 (Threads, enqueuing test #1) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 1.2 (Threads, enqueuing test #2) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 1.3 (Threads, priority change) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 1.4 (Threads, delays) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 2.1 (Semaphores, enqueuing) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 2.2 (Semaphores, timeout) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 2.3 (Semaphores, atomic signal-wait) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 2.4 (Binary Semaphores, functionality) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 3.1 (Mutexes, priority enqueuing test) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 3.2 (Mutexes, priority inheritance, simple case) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 3.3 (Mutexes, priority inheritance, complex case) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 3.4 (Mutexes, priority return) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 3.5 (Mutexes, status) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 3.6 (CondVar, signal test) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 3.7 (CondVar, broadcast test) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 3.8 (CondVar, boost test) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 4.1 (Messages, loop) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 5.1 (Mailboxes, queuing and timeouts) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 6.1 (Events, registration and dispatch) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 6.2 (Events, wait and broadcast) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 6.3 (Events, timeouts) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 7.1 (Heap, allocation and fragmentation test) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 8.1 (Memory Pools, queue/dequeue) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 9.1 (Dynamic APIs, threads creation from heap) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 9.2 (Dynamic APIs, threads creation from memory pool) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 9.3 (Dynamic APIs, registry and references) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 10.1 (Queues, input queues) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 10.2 (Queues, output queues) +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.1 (Benchmark, messages #1) +--- Score : 116826 msgs/S, 233652 ctxswc/S +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.2 (Benchmark, messages #2) +--- Score : 100172 msgs/S, 200344 ctxswc/S +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.3 (Benchmark, messages #3) +--- Score : 99754 msgs/S, 199508 ctxswc/S +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.4 (Benchmark, context switch) +--- Score : 377360 ctxswc/S +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.5 (Benchmark, threads, full cycle) +--- Score : 79506 threads/S +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.6 (Benchmark, threads, create only) +--- Score : 112694 threads/S +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.7 (Benchmark, mass reschedule, 5 threads) +--- Score : 33626 reschedules/S, 201756 ctxswc/S +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.8 (Benchmark, round robin context switching) +--- Score : 246616 ctxswc/S +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.9 (Benchmark, I/O Queues throughput) +--- Score : 261068 bytes/S +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.10 (Benchmark, virtual timers set/reset) +--- Score : 301424 timers/S +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.11 (Benchmark, semaphores wait/signal) +--- Score : 614472 wait+signal/S +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.12 (Benchmark, mutexes lock/unlock) +--- Score : 382980 lock+unlock/S +--- Result: SUCCESS +---------------------------------------------------------------------------- +--- Test Case 11.13 (Benchmark, RAM footprint) +--- System: 360 bytes +--- Thread: 68 bytes +--- Timer : 20 bytes +--- Semaph: 12 bytes +--- EventS: 4 bytes +--- EventL: 12 bytes +--- Mutex : 16 bytes +--- CondV.: 8 bytes +--- Queue : 32 bytes +--- MailB.: 40 bytes +--- Result: SUCCESS +---------------------------------------------------------------------------- + +Final result: SUCCESS diff --git a/docs/reports/LPC1114-48.txt b/docs/reports/LPC1114-48.txt index 1f2bccf50..78f27a01c 100644 --- a/docs/reports/LPC1114-48.txt +++ b/docs/reports/LPC1114-48.txt @@ -1,6 +1,6 @@ *************************************************************************** Options: -O2 -fomit-frame-pointer -mabi=apcs-gnu -Settings: CLK=48, (3 wait states) +Settings: CLK=48, (2 wait states) *************************************************************************** *** ChibiOS/RT test suite diff --git a/docs/reports/LPC1343-72-IAR.txt b/docs/reports/LPC1343-72-IAR.txt index 28f540ce9..3b0b45d03 100644 --- a/docs/reports/LPC1343-72-IAR.txt +++ b/docs/reports/LPC1343-72-IAR.txt @@ -1,6 +1,6 @@ *************************************************************************** Options: -Ohs -Settings: SYSCLK=24, ACR=0x10 (no wait states) +Settings: CLK=72, (3 wait states) Compiler: IAR C/C++ Compiler for ARM 6.10.1.32143 *************************************************************************** diff --git a/docs/reports/LPC1343-72-RVCT.txt b/docs/reports/LPC1343-72-RVCT.txt index 66c41be00..6edf4f2b5 100644 --- a/docs/reports/LPC1343-72-RVCT.txt +++ b/docs/reports/LPC1343-72-RVCT.txt @@ -1,6 +1,6 @@ *************************************************************************** Options: -O3 -Otime --apcs=interwork -Settings: SYSCLK=72, ACR=0x12 (2 wait states) +Settings: CLK=72, (3 wait states) Compiler: RealView C/C++ Compiler V4.1.0.561 [Evaluation]. *************************************************************************** diff --git a/os/ports/IAR/ARMCMx/chcoreasm_v6m.s b/os/ports/IAR/ARMCMx/chcoreasm_v6m.s index 5f0887960..07d89e6b5 100644 --- a/os/ports/IAR/ARMCMx/chcoreasm_v6m.s +++ b/os/ports/IAR/ARMCMx/chcoreasm_v6m.s @@ -111,20 +111,20 @@ _port_irq_epilogue: subs r3, r3, #1 str r3, [r2] cmp r3, #0 - beq .L34 + beq skipexit +notrequired cpsie i pop {r4, pc} -.L34: +skipexit bl chSchIsRescRequiredExI cmp r0, #0 - beq .L31 + beq notrequired mrs r1, PSP ldr r2, =_port_saved_pc ldr r3, [r1, #24] str r3, [r2] ldr r3, =_port_switch_from_isr str r3, [r1, #24] -.L31: pop {r4, pc} END diff --git a/os/ports/RVCT/ARMCMx/chcoreasm_v6m.s b/os/ports/RVCT/ARMCMx/chcoreasm_v6m.s index e813d7eca..8f348f099 100644 --- a/os/ports/RVCT/ARMCMx/chcoreasm_v6m.s +++ b/os/ports/RVCT/ARMCMx/chcoreasm_v6m.s @@ -110,6 +110,7 @@ _port_irq_epilogue PROC str r3, [r2] cmp r3, #0 beq skipexit +notrequired cpsie i pop {r4, pc} skipexit @@ -122,7 +123,6 @@ skipexit str r3, [r2] ldr r3, =_port_switch_from_isr str r3, [r1, #24] -notrequired pop {r4, pc} nop ENDP