R
R
Rostislav Tsekhmistro2019-10-08 15:09:40
C++ / C#
Rostislav Tsekhmistro, 2019-10-08 15:09:40

How to optimize a C application?

When implementing complex image filtering algorithms, I ran into the problem of optimizing applications in terms of running time and the amount of memory used. If someone knows some good books on C-code optimization please tell me.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
T
tsarevfs, 2019-10-08
@rostik_tsekhmistro

Use a profiler to find problem areas. I work with https://developer.nvidia.com/nsight-systems, but there are others, including more popular options.
First of all, it is worth optimizing the asymptotic complexity.
Further it is possible to think of parallelization on some flows.
If everything is already optimal, you can look at micro optimizations:
https://habr.com/en/company/intel/blog/257309/
Well, in addition, you can use CUDA for GPU processing

A
Antonio Solo, 2019-10-08
@solotony

start with the grandfather of the whip, or something

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question