Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix caching of small inline images in Parser.makeInlineImage (issue 8790) #8792

Merged
merged 2 commits into from
Aug 19, 2017
Merged

Fix caching of small inline images in Parser.makeInlineImage (issue 8790) #8792

merged 2 commits into from
Aug 19, 2017

Conversation

Snuffleupagus
Copy link
Collaborator

Follow-up to PR #5445.

Using the PDF file from issue #2618, i.e. http://bugzilla-attachments.gnome.org/attachment.cgi?id=226471, with the following manifest file:

[
    {  "id": "issue2618",
       "file": "../web/pdfs/issue2618.pdf",
       "md5": "",
       "rounds": 50,
       "type": "eq"
    }
]

I get the following results when comparing master against this patch:

browser | stat         | Count | Baseline(ms) | Current(ms) |  +/- |     %  | Result(P<.05)
------- | ------------ | ----- | ------------ | ----------- | ---- | ------ | -------------
firefox | Overall      |    50 |         4694 |        3974 | -721 | -15.35 |        faster
firefox | Page Request |    50 |            2 |           1 |    0 | -22.83 |
firefox | Rendering    |    50 |         4692 |        3972 | -720 | -15.35 |        faster

So, based on these results, it seems like a fairly clear win to fix this broken caching :-)

Fixes #8790.

… 8790)

*Follow-up to PR 5445.*

Using the PDF file from issue 2618, i.e. http://bugzilla-attachments.gnome.org/attachment.cgi?id=226471, with the following manifest file:
```json
[
    {  "id": "issue2618",
       "file": "../web/pdfs/issue2618.pdf",
       "md5": "",
       "rounds": 50,
       "type": "eq"
    }
]
```
I get the following results when comparing `master` against this patch:
```
browser | stat         | Count | Baseline(ms) | Current(ms) |  +/- |     %  | Result(P<.05)
------- | ------------ | ----- | ------------ | ----------- | ---- | ------ | -------------
firefox | Overall      |    50 |         4694 |        3974 | -721 | -15.35 |        faster
firefox | Page Request |    50 |            2 |           1 |    0 | -22.83 |
firefox | Rendering    |    50 |         4692 |        3972 | -720 | -15.35 |        faster
```

So, based on these results, it seems like a fairly clear win to fix this broken caching :-)
I've gotten tired of having to manually re-install the `ttest` package on numerous occasions when benchmarking changes, so let's just list it in package.json to simplify things.
@Snuffleupagus
Copy link
Collaborator Author

/botio test

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Received

Command cmd_test from @Snuffleupagus received. Current queue size: 0

Live output at: http://54.67.70.0:8877/4f2880d2dfeddbe/output.txt

@pdfjsbot
Copy link

From: Bot.io (Windows)


Received

Command cmd_test from @Snuffleupagus received. Current queue size: 0

Live output at: http://54.215.176.217:8877/181618a2fcf9116/output.txt

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Success

Full output at http://54.67.70.0:8877/4f2880d2dfeddbe/output.txt

Total script time: 16.45 mins

  • Font tests: Passed
  • Unit tests: Passed
  • Regression tests: Passed

@pdfjsbot
Copy link

From: Bot.io (Windows)


Success

Full output at http://54.215.176.217:8877/181618a2fcf9116/output.txt

Total script time: 29.45 mins

  • Font tests: Passed
  • Unit tests: Passed
  • Regression tests: Passed

@Snuffleupagus Snuffleupagus merged commit 9b26bec into mozilla:master Aug 19, 2017
@Snuffleupagus Snuffleupagus deleted the issue-8790 branch August 19, 2017 07:13
movsb pushed a commit to movsb/pdf.js that referenced this pull request Jul 14, 2018
Fix caching of small inline images in `Parser.makeInlineImage` (issue 8790)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Is imageCache in Parser working?
3 participants