summaryrefslogtreecommitdiff
path: root/fpdfsdk/src/javascript/console.cpp
diff options
context:
space:
mode:
authorBruce Dawson <brucedawson@google.com>2014-12-12 21:30:37 -0800
committerBo Xu <bo_xu@foxitsoftware.com>2014-12-19 14:43:09 -0800
commitc674af4698ab5fd1ce48b069bd72aa4c5fa10c6c (patch)
tree33d02d749cc95930c30ebb0ad7f6e14d0fe0fca8 /fpdfsdk/src/javascript/console.cpp
parent293b95f26ee3b561db09ecec88406583e7d566f6 (diff)
downloadpdfium-c674af4698ab5fd1ce48b069bd72aa4c5fa10c6c.tar.xz
XFA: merge patch from CL 441988
Avoid duplicate definitions of JSCONST_n*Hash and QeTable variables. QeTable is a 752 byte array that was defined in a header file. This caused it to be instantiated by the VC++ compiler 12 times, wasting 8,272 bytes of space in the data segment. Because 'const' implies 'static' this did not cause any duplicate symbol errors. JSCONST_n*HASH are a set of eight variables that are defined in a header file. This causes them to be replicated 15 times. The variables themselves are tiny but they are dynamically initialized and this dynamic initialization code is replicated 15 times. When tested on pdfium_test.exe the effect of this change is to: Reduce the .text (code) segment by 3,616 bytes. Reduce the .rdata section by 8,656 bytes. Reduce the total binary file size by 13312 bytes. These are the worst offenders for pdf.dll as shown in: https://drive.google.com/open?id=1BvubxoA2SU_2e4T5cq7jHTjc1TlT0qOndpIfX3DMeA8&authuser=0 This will also drastically simplify the list of work to be done for bug 441899 (getting rid of initializers). BUG=441988 R=bo_xu@foxitsoftware.com Review URL: https://codereview.chromium.org/802013002
Diffstat (limited to 'fpdfsdk/src/javascript/console.cpp')
0 files changed, 0 insertions, 0 deletions