-
Notifications
You must be signed in to change notification settings - Fork 24.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fabirc: Improvements in
ImageResponseObserverCoordinator
Summary: This diff contains some small improvements in `ImageResponseObserverCoordinator` which are pretty minor: * Now we use `small_vector` instead of a normal one. In the vast majority of cases, the coordinator has only one observer, so having `small_vector` with default size `1` saves us a memory allocation (which is a dozen of allocations for a screen, not bad). * Empty constructor and destructor were removed. * Unnecessary copying of ImageResponse was removed. ImageResponse is a practically a shared_pointer, it has value semantic and does not need to be copied. We don't need to acquire mutex to access that. Reviewed By: sammy-SC Differential Revision: D17368740 fbshipit-source-id: 828e27a72b9c8ac0063c5fbda00f83ddb255309c
- Loading branch information
1 parent
bfc9839
commit 69f9fd4
Showing
2 changed files
with
8 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters