4 ms·
Most C++-projects I dealt with are neither clean nor performant. I rather follow clean code to improve maintainability and get things done than to optimize for
by devdude1337 4y ago
Most C++-projects I dealt with are neither clean nor performant. I rather follow clean code to improve maintainability and get things done than to optimize for performance.
It’s also easier to find bottlenecks in a well readable and testable code base than in a premature-optimized one.
However it is true that the more abstractions and indirections used software gets slower.
Also these examples are too basic to make a real-world suggestion: never assume sonething is slow in a large project because of indirection or something…always get a profiler involved and run tests with time requirements to identify and fix slow running parts of a program.