Closed
Bug 817134
Opened 13 years ago
Closed 13 years ago
Delete the low-res screenshot code
Categories
(Firefox for Android Graveyard :: Toolbar, defect)
Tracking
(firefox19 fixed, firefox20 fixed)
RESOLVED
FIXED
Firefox 20
People
(Reporter: kats, Assigned: kats)
References
Details
Attachments
(2 files)
49.21 KB,
patch
|
blassey
:
review+
akeybl
:
approval-mozilla-beta+
|
Details | Diff | Splinter Review |
36.88 KB,
patch
|
blassey
:
review+
akeybl
:
approval-mozilla-beta+
|
Details | Diff | Splinter Review |
Now that the low-res screenshot has been obsoleted by the progressive and low-res tiles stuff, we can delete the code. This includes all of the code in ScreenshotHandler as well as the AfterPaintListener goop in nsAppShell.cpp. We'll need to keep the AndroidBridge::TakeScreenshot and related code for the thumbnail codepaths, although it will need some renaming and rebinding of JNI functions.
Assignee | ||
Comment 1•13 years ago
|
||
This should also save a bunch of memory because we're still allocating a 2-meg buffer in ScreenshotLayer which we don't need to be doing.
Assignee | ||
Comment 2•13 years ago
|
||
Attachment #692373 -
Flags: review?(blassey.bugs)
Assignee | ||
Comment 3•13 years ago
|
||
Attachment #692374 -
Flags: review?(blassey.bugs)
Assignee | ||
Updated•13 years ago
|
Attachment #692374 -
Attachment description: Delete maor code and stop wasting memory → Delete moar code and stop wasting memory
Comment 4•13 years ago
|
||
Comment on attachment 692373 [details] [diff] [review]
Delete some code
Review of attachment 692373 [details] [diff] [review]:
-----------------------------------------------------------------
Can we get rid of the ScreenshotLayer entirely?
::: widget/android/AndroidBridge.cpp
@@ +2459,5 @@
> jobject JNICALL
> Java_org_mozilla_gecko_GeckoAppShell_allocateDirectBuffer(JNIEnv *env, jclass, jlong size);
>
>
> +nsresult AndroidBridge::TakeThumbnail(nsIDOMWindow *window, int32_t bufW, int32_t bufH, int32_t tabId, jobject buffer)
naming nit, I'd go with CaptureThumnail()
Attachment #692373 -
Flags: review?(blassey.bugs) → review+
Comment 5•13 years ago
|
||
Comment on attachment 692374 [details] [diff] [review]
Delete moar code and stop wasting memory
Review of attachment 692374 [details] [diff] [review]:
-----------------------------------------------------------------
guess I should have looked at this patch before asking about removing ScreenshotLayer
Attachment #692374 -
Flags: review?(blassey.bugs) → review+
Assignee | ||
Comment 6•13 years ago
|
||
Comment 7•13 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/35a2b968dc98
https://hg.mozilla.org/mozilla-central/rev/0f45583754ca
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 20
Assignee | ||
Comment 8•13 years ago
|
||
Note: the removal of the 2-meg direct-allocation buffer reduces Fennec's startup vsize by the corresponding 2 megs, but doesn't reduce RSS that much because most of the 2 megs was never touched and so remained unmapped anyway.
Whiteboard: [MemShrink]
![]() |
||
Comment 9•13 years ago
|
||
Can/should we land this on 19 as well? It looks like this "fixes" topcrash bug 817514.
Assignee | ||
Comment 10•13 years ago
|
||
I think we can uplift it, yeah. I'll request approval once I have a chance to apply the patch on aurora and make sure none of the conflicts are dealbreakers (it's a large patch and will definitely not apply cleanly).
Assignee | ||
Comment 11•13 years ago
|
||
Comment on attachment 692373 [details] [diff] [review]
Delete some code
[Approval Request Comment]
Bug caused by (feature/regressing bug #): unknown
User impact if declined: some crashes in screenshotting-related code, like bug 805353 and bug 817514.
Testing completed (on m-c, etc.): on m-c, nightlies (FF20) since mid-december
Risk to taking this patch (and alternatives if risky): touches android code only. the patches are large-ish but i was able to rebase them successfully to 19 branch, so I don't think there's a lot of risk. Note that the second patch here rebases much more easily if patch #2 from bug 820556 is also uplifted, so i will request uplift for that as well.
String or UUID changes made by this patch: none
Try build with the rebased patches: https://tbpl.mozilla.org/?tree=Try&rev=1248c582658d
Attachment #692373 -
Flags: approval-mozilla-beta?
Assignee | ||
Updated•13 years ago
|
status-firefox19:
--- → affected
status-firefox20:
--- → fixed
Assignee | ||
Comment 12•13 years ago
|
||
Comment on attachment 692374 [details] [diff] [review]
Delete moar code and stop wasting memory
[Approval Request Comment]
Same as above
Attachment #692374 -
Flags: approval-mozilla-beta?
Comment 13•13 years ago
|
||
Comment on attachment 692373 [details] [diff] [review]
Delete some code
Approving in support of fixing top crasher bug 817514 - we'll have a few weeks of bake time with this change.
Attachment #692373 -
Flags: approval-mozilla-beta? → approval-mozilla-beta+
Updated•13 years ago
|
Attachment #692374 -
Flags: approval-mozilla-beta? → approval-mozilla-beta+
Assignee | ||
Comment 14•13 years ago
|
||
Updated•5 years ago
|
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•