Forráskód Böngészése

mitigate warnings

Gabriel Wang 3 éve
szülő
commit
e4d768fa28
7 módosított fájl, 14 hozzáadás és 10 törlés
  1. 1 1
      Doxyfile
  2. 5 2
      GorgonMeducer.perf_counter.pdsc
  3. 1 1
      README.md
  4. 2 2
      lib/perf_counter.h
  5. BIN
      lib/perf_counter.lib
  6. 3 2
      perf_counter.c
  7. 2 2
      perf_counter.h

+ 1 - 1
Doxyfile

@@ -38,7 +38,7 @@ PROJECT_NAME           = perf_counter
 # could be handy for archiving the generated documentation or if some version
 # control system is used.
 
-PROJECT_NUMBER         = v2.0.0
+PROJECT_NUMBER         = v2.1.0
 
 # Using the PROJECT_BRIEF tag one can provide an optional one line description
 # for a project that appears at the top of each page and should give viewer a

+ 5 - 2
GorgonMeducer.perf_counter.pdsc

@@ -16,7 +16,10 @@
   <repository type="git">https://github.com/GorgonMeducer/perf_counter.git</repository>
   
   <releases>
-    <release date="2023-03-02" version="2.0.0" url="https://raw.githubusercontent.com/GorgonMeducer/perf_counter/CMSIS-Pack/cmsis-pack/GorgonMeducer.perf_counter.2.0.0.pack">
+    <release date="2023-03-03" version="2.1.0-dev" url="https://raw.githubusercontent.com/GorgonMeducer/perf_counter/CMSIS-Pack/cmsis-pack/GorgonMeducer.perf_counter.2.1.0-dev.pack">
+      - Add Coremark
+    </release>
+    <release date="2023-03-02" version="2.0.0" url="https://github.com/GorgonMeducer/perf_counter/raw/0c6b79b20308bb9b7d15a7c65f0fe91174c78061/cmsis-pack/GorgonMeducer.perf_counter.2.0.0.pack">
       - Add Coremark
     </release>
     <release date="2023-02-09" version="1.9.11" url="https://github.com/GorgonMeducer/perf_counter/raw/659eb12026977d81391d90290706f9ac3c8efe7e/cmsis-pack/GorgonMeducer.perf_counter.1.9.11.pack">
@@ -227,7 +230,7 @@
   -->
 
     <components>
-        <bundle Cbundle="Performance Counter" Cclass="Utilities" Cversion="2.0.0">
+        <bundle Cbundle="Performance Counter" Cclass="Utilities" Cversion="2.1.0-dev">
             <description>A dedicated performance counter for Cortex-M systick.</description>
             <doc>documents/Doxygen/html/index.html</doc>
             <component Cgroup="perf_counter" Csub="Core" Cvariant="Library" condition="CMSIS-CORE">

+ 1 - 1
README.md

@@ -1,4 +1,4 @@
-# perf_counter (v2.0.0)
+# perf_counter (v2.1.0-dev)
 A dedicated performance counter for Cortex-M Systick. It shares the SysTick with users' original SysTick function(s) without interfering with it. This library will bring new functionalities, such as performance counter,` delay_us` and `clock()` service defined in `time.h`.
 
 ### Features:

+ 2 - 2
lib/perf_counter.h

@@ -34,10 +34,10 @@ extern "C" {
  * @{
  */
 #define __PERF_COUNTER_VER_MAJOR__          2
-#define __PERF_COUNTER_VER_MINOR__          0
+#define __PERF_COUNTER_VER_MINOR__          1
 #define __PERF_COUNTER_VER_REVISE__         0
 
-#define __PERF_COUNTER_VER_STR__            ""
+#define __PERF_COUNTER_VER_STR__            "dev"
 
 #define __PER_COUNTER_VER__    (__PERF_COUNTER_VER_MAJOR__ * 10000ul            \
                                +__PERF_COUNTER_VER_MINOR__ * 100ul              \

BIN
lib/perf_counter.lib


+ 3 - 2
perf_counter.c

@@ -35,6 +35,7 @@
 #   pragma clang diagnostic ignored "-Wreserved-identifier"
 #   pragma clang diagnostic ignored "-Wconditional-uninitialized"
 #   pragma clang diagnostic ignored "-Wcast-align"
+#   pragma clang diagnostic ignored "-Wmissing-prototypes"
 #endif
 
 
@@ -554,9 +555,9 @@ unregister_task_cycle_agent(task_cycle_info_agent_t *ptAgent)
 void __on_context_switch_in(uint32_t *pwStack)
 {
     struct __task_cycle_info_t *ptRootAgent = (struct __task_cycle_info_t *)pwStack;
-    uint64_t dwTimeStamp = get_system_ticks();
+    int64_t lTimeStamp = get_system_ticks();
 
-    ptRootAgent->lLastTimeStamp = dwTimeStamp;
+    ptRootAgent->lLastTimeStamp = lTimeStamp;
     ptRootAgent->tInfo.hwActiveCount++;
 
     if (MAGIC_WORD_AGENT_LIST_VALID == ptRootAgent->wMagicWord) {

+ 2 - 2
perf_counter.h

@@ -34,10 +34,10 @@ extern "C" {
  * @{
  */
 #define __PERF_COUNTER_VER_MAJOR__          2
-#define __PERF_COUNTER_VER_MINOR__          0
+#define __PERF_COUNTER_VER_MINOR__          1
 #define __PERF_COUNTER_VER_REVISE__         0
 
-#define __PERF_COUNTER_VER_STR__            ""
+#define __PERF_COUNTER_VER_STR__            "dev"
 
 #define __PER_COUNTER_VER__    (__PERF_COUNTER_VER_MAJOR__ * 10000ul            \
                                +__PERF_COUNTER_VER_MINOR__ * 100ul              \