![]() |
GPUart
1.01
Prototype of GPUart, an application-based limited preemptive GPU scheduler for embedded real-time systems
|
#include "../Sobel1/SWC_Sobel1.h"#include "../Sobel2/SWC_Sobel2.h"#include "../MatrMul/SWC_MM.h"#include "SWC_Scheduler.h"#include "../../GPUart/GPUart.h"#include <pthread.h>#include <signal.h>#include <time.h>#include <unistd.h>#include <stdlib.h>#include <string.h>#include <stdio.h>
Macros | |
| #define | C_SWC_SCH_NUMBER_OF_THREADS (4) |
| #define | C_SWC_SCH_SYSTEM_OPERATION_TIME (100000) |
| #define | C_SWC_SCH_TIMER_RESOLUTION (100 * 1000/*ns -> 0.1 ms resolution*/) |
| #define | C_SWC_SCH_NR_DIFFERENT_PERIODS (10) |
| #define | C_SWC_SCH_PERIOD_1MS (0) |
| #define | C_SWC_SCH_PERIOD_2MS (1) |
| #define | C_SWC_SCH_PERIOD_5MS (2) |
| #define | C_SWC_SCH_PERIOD_10MS (3) |
| #define | C_SWC_SCH_PERIOD_20MS (4) |
| #define | C_SWC_SCH_PERIOD_50MS (5) |
| #define | C_SWC_SCH_PERIOD_100MS (6) |
| #define | C_SWC_SCH_PERIOD_200MS (7) |
| #define | C_SWC_SCH_PERIOD_500MS (8) |
| #define | C_SWC_SCH_PERIOD_1000MS (9) |
Functions | |
| static void * | swc_Scheduler_MPMD (void *args) |
| static void | swc_Scheduler_Timer (void) |
| static void | swc_Scheduler_Thread0 (void) |
| static void | swc_Scheduler_Thread1 (void) |
| static void | swc_Scheduler_Thread2 (void) |
| unsigned int | swc_Scheduler_getClock (void) |
| void | swc_init (void) |
| void | swc_Scheduler_init (void) |
| void | swc_Scheduler_run (void) |
Variables | |
| static const unsigned int | swc_sch_task_periods [C_SWC_SCH_NR_DIFFERENT_PERIODS] |
| static const unsigned int | swc_sch_task_activ_offsets [C_SWC_SCH_NUMBER_OF_THREADS-1][C_SWC_SCH_NR_DIFFERENT_PERIODS] |
| static unsigned char | swc_sch_task_used [C_SWC_SCH_NUMBER_OF_THREADS-1][C_SWC_SCH_NR_DIFFERENT_PERIODS] |
| static volatile unsigned char | swc_sch_task_event [C_SWC_SCH_NUMBER_OF_THREADS-1][C_SWC_SCH_NR_DIFFERENT_PERIODS] |
| static volatile unsigned char | swc_sch_terminate_threads = 0u |
| static unsigned int | swc_Scheduler_clock = 0u |
| #define C_SWC_SCH_NR_DIFFERENT_PERIODS (10) |
| #define C_SWC_SCH_NUMBER_OF_THREADS (4) |
| #define C_SWC_SCH_PERIOD_1000MS (9) |
| #define C_SWC_SCH_PERIOD_100MS (6) |
| #define C_SWC_SCH_PERIOD_10MS (3) |
| #define C_SWC_SCH_PERIOD_1MS (0) |
| #define C_SWC_SCH_PERIOD_200MS (7) |
| #define C_SWC_SCH_PERIOD_20MS (4) |
| #define C_SWC_SCH_PERIOD_2MS (1) |
| #define C_SWC_SCH_PERIOD_500MS (8) |
| #define C_SWC_SCH_PERIOD_50MS (5) |
| #define C_SWC_SCH_PERIOD_5MS (2) |
| #define C_SWC_SCH_SYSTEM_OPERATION_TIME (100000) |
| #define C_SWC_SCH_TIMER_RESOLUTION (100 * 1000/*ns -> 0.1 ms resolution*/) |
| void swc_init | ( | void | ) |


| unsigned int swc_Scheduler_getClock | ( | void | ) |

| void swc_Scheduler_init | ( | void | ) |

|
static |


| void swc_Scheduler_run | ( | void | ) |


|
static |


|
static |


|
static |


|
static |

|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
1.8.6