4 ms·
To make something fast or to make something scale you don't need a proof. You need a profiler.
by pepve 14y ago
To make something fast or to make something scale you don't need a proof. You need a profiler.
- regularfry 14y agoTo a certain degree, this is true. However, a profiler won't turn the DFT into the FFT.
- nitrogen 14y agoThe FFT only needs to be invented and optimized once, though, then everyone else can just link in libfftw or kissfft. All those software tradespeople can do the jobs that require connecting pieces together. A tradesperson can be taught enough to know which algorithms to apply in which situations. Computer scientists become academics inventing new algorithms, and analyzing and perfecting the ad hoc algorithms created by software tradespeople. Aside: I wish the English language would just decide that "man" and "men", when used as part of a compound word like "tradesman", is gender neutral.
- regularfry 14y ago> The FFT only needs to be invented and optimized once, though, then everyone else can just link in libfftw or kissfft. > All those software tradespeople can do the jobs that require connecting pieces together. A tradesperson can be taught enough to know which algorithms to apply in which situations. Is that a circular argument? If we had enough people cranking out smart enough algorithms (like the automatic programming example upthread), would we need so many tradespeople?
- UK-AL 14y agoA profiler is for micro optimisations. A profiler won't let you go from bubble to quick sort for example.
- arethuza 14y agoIn my view, all performance optimisations need to be driven by hard data and a profiler is just one source of this kind of data.
- Negitivefrags 14y agoA profiler will tell you if sorting actually using a meaningful amount time in your application. If you go ahead and blindly change your bubble sorts for quick sorts then at best you may be wasting time doing something that has no effect on performance, and at worst you may be making your program slower. Quicksort is slower than bubble sort for nearly sorted input after all.
- UK-AL 14y agoIt does give you information on where the most time is being spent, but it doesn't tell you what to implement. Without adequate algorithm knowledge you might try a micro optimisation when it really needs a completely different algorithm. With superficial knowledge you might stick to certain rules without really understanding them. That bubble sort example you gave is a perfect example.
- enjo 14y agoMaybe not, but Google will:)
- InclinedPlane 14y agoYou are operating under the assumption that the performance of an average piece of software is algorithmically limited, this is almost never the case. In average software the core performance characteristics are typically bound by far simpler issues, such as excessive database queries. A profiler is not good at speed up an algorithm, but a profiler is THE tool you need to speed up a system, and most optimization in the wild is system optimization, not algorithm optimization. This particular example is a perfect case study in how excessive focus on computer science can lead you astray in software engineering.