IP Library Granted Patent US 9,798,581
Granted Patent B2
US 9,798,581 · App. 14/495,816 · Granted Oct 24, 2017

Multi-threaded processing of user interfaces for an application

Inventor: Scott Paul Goodson (Emerald Hills, CA)
Assignee: FACEBOOK, INC.
G06F9/4881G06F2209/509
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 9,798,581
App. No.
14/495,816
Granted
Oct 24, 2017
Kind
B2
Abstract

A method performed at an electronic device with a display includes: processing tasks in an application program; at least partially processing a plurality of layout objects in the application program; in accordance with a determination that one or more predefined control criteria are satisfied, pausing the processing of the plurality of layout objects in the application program; while the processing of the plurality of layout objects in the application program is paused, processing system tasks; and, after processing the system tasks while the processing of the plurality of layout objects in the application program is paused, resuming the processing of the plurality of layout objects.

Claims (32)

1. A method, comprising:

at an electronic device with a display, one or more processors, and memory storing one or more programs for execution by the one or more processors:

processing tasks in an application program on a main thread;

at least partially processing a plurality of layout objects in the application program on one or more background threads distinct from the main thread;

in accordance with a determination that one or more predefined background-thread-to-main-thread-control criteria are satisfied, pausing the processing of the plurality of layout objects in the application program on the one or more background threads and giving control of processing the application program to the main thread, wherein the display is refreshed at a predefined rate and the one or more predefined background-thread-to-main-thread-control criteria include a predefined time interval that corresponds to one refresh cycle or less at the predefined rate;

while the processing of the plurality of layout objects in the application program is paused, processing system tasks on the main thread, comprising processing at least a subset of tasks in the application program on the main thread; and,

after processing the system tasks on the main thread while the processing of the plurality of layout objects in the application program is paused, resuming the processing of the plurality of layout objects on the one or more background threads.

2. The method of claim 1 , including processing a plurality of view objects in the application program on the main thread, wherein a hierarchy of the plurality of view objects is identical to a hierarchy of the plurality of layout objects and each view object of the plurality of view objects corresponds to a respective layout object of the plurality of layout objects.

3. The method of claim 2 , wherein the plurality of view objects in the application program is not configured for processing on any background thread.

4. The method of claim 1 , wherein processing the plurality of layout objects in the application program on the one or more background threads includes determining layout parameters for the plurality of layout objects.

5. The method of claim 1 , wherein the processing of the plurality of layout objects is paused based on a thread control value included in the application program.

6. The method of claim 1 , wherein the subset of tasks in the application program includes processing a user input.

7. The method of claim 1 , wherein the subset of tasks in the application program includes updating a display of a user interface in the application program.

8. An electronic device, comprising:

a display,

one or more processors, and

memory storing one or more programs for execution by the one or more processors, the one or more programs including instructions for:

processing tasks in an application program on a main thread;

at least partially processing a plurality of layout objects in the application program on one or more background threads distinct from the main thread;

in accordance with a determination that one or more predefined background-thread-to-main-thread-control criteria are satisfied, pausing the processing of the plurality of layout objects in the application program on the one or more background threads and giving control of processing the application program to the main thread, wherein the display is refreshed at a predefined rate and the one or more predefined background-thread-to-main-thread-control criteria include a predefined time interval that corresponds to one refresh cycle or less at the predefined rate;

while the processing of the plurality of layout objects in the application program is paused, processing system tasks on the main thread, comprising processing at least a subset of tasks in the application program on the main thread; and,

after processing the system tasks on the main thread while the processing of the plurality of layout objects in the application program is paused, resuming the processing of the plurality of layout objects on the one or more background threads.

9. The device of claim 8 , wherein the one or more programs include instructions for processing a plurality of view objects in the application program on the main thread, wherein a hierarchy of the plurality of view objects is identical to a hierarchy of the plurality of layout objects and each view object of the plurality of view objects corresponds to a respective layout object of the plurality of layout objects.

10. The device of claim 9 , wherein the plurality of view objects in the application program is not configured for processing on any background thread.

11. The device of claim 8 , wherein the instructions for processing the plurality of layout objects in the application program on the one or more background threads include instructions for determining layout parameters for the plurality of layout objects.

12. The device of claim 8 , wherein the processing of the plurality of layout objects is paused based on a thread control value included in the application program.

13. A non-transitory computer readable storage medium, storing one or more programs for execution by one or more processors of an electronic device with a display, the one or more programs including instructions for:

processing tasks in an application program on a main thread;

at least partially processing a plurality of layout objects in the application program on one or more background threads distinct from the main thread;

in accordance with a determination that one or more predefined background-thread-to-main-thread-control criteria are satisfied, pausing the processing of the plurality of layout objects in the application program on the one or more background threads and giving control of processing the application program to the main thread, wherein the display is refreshed at a predefined rate and the one or more predefined background-thread-to-main-thread-control criteria include a predefined time interval that corresponds to one refresh cycle or less at the predefined rate;

while the processing of the plurality of layout objects in the application program is paused, processing system tasks on the main thread, comprising processing at least a subset of tasks in the application program on the main thread; and,

after processing the system tasks on the main thread while the processing of the plurality of layout objects in the application program is paused, resuming the processing of the plurality of layout objects on the one or more background threads.

Assignments (2)
CHANGE OF NAME Recorded Dec 16, 2021
From: FACEBOOK, INC.
To: META PLATFORMS, INC.
Reel/Frame 058520/0535 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Dec 3, 2014
From: GOODSON, SCOTT PAUL
To: FACEBOOK, INC.
Reel/Frame 034365/0001 →
Continuity (1)
Related Publication 20160085583A1 · Mar 24, 2016