Join Simon Allardice for an in-depth discussion in this video Basic measurement, part of Foundations of Programming: Code Efficiency.
- View Offline
As with memory, we could begin measuring and…profiling our algorithms by just looking at one number.…The overall CPU amount the application or process is…using, using task manager or activity monitor, but this…number by itself is not as directly useful as…when looking at the memory amount for two reasons.…First, while want some speed improvements, but this says nothing…about actual speed or the actual time anything is taking.…It's just how hard the CPU is being tasked by this process at this moment in time.…
And second, this number is more variable than the…memory amount, because it's dependent on the hardware specification.…If your application needs 50 megabytes of memory…to run on a slow machine, and then you…put it on a fast machine, you would still expect it to need 50 megabytes of memory.…But you would expect to see a different CPU number.…Less…CPU, on the faster machine. So, what is a good number here?…Ten? 20?…50?…Well, of course there is no good number, there's only a good number for your app.…Based on whatever your App is doing on whatever machine your App is running on.…
Learn to choose the right data types, understand the pitfalls of using high-level languages, and decide where to spend your time. Plus, see how the underlying memory management model may have more of an impact than you realize, and what performance issues you can expect working with databases and web services.
- Identifying problems in the code
- Embracing constraints
- Using code analysis tools to measure performance
- Managing memory
- Managing disk-based and network resources
Skill Level Beginner
Foundations of Programming: Refactoring Codewith Simon Allardice1h 44m Intermediate
1. Approaching Efficiency
4. Algorithmic Efficiency
5. Disk-Based and Network Resources
Next steps6m 4s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.