mozilla/pdf.js — pull request #4937 by nnethercote (2014-06-13 15:08:57+00:00)
Title: Halve the size of the PageView cache.

The PageView cache currently has a max size of 20. That seems overly generous. This patch reduces it to 10.

On my MacBook with a retina screen, the canvas for each page is typically about 22 MiB, so this reduces peak memory usage by 10 x 22 = 220 MiB. On my Linux desktop it's about 5.5 MiB per page, so it saves 10 x 5.5 = 55 MiB.