cleaning up
All checks were successful
EIVE/eive-obsw/pipeline/pr-develop This commit looks good

This commit is contained in:
Robin Müller 2023-03-28 21:58:04 +02:00
parent 4d1fbbcabd
commit 4c57e48399
No known key found for this signature in database
GPG Key ID: 11D4952C8CCEF814
2 changed files with 1 additions and 22 deletions

View File

@ -15,7 +15,6 @@ PersistentLogTmStoreTask::PersistentLogTmStoreTask(object_id_t objectId, Storage
ReturnValue_t PersistentLogTmStoreTask::performOperation(uint8_t opCode) {
bool someonesBusy = false;
bool vcBusyDuringDump = false;
bool byteFlowControl = false;
auto stateHandlingForStore = [&](bool storeIsBusy, DumpContext& ctx) {
if (storeIsBusy) {
someonesBusy = true;
@ -26,10 +25,6 @@ ReturnValue_t PersistentLogTmStoreTask::performOperation(uint8_t opCode) {
if (ctx.vcBusyDuringDump) {
vcBusyDuringDump = true;
}
if (ctx.dumpedBytes - ctx.bytesDumpedAtLastDelay >= 2048) {
byteFlowControl = true;
ctx.bytesDumpedAtLastDelay = ctx.dumpedBytes;
}
};
while (true) {
if (not cyclicStoreCheck()) {
@ -45,7 +40,7 @@ ReturnValue_t PersistentLogTmStoreTask::performOperation(uint8_t opCode) {
TaskFactory::delayTask(100);
} else if (vcBusyDuringDump) {
// TODO: Might not be necessary
TaskFactory::delayTask(20);
TaskFactory::delayTask(10);
}
}
}

View File

@ -11,11 +11,6 @@ PersistentSingleTmStoreTask::PersistentSingleTmStoreTask(
dumpContext(eventIfDumpDone, eventIfCancelled) {}
ReturnValue_t PersistentSingleTmStoreTask::performOperation(uint8_t opCode) {
ReturnValue_t result = returnvalue::OK;
uint32_t delaysVcBusyDuringDump = 0;
uint32_t delaysFlowControl = 0;
uint32_t delayNotBusy = 0;
uint32_t delayHotLoop = 0;
while (true) {
// Delay done by the check
if (not cyclicStoreCheck()) {
@ -24,21 +19,10 @@ ReturnValue_t PersistentSingleTmStoreTask::performOperation(uint8_t opCode) {
bool busy = handleOneStore(storeWithQueue, dumpContext);
if (not busy) {
TaskFactory::delayTask(100);
delayNotBusy++;
} else if (dumpContext.vcBusyDuringDump) {
// TODO: Might not be necessary
delaysVcBusyDuringDump++;
TaskFactory::delayTask(10);
} else {
delayHotLoop++;
}
// if ((delaysVcBusyDuringDump + delaysFlowControl + delayNotBusy + delayHotLoop) % 2000 ==
// 0) {
// sif::debug << "DLY NBUSY: " << delayNotBusy << std::endl;
// sif::debug << "DLY FLCTRL: " << delaysFlowControl << std::endl;
// sif::debug << "DLY BUSYDUMP: " << delaysVcBusyDuringDump << std::endl;
// sif::debug << "DLY HOTLOOP: " << delayHotLoop << std::endl;
// }
}
}