![]() To improve run time we need to use compiler optimizations that will generate more efficient code. ![]() There is of course an obvious trade-off between the two. ![]() Now, multiply this wasted time in the number of times the code is being built throughout the day, the week, the month… This is a major cost in human time! We will return to this example with a solution that will keep you ahead of the game. If you disagree, just think about 6 engineers waiting for a build that takes 10 minutes – that’s 60 minutes of engineer time that is wasted, given, their ability to improve or analyze the code is completely put on hold or at least significantly restricted. Waiting for a build to complete is simply a waste of time. Most of us have only realized this when first working on relatively large-scale codebases. Build time is also important and sometimes critical. We all learned to consider it when writing a computer program or algorithm. If this is too basic for you, perhaps you know a C++ beginner who would enjoy it □ Build Time and Run Time If you haven’t watched Chandler’s talk, he gives an interesting test case of pre- Move Semantics in C++11. If you want to read about move semantics, this one is nice. As Dori points out and Chandler demonstrates, we may very well think about code efficiency and its ecosystem of build, testing, and release in terms of three key measurements: run time, build time, and of course human time. In his blog how-to-create-efficient-c-parallel-builds, Dori refers us to Chandler Carruth’s excellent CPPCon 2019 talk titled “ There Are No Zero-cost Abstractions”.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |