Dedication of all processor power to a task

Let's say we have a very difficult task that can be effectively parallelized. How can we allocate all or almost all available processor power for this task?

The task can be varied, and the iterative generation of the Fibonacci number, which stores the recorded numbers, will be just one example.

+3
source share
4 answers

You may have provided too little information about your target environment.

RTOS , , , , , ISR . , , .

RTOS ( ), , (.. , ), , . , Windows 100% , . , - , .

- , "" . ( ) .

+3

. , , , ( "" Linux) .

0

, , .

:

1/ , , USB, CAN, SPI - , ( Processort), , . ( , ) . , (, ...)

2/ , ( , , ), , , !

, , , ... , "" !

, .

0

.

Disable each disk access and other IO lock caused by this or another process. If you need to do this, do it late, release it. Using multiple cores in parallel threads and establishing a dependency between the processor or communication between processors can help - the latter is likely to be OS specific.

Set the process priority so that it gets bigger.

0
source

Source: https://habr.com/ru/post/1746656/


All Articles