1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-24 00:35:39 +03:00

Merge pull request #5976 from DieHertz/mark-inlined-fastcode-functions-explicitly

Mark crucial inlined functions with FAST_CODE
This commit is contained in:
Michael Keller 2018-05-26 22:50:27 +12:00 committed by GitHub
commit 28a12dc203
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View file

@ -835,7 +835,7 @@ bool processRx(timeUs_t currentTimeUs)
return true; return true;
} }
static void subTaskPidController(timeUs_t currentTimeUs) static FAST_CODE void subTaskPidController(timeUs_t currentTimeUs)
{ {
uint32_t startTime = 0; uint32_t startTime = 0;
if (debugMode == DEBUG_PIDLOOP) {startTime = micros();} if (debugMode == DEBUG_PIDLOOP) {startTime = micros();}
@ -951,7 +951,7 @@ static FAST_CODE_NOINLINE void subTaskMainSubprocesses(timeUs_t currentTimeUs)
DEBUG_SET(DEBUG_PIDLOOP, 3, micros() - startTime); DEBUG_SET(DEBUG_PIDLOOP, 3, micros() - startTime);
} }
static void subTaskMotorUpdate(timeUs_t currentTimeUs) static FAST_CODE void subTaskMotorUpdate(timeUs_t currentTimeUs)
{ {
uint32_t startTime = 0; uint32_t startTime = 0;
if (debugMode == DEBUG_CYCLETIME) { if (debugMode == DEBUG_CYCLETIME) {

View file

@ -540,7 +540,7 @@ static void handleItermRotation()
// Betaflight pid controller, which will be maintained in the future with additional features specialised for current (mini) multirotor usage. // Betaflight pid controller, which will be maintained in the future with additional features specialised for current (mini) multirotor usage.
// Based on 2DOF reference design (matlab) // Based on 2DOF reference design (matlab)
void pidController(const pidProfile_t *pidProfile, const rollAndPitchTrims_t *angleTrim, timeUs_t currentTimeUs) void FAST_CODE pidController(const pidProfile_t *pidProfile, const rollAndPitchTrims_t *angleTrim, timeUs_t currentTimeUs)
{ {
static float previousGyroRateDterm[2]; static float previousGyroRateDterm[2];
static float previousPidSetpoint[2]; static float previousPidSetpoint[2];