|
|
DescriptionUse flat_set in SurfaceAggregator.
The sets and maks are typically small or empty and created once. flat_set and
flat_map will have better performance for these workloads.
See the bug for histograms of sizes.
BUG=712295
CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel
Review-Url: https://codereview.chromium.org/2823043002
Cr-Commit-Position: refs/heads/master@{#465040}
Committed: https://chromium.googlesource.com/chromium/src/+/95286bcd87997785c90c4194d65a430d082bc784
Patch Set 1 #Patch Set 2 : More #Patch Set 3 : More #
Total comments: 1
Messages
Total messages: 19 (12 generated)
Description was changed from ========== Use flat_set SurfaceAggregator. The unordered_set is typically small or empty and created once. flat_set will have better performance for these workloads. The unordered_set will always create a hash table on the heap, and will do one list item allocation per insert. This ends up showing in profiles of frequent callers of malloc since this function is called so often. BUG=712295 ========== to ========== Use flat_set SurfaceAggregator. The unordered_set is typically small or empty and created once. flat_set will have better performance for these workloads. The unordered_set will always create a hash table on the heap, and will do one list item allocation per insert. This ends up showing in profiles of frequent callers of malloc since this function is called so often. BUG=712295 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel ==========
Description was changed from ========== Use flat_set SurfaceAggregator. The unordered_set is typically small or empty and created once. flat_set will have better performance for these workloads. The unordered_set will always create a hash table on the heap, and will do one list item allocation per insert. This ends up showing in profiles of frequent callers of malloc since this function is called so often. BUG=712295 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel ========== to ========== Use flat_set in SurfaceAggregator. The unordered_set is typically small or empty and created once. flat_set will have better performance for these workloads. The unordered_set will always create a hash table on the heap, and will do one list item allocation per insert. This ends up showing in profiles of frequent callers of malloc since this function is called so often. BUG=712295 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel ==========
Description was changed from ========== Use flat_set in SurfaceAggregator. The unordered_set is typically small or empty and created once. flat_set will have better performance for these workloads. The unordered_set will always create a hash table on the heap, and will do one list item allocation per insert. This ends up showing in profiles of frequent callers of malloc since this function is called so often. BUG=712295 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel ========== to ========== Use flat_set in SurfaceAggregator. The sets and maks are typically small or empty and created once. flat_set and flat_map will have better performance for these workloads. See the bug for histograms of sizes. BUG=712295 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel ==========
More
brettw@chromium.org changed reviewers: + jbauman@chromium.org
See the bug for stats. If there are degenerate cases where there can be hundreds or thousands of surfaces, please let me know so I can test. https://codereview.chromium.org/2823043002/diff/40001/cc/surfaces/surface_agg... File cc/surfaces/surface_aggregator.cc (right): https://codereview.chromium.org/2823043002/diff/40001/cc/surfaces/surface_agg... cc/surfaces/surface_aggregator.cc:772: referenced_surfaces_.erase(referenced_surfaces_.find(surface->surface_id())); This changed because the set is mutated in between the previous insertion, and flat_set iterators are not stable.
The CQ bit was checked by brettw@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
lgtm With oopif there could be degenerate cases if a page nests a ton of iframes, but there are probably other expensive operations there.
On 2017/04/17 21:19:34, jbauman wrote: > lgtm > > With oopif there could be degenerate cases if a page nests a ton of iframes, but > there are probably other expensive operations there. Even with several hundred it won't fall over, so that should be fine. Thanks!
The CQ bit was checked by brettw@chromium.org
The CQ bit was unchecked by brettw@chromium.org
The CQ bit was unchecked by brettw@chromium.org
The CQ bit was checked by brettw@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
CQ is committing da patch. Bot data: {"patchset_id": 40001, "attempt_start_ts": 1492464341348230, "parent_rev": "fb11d048bac3ddc72bb78399e5b7e8057fd050c7", "commit_rev": "95286bcd87997785c90c4194d65a430d082bc784"}
Message was sent while issue was closed.
Description was changed from ========== Use flat_set in SurfaceAggregator. The sets and maks are typically small or empty and created once. flat_set and flat_map will have better performance for these workloads. See the bug for histograms of sizes. BUG=712295 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel ========== to ========== Use flat_set in SurfaceAggregator. The sets and maks are typically small or empty and created once. flat_set and flat_map will have better performance for these workloads. See the bug for histograms of sizes. BUG=712295 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel Review-Url: https://codereview.chromium.org/2823043002 Cr-Commit-Position: refs/heads/master@{#465040} Committed: https://chromium.googlesource.com/chromium/src/+/95286bcd87997785c90c4194d65a... ==========
Message was sent while issue was closed.
Committed patchset #3 (id:40001) as https://chromium.googlesource.com/chromium/src/+/95286bcd87997785c90c4194d65a...
Message was sent while issue was closed.
A revert of this CL (patchset #3 id:40001) has been created in https://codereview.chromium.org/2824953002/ by alexmos@chromium.org. The reason for reverting is: Seems to be causing several tests to fail: https://build.chromium.org/p/chromium.chromiumos/builders/Linux%20ChromiumOS%... Failure output: ../../build/linux/debian_jessie_amd64-sysroot/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../include/c++/4.8/debug/safe_iterator.210: error: attempt to construct a constant iterator from a singular mutable iterator. Objects involved in the operation: iterator "this" @ 0x0x7fff97b205a0 { state = dereferenceable; references sequence @ 0x0x7fff97b205a0 } iterator "other" @ 0x0x7fff97b20878 { state = singular; references sequence @ 0x0x7fff97b20878 } Received signal 6 #0 0x7f0cbdddb56b base::debug::StackTrace::StackTrace() #1 0x7f0cbddda2ac base::debug::StackTrace::StackTrace() #2 0x7f0cbdddb07f base::debug::(anonymous namespace)::StackDumpSignalHandler() #3 0x7f0cbe22f330 <unknown> #4 0x7f0ca248ac37 gsignal #5 0x7f0ca248e028 abort #6 0x7f0ca2adffe5 __gnu_debug::_Error_formatter::_M_error() #7 0x7f0cb26be3ad _ZN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPKN2cc9SurfaceIdENSt9__cxx19986vectorIS4_SaIS4_EEEEENSt7__debug6vectorIS4_S9_EEEC2INS2_IPS4_SA_EEEERKNS0_IT_NS1_11__enable_ifIXsr3std10__are_sameISJ_SI_EE7__valueESE_E6__typeEEE #8 0x7f0cb26ce1de cc::SurfaceAggregator::HandleSurfaceQuad() #9 0x7f0cb26ce94f cc::SurfaceAggregator::CopyQuadsToPass() #10 0x7f0cb26cf76e cc::SurfaceAggregator::CopyPasses() #11 0x7f0cb26d1df6 cc::SurfaceAggregator::Aggregate() #12 0x7f0cb268aacc cc::Display::DrawAndSwap() #13 0x7f0cb269c3ab cc::DisplayScheduler::DrawAndSwap() #14 0x7f0cb269baf6 cc::DisplayScheduler::AttemptDrawAndSwap() #15 0x7f0cb269b3ef cc::DisplayScheduler::OnBeginFrameDeadline() #16 0x7f0cb269c92b cc::DisplayScheduler::OnBeginFrameDerivedImpl() #17 0x7f0cb2f1b179 cc::BeginFrameObserverBase::OnBeginFrame() #18 0x7f0cb2f1cd96 cc::DelayBasedBeginFrameSource::OnTimerTick() #19 0x7f0cb2f34d1a cc::DelayBasedTimeSource::OnTimerTick() #20 0x7f0cb2d90107 _ZN4base8internal13FunctorTraitsIMN2cc28ScrollbarAnimationControllerEFvvEvE6InvokeIRKNS_7WeakPtrIS3_EEJEEEvS5_OT_DpOT0_ #21 0x7f0cb2f354da _ZN4base8internal12InvokeHelperILb1EvE8MakeItSoIRKMN2cc20DelayBasedTimeSourceEFvvERKNS_7WeakPtrIS5_EEJEEEvOT_OT0_DpOT1_ #22 0x7f0cb2f35462 _ZN4base8internal7InvokerINS0_9BindStateIMN2cc20DelayBasedTimeSourceEFvvEJNS_7WeakPtrIS4_EEEEEFvvEE7RunImplIRKS6_RKSt5tupleIJS8_EEJLm0EEEEvOT_OT0_NS_13IndexSequenceIJXspT1_EEEE #23 0x7f0cb2f353ac _ZN4base8internal7InvokerINS0_9BindStateIMN2cc20DelayBasedTimeSourceEFvvEJNS_7WeakPtrIS4_EEEEEFvvEE3RunEPNS0_13BindStateBaseE #24 0x7f0cb2d9044d _ZNKR4base8CallbackIFvvELNS_8internal8CopyModeE1ELNS2_10RepeatModeE1EE3RunEv #25 0x7f0cb2d8fe29 base::CancelableCallback<>::Forward() #26 0x7f0cb2d90107 _ZN4base8internal13FunctorTraitsIMN2cc28ScrollbarAnimationControllerEFvvEvE6InvokeIRKNS_7WeakPtrIS3_EEJEEEvS5_OT_DpOT0_ #27 0x7f0cb2d9005a _ZN4base8internal12InvokeHelperILb1EvE8MakeItSoIRKMNS_18CancelableCallbackIFvvEEEKFvvERKNS_7WeakPtrIS6_EEJEEEvOT_OT0_DpOT1_ #28 0x7f0cb2d8ffe2 _ZN4base8internal7InvokerINS0_9BindStateIMNS_18CancelableCallbackIFvvEEEKFvvEJNS_7WeakPtrIS5_EEEEES4_E7RunImplIRKS7_RKSt5tupleIJS9_EEJLm0EEEEvOT_OT0_NS_13IndexSequenceIJXspT1_EEEE #29 0x7f0cb2d8ff2c _ZN4base8internal7InvokerINS0_9BindStateIMNS_18CancelableCallbackIFvvEEEKFvvEJNS_7WeakPtrIS5_EEEEES4_E3RunEPNS0_13BindStateBaseE #30 0x7f0cbdde126e _ZNO4base8CallbackIFvvELNS_8internal8CopyModeE0ELNS2_10RepeatModeE0EE3RunEv #31 0x7f0cbdde0a61 base::debug::TaskAnnotator::RunTask() #32 0x7f0cbde68f1e base::MessageLoop::RunTask() #33 0x7f0cbde69184 base::MessageLoop::DeferOrRunPendingTask() #34 0x7f0cbde6970c base::MessageLoop::DoDelayedWork() #35 0x7f0cbde7ee68 base::MessagePumpGlib::Run() #36 0x7f0cbde68b02 base::MessageLoop::RunHandler() #37 0x7f0cbdf02a64 base::RunLoop::Run() #38 0x000004f3de76 content::RunThisRunLoop() #39 0x0000089f1d0e extensions::ResultCatcher::GetNextResult() #40 0x000001657c6c ExtensionApiTest::RunExtensionTestImpl() #41 0x000001657685 ExtensionApiTest::RunExtensionTest() #42 0x000000d8d146 extensions::ContentScriptApiTest_ContentScriptExtensionIframe_Test::RunTestOnMainThread() #43 0x000003db23d5 InProcessBrowserTest::RunTestOnMainThreadLoop() #44 0x000004eb9764 content::BrowserTestBase::ProxyRunTestOnMainThreadLoop() #45 0x00000093c845 _ZN4base8internal13FunctorTraitsIM25RenderViewContextMenuBaseFvvEvE6InvokeIP21RenderViewContextMenuJEEEvS4_OT_DpOT0_ #46 0x00000093c761 _ZN4base8internal12InvokeHelperILb0EvE8MakeItSoIRKM25RenderViewContextMenuBaseFvvEJP21RenderViewContextMenuEEEvOT_DpOT0_ #47 0x000004eba6a7 _ZN4base8internal7InvokerINS0_9BindStateIMN7content15BrowserTestBaseEFvvEJNS0_17UnretainedWrapperIS4_EEEEEFvvEE7RunImplIRKS6_RKSt5tupleIJS8_EEJLm0EEEEvOT_OT0_NS_13IndexSequenceIJXspT1_EEEE #48 0x000004eba5ec _ZN4base8internal7InvokerINS0_9BindStateIMN7content15BrowserTestBaseEFvvEJNS0_17UnretainedWrapperIS4_EEEEEFvvEE3RunEPNS0_13BindStateBaseE #49 0x00000092405d _ZNKR4base8CallbackIFvvELNS_8internal8CopyModeE1ELNS2_10RepeatModeE1EE3RunEv #50 0x000003e5880e ChromeBrowserMainParts::PreMainMessageLoopRunImpl() #51 0x000003e57450 ChromeBrowserMainParts::PreMainMessageLoopRun() #52 0x000001e20bab chromeos::ChromeBrowserMainPartsChromeos::PreMainMessageLoopRun() #53 0x7f0cb55d2931 content::BrowserMainLoop::PreMainMessageLoopRun() #54 0x7f0cb48e4af5 _ZN4base8internal13FunctorTraitsIMN7content13URLLoaderImplEFvvEvE6InvokeIPS3_JEEEvS5_OT_DpOT0_ #55 0x7f0cb55dbae1 _ZN4base8internal12InvokeHelperILb0EiE8MakeItSoIRKMN7content15BrowserMainLoopEFivEJPS5_EEEiOT_DpOT0_ #56 0x7f0cb55dba87 _ZN4base8internal7InvokerINS0_9BindStateIMN7content15BrowserMainLoopEFivEJNS0_17UnretainedWrapperIS4_EEEEEFivEE7RunImplIRKS6_RKSt5tupleIJS8_EEJLm0EEEEiOT_OT0_NS_13IndexSequenceIJXspT1_EEEE #57 0x7f0cb55db9cc _ZN4base8internal7InvokerINS0_9BindStateIMN7content15BrowserMainLoopEFivEJNS0_17UnretainedWrapperIS4_EEEEEFivEE3RunEPNS0_13BindStateBaseE #58 0x7f0cb48cb4bd _ZNKR4base8CallbackIFvvELNS_8internal8CopyModeE1ELNS2_10RepeatModeE1EE3RunEv #59 0x7f0cb60e53cb content::StartupTaskRunner::RunAllTasksNow() #60 0x7f0cb55d0530 content::BrowserMainLoop::CreateStartupTasks() #61 0x7f0cb55ded17 content::BrowserMainRunnerImpl::Initialize() r8: 00007f0ca28149d0 r9: 00007fff97b1ff98 r10: 0000000000000008 r11: 0000000000000202 r12: 0000000000000002 r13: 00007fff97b28ea0 r14: 0000000000000000 r15: 0000000000000000 di: 000000000000266d si: 000000000000266d bp: 00007fff97b20278 bx: 00007fff97b201f8 dx: 0000000000000006 ax: 0000000000000000 cx: ffffffffffffffff sp: 00007fff97b1ffe8 ip: 00007f0ca248ac37 efl: 0000000000000202 cgf: 0000000000000033 erf: 0000000000000000 trp: 0000000000000000 msk: 0000000000000000 cr2: 0000000000000000 [end of stack trace] . |