Issue metadata
Sign in to add a comment
|
Valgrind reports a memory leak in GCCallbackTest.ContextInvalidatedBeforeGC (extensions_unittests) |
||||||||||||||||||||||
Issue description
$ tools/valgrind/chrome_tests.sh -t extensions -b out/Release --gtest_filter=GCCallbackTest.ContextInvalidatedBeforeGC
[ RUN ] GCCallbackTest.ContextInvalidatedBeforeGC
...
[ OK ] GCCallbackTest.ContextInvalidatedBeforeGC (11861 ms)
[----------] 1 test from GCCallbackTest (11890 ms total)
[----------] Global test environment tear-down
[==========] 1 test from 1 test case ran. (11933 ms total)
[ PASSED ] 1 test.
16:21:51 common.py [INFO] process ended, did not time out
16:21:51 common.py [INFO] flushing stdout
16:21:51 common.py [INFO] collecting result code
-----------------------------------------------------
Suppressions used:
count name
1 bug_562431_b
1 bug_562718b
1 bug_562718c
2 glibc-2.5.x-on-SUSE-10.2-(PPC)-2a
337 bug_64887_a
2247 bug_340752
-----------------------------------------------------
16:21:51 memcheck_analyze.py [ERROR] FAIL! There were 1 errors:
16:21:51 memcheck_analyze.py [ERROR]
### BEGIN MEMORY TOOL REPORT (error hash=#69C5AC1B373C7EFE#)
Command: out/Release/extensions_unittests --gtest_print_time --single-process-tests --gtest_filter=GCCallbackTest.ContextInvalidatedBeforeGC --test-tiny-timeout=1000
Leak_DefinitelyLost
16 bytes in 1 blocks are definitely lost in loss record 261 of 929
malloc (m_replacemalloc/vg_replace_malloc.c:1138)
WTF::Partitions::fastMalloc(unsigned long, char const*) (third_party/WebKit/Source/wtf/PartitionAlloc.h:736)
blink::PersistentBase<blink::StyleFilterData, (blink::WeaknessPersistentConfiguration)0, (blink::CrossThreadnessPersistentConfiguration)0>::operator new(unsigned long) (/usr/local/google/src/chrome/src/out/Release/extensions_unittests)
blink::RefCountedGarbageCollected<blink::StyleFilterData>::makeKeepAlive() (third_party/WebKit/Source/platform/heap/GarbageCollected.h:363)
blink::RefCountedGarbageCollected<blink::StyleFilterData>::ref() (third_party/WebKit/Source/platform/heap/GarbageCollected.h:324)
blink::DataRef<blink::StyleFilterData>::init() (third_party/WebKit/Source/wtf/PassRefPtr.h:49)
blink::ComputedStyle::createInitialStyle() (third_party/WebKit/Source/core/style/ComputedStyle.cpp:137)
blink::ComputedStyle::mutableInitialStyle() (third_party/WebKit/Source/core/style/ComputedStyle.h:361)
blink::ComputedStyle::initialStyle() (/usr/local/google/src/chrome/src/out/Release/extensions_unittests)
blink::ComputedStyle::create() (third_party/WebKit/Source/core/style/ComputedStyle.cpp:109)
blink::StyleResolver::styleForDocument(blink::Document&) (third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp:679)
blink::Document::attach(blink::Node::AttachContext const&) (third_party/WebKit/Source/core/dom/Document.cpp:2207)
blink::LocalDOMWindow::installNewDocument(WTF::String const&, blink::DocumentInit const&, bool) (third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp:350)
blink::DocumentLoader::createWriterFor(blink::DocumentInit const&, WTF::AtomicString const&, WTF::AtomicString const&, bool, blink::ParserSynchronizationPolicy) (third_party/WebKit/Source/core/loader/DocumentLoader.cpp:668)
blink::DocumentLoader::ensureWriter(WTF::AtomicString const&, blink::KURL const&) (third_party/WebKit/Source/core/loader/DocumentLoader.cpp:449)
blink::DocumentLoader::commitData(char const*, unsigned long) (third_party/WebKit/Source/core/loader/DocumentLoader.cpp:464)
blink::DocumentLoader::finishedLoading(double) (third_party/WebKit/Source/core/loader/DocumentLoader.cpp:278)
blink::DocumentLoader::maybeLoadEmpty() (third_party/WebKit/Source/core/loader/DocumentLoader.cpp:610)
blink::DocumentLoader::startLoadingMainResource() (third_party/WebKit/Source/core/loader/DocumentLoader.cpp:621)
blink::FrameLoader::init() (third_party/WebKit/Source/core/loader/FrameLoader.cpp:200)
blink::LocalFrame::init() (third_party/WebKit/Source/core/frame/LocalFrame.h:241)
blink::WebLocalFrameImpl::initializeCoreFrame(blink::FrameHost*, blink::FrameOwner*, WTF::AtomicString const&, WTF::AtomicString const&) (third_party/WebKit/Source/web/WebLocalFrameImpl.cpp:1559)
blink::WebViewImpl::setMainFrame(blink::WebFrame*) (third_party/WebKit/Source/web/WebViewImpl.cpp:372)
extensions::ScopedWebFrame::ScopedWebFrame() (extensions/renderer/scoped_web_frame.cc:15)
extensions::(anonymous namespace)::GCCallbackTest::GCCallbackTest() (extensions/renderer/gc_callback_unittest.cc:33)
extensions::(anonymous namespace)::GCCallbackTest_ContextInvalidatedBeforeGC_Test::GCCallbackTest_ContextInvalidatedBeforeGC_Test() (extensions/renderer/gc_callback_unittest.cc:122)
testing::internal::TestFactoryImpl<extensions::(anonymous namespace)::GCCallbackTest_ContextInvalidatedBeforeGC_Test>::CreateTest() (/usr/local/google/src/chrome/src/out/Release/extensions_unittests)
Suppression (error hash=#69C5AC1B373C7EFE#):
For more info on using suppressions see http://dev.chromium.org/developers/tree-sheriffs/sheriff-details-chromium/memory-sheriff#TOC-Suppressing-memory-reports
{
<insert_a_suppression_name_here>
Memcheck:Leak
fun:malloc
fun:_ZN3WTF10Partitions10fastMallocEmPKc
fun:_ZN5blink14PersistentBaseINS_15StyleFilterDataELNS_31WeaknessPersistentConfigurationE0ELNS_38CrossThreadnessPersistentConfigurationE0EEnwEm
fun:_ZN5blink26RefCountedGarbageCollectedINS_15StyleFilterDataEE13makeKeepAliveEv
fun:_ZN5blink26RefCountedGarbageCollectedINS_15StyleFilterDataEE3refEv
fun:_ZN5blink7DataRefINS_15StyleFilterDataEE4initEv
fun:_ZN5blink13ComputedStyle18createInitialStyleEv
fun:_ZN5blink13ComputedStyle19mutableInitialStyleEv
fun:_ZN5blink13ComputedStyle12initialStyleEv
fun:_ZN5blink13ComputedStyle6createEv
fun:_ZN5blink13StyleResolver16styleForDocumentERNS_8DocumentE
fun:_ZN5blink8Document6attachERKNS_4Node13AttachContextE
fun:_ZN5blink14LocalDOMWindow18installNewDocumentERKN3WTF6StringERKNS_12DocumentInitEb
fun:_ZN5blink14DocumentLoader15createWriterForERKNS_12DocumentInitERKN3WTF12AtomicStringES7_bNS_27ParserSynchronizationPolicyE
fun:_ZN5blink14DocumentLoader12ensureWriterERKN3WTF12AtomicStringERKNS_4KURLE
fun:_ZN5blink14DocumentLoader10commitDataEPKcm
fun:_ZN5blink14DocumentLoader15finishedLoadingEd
fun:_ZN5blink14DocumentLoader14maybeLoadEmptyEv
fun:_ZN5blink14DocumentLoader24startLoadingMainResourceEv
fun:_ZN5blink11FrameLoader4initEv
fun:_ZN5blink10LocalFrame4initEv
fun:_ZN5blink17WebLocalFrameImpl19initializeCoreFrameEPNS_9FrameHostEPNS_10FrameOwnerERKN3WTF12AtomicStringES8_
}
### END MEMORY TOOL REPORT (error hash=#69C5AC1B373C7EFE#)
,
Apr 11 2016
Started at https://build.chromium.org/p/chromium.memory.fyi/builders/Linux Tests (valgrind)(2)/builds/54698/ with r384950 - suppression bug_562431_a stopped firing.
,
Apr 12 2016
Lei, are you sure this is the same as issue 562431?
,
Apr 13 2016
|
|||||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||||
Comment 1 by glider@chromium.org
, Apr 8 2016The leaking object is created in RefCountedGarbageCollected::makeKeepAlive(): m_keepAlive = new Persistent<T>(static_cast<T*>(this)); The test actually calls makeKeepAlive for two different objects, one of which leaks and the other does not. I'm now trying to understand what's the difference between those objects.