Join Simon Allardice for an in-depth discussion in this video Strategies for memory efficiency, part of Foundations of Programming: Code Efficiency.
- View Offline
So we want to improve memory efficiency in our code.…So first, we measure.…We profile the application.…We need some kind of data over time, even if that's just a few second's worth.…So we'll use a Profiling tool of some kind.…Like the allocations option, using Instruments.…Or if we're in the Visual Studio Profiling tools, there's…a memory allocation option, or whatever equivalent you can get to.…We want to profile, rather than just look at a single…memory number, at 1 moment in time.…Because we want to see this area of our own allocated objects.…
Whether you call this area the heap or something else, because if it is growing…as the program runs, you really have three kinds of growth this could be coming from.…We have the idea of leaked growth, you have an actual memory leak somewhere,…whether it's fast or whether it's slow,…but objects have been created and discarded…but never reclaimed.…And leaks will leave their own kind of memory foot print, when…we're looking at them, when we're profiling, as we'll see in a moment.…
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.