In master debug builds on OSX 10.10.2, seeing the unittest sw_globalfilter crash for a failed assertion : Assertion failed: (nMapNum == 0 || std::abs(n) < std::numeric_limits<long>::max() / nMapNum / nDPI), function ImplLogicToPixel, file /Volumes/BUILDHD/Shared/LO/core/vcl/source/outdev/map.cxx, line 379. Enclosing a bt - tried investigating a few frames, but not understanding what the code is trying to do, didn't get me very far.
Created attachment 114675 [details] full bt, a few frames analysed
Stephan: noticing http://cgit.freedesktop.org/libreoffice/core/commit/?id=be5a6706b6a34a57774714929b9b7fe06f69173e, thought you might be interested in this one. (putting at NEW since there's a bt + increase importance since crash+regression)
So at the end of lcl_CalcBorderRect (sw/source/core/layout/paintfrm.cxx; frame 7) rRect must contain the values that are reported for rLogicRect in frame 5: nLeft = 9223372036854755805 nTop = 9223372036854755807 nRight = 9223372036854755808 nBottom = 9223372036854755808 resp. nLeft = 0x7FFF'FFFF'FFFF'B1DD nTop = 0x7FFF'FFFF'FFFF'B1DF nRight = 0x7FFF'FFFF'FFFF'B1E0 nBottom = 0x7FFF'FFFF'FFFF'B1E0 which smells like mis-calculations using the FAR_AWAY (sw/source/core/inc/frmtool.hxx) value LONG_MAX - 20000 = 9223372036854755807 = 0x7FFF'FFFF'FFFF'B1DF.
Is this specific to OS X or something that can be reproduced on Linux, too? Without being able to reproduce, the big picture is: for e.g. page frames, there is an "is invalid" flag that's true by default and set to false by the layout when its size and position is correct. I guess there is a similar flag for fly frames as well: before that FAR_AWAY should not be taken literally. Possibly that's what happens here, seeing the values which are close to, but do not equal to FAR_AWAY.
Seems specific to OSX - also confirmed by mjayfrancis on his OSX setup
Assertion failed: (nMapNum == 0 || std::abs(n) < std::numeric_limits<long>::max() / nMapNum / nDPI), function ImplLogicToPixel, file /Volumes/BUILDHD/Shared/LO/core/vcl/source/outdev/map.cxx, line 379. So, if I understand correctly, the line of code above is using LONG MAX ?
Just for the record, I could also reproduce this on MacOs build (with debug option) and not on Linux.
Caolan/Chris: thought you might be interested in this one since bt shows vcl part.
It makes no difference whether I build with debug enabled or disabled, the build fails systematically with this unit test. This has completely broken building on master for me. I completely clean the build tree each time before pulling, forcing removal with 'sudo rm -Rf' of any instdir, workdir, and test-install folders. Changed title to reflect findings.
No crash here. Maybe a High-DPI issue?
(In reply to David Tardon from comment #11) > No crash here. Maybe a High-DPI issue? My monitor is a LG Flatron W1946 18,4-inch (1360 x 768) GPU : NVIDIA GeForce 320M 256 Mo so it isn't hi-DPI capable and shouldn't be using code paths geared to such hiDPI support ?
Now seeing this : (lldb) run Process 80430 launched: '/Volumes/BUILDHD/Shared/LO/core/workdir/LinkTarget/Executable/cppunittester' (x86_64) /Volumes/BUILDHD/Shared/LO/core/unotest/source/cpp/macros_test.cxx:52:Test::testSkipImages assertion failed - Expression: xComponent.is() - loading failed: file:///Volumes/BUILDHD/Shared/LO/core//sw/qa/extras/globalfilter/data/skipimages.docx unknown:0:Test::testSkipImages tearDown() failed - An uncaught exception of type com.sun.star.lang.DisposedException - /Volumes/BUILDHD/Shared/LO/core/unotest/source/cpp/macros_test.cxx:52: Assertion Test name: Test::testSkipImages assertion failed - Expression: xComponent.is() - loading failed: file:///Volumes/BUILDHD/Shared/LO/core//sw/qa/extras/globalfilter/data/skipimages.docx ##Failure Location unknown## : Error Test name: Test::testSkipImages tearDown() failed - An uncaught exception of type com.sun.star.lang.DisposedException - Failures !!! Run: 8 Failure total: 2 Failures: 1 Errors: 1 2015-04-22 16:25:08.529 cppunittester[80430:1566208] *** -[NSAutoreleasePool release]: This pool has already been released, do not drain it (double release). Process 80430 exited with status = 1 (0x00000001) There is no stack to trace in this via lldb, but the line of code indicated as failing is : CPPUNIT_ASSERT_MESSAGE(OUStringToOString( sMessage, RTL_TEXTENCODING_UTF8 ).getStr( ), xComponent.is());
I've got the same bt on Mac too with master sources updated today (+ enable-dbgutil + "make clean" before building): frame #4: 0x000000010683ffde libvcllo.dylib`ImplLogicToPixel(n=9223372036854755805, nDPI=103, nMapNum=1, nMapDenom=1440, nThres=44773650664343568) + 302 at map.cxx:381 frame #5: 0x0000000106843da8 libvcllo.dylib`OutputDevice::LogicToPixel(this=0x000000013009e860, rLogicRect=0x00007fff5fbecfb8) const + 184 at map.cxx:997 frame #6: 0x000000010d4a3267 libswlo.dylib`SwAlignRect(rRect=0x00007fff5fbed538, pSh=0x000000013328cb40) + 231 at paintfrm.cxx:1254 frame #7: 0x000000010d4be5cd libswlo.dylib`lcl_CalcBorderRect(rRect=0x00007fff5fbed538, pFrm=0x0000000133218170, rAttrs=0x000000011a913f18, bShadow=false, properties=0x000000010e7b1620) + 3005 at paintfrm.cxx:1512 frame #8: 0x000000010d4b9b78 libswlo.dylib`SwFrm::GetBackgroundBrush(this=0x0000000133218170, rFillAttributes=0x00007fff5fbed528, rpBrush=0x00007fff5fbed560, rpCol=0x00007fff5fbed558, rOrigRect=0x00007fff5fbed538, bLowerMode=false) const + 1736 at paintfrm.cxx:7595 frame #9: 0x000000010d4b919e libswlo.dylib`SwFlyFrm::IsBackgroundTransparent(this=0x0000000133218170) const + 238 at paintfrm.cxx:3972 frame #10: 0x000000010d4ccae5 libswlo.dylib`lcl_RefreshLine(pLay=0x0000000133289be0, pPage=0x000000011a912000, rP1=0x00007fff5fbeda98, rP2=0x00007fff5fbeda68, nSubColor='\x10', pSubsLines=0x0000000130b3e160) + 1221 at paintfrm.cxx:6857 frame #11: 0x000000010d4cc08f libswlo.dylib`SwLayoutFrm::PaintSubsidiaryLines(this=0x0000000133289be0, pPage=0x000000011a912000, rRect=0x00007fff5fbee0f0) const + 1391 at paintfrm.cxx:7174 frame #12: 0x000000010d4bd36d libswlo.dylib`SwLayoutFrm::RefreshLaySubsidiary(this=0x0000000133289be0, pPage=0x000000011a912000, rRect=0x00007fff5fbee0f0) const + 205 at paintfrm.cxx:6749 frame #13: 0x000000010d4bb58a libswlo.dylib`SwFlyFrm::Paint(this=0x0000000133289be0, rRect=0x0000000133289c40, (null)=0x0000000000000000) const + 5018 at paintfrm.cxx:4332 iMac (21.5 inches, mid-2011) Processor: 2,5 GHz Intel Core i5 AMD Radeon HD 6750M 512 Mo
I tried to follow FAR_AWAY/flag lead (proposed by Miklos and Stephan) but I must recognize I got lost :-( Michael: noticing your commit http://cgit.freedesktop.org/libreoffice/core/commit/?id=21be3257d9d10f0f65c2ae49d7ef3beb81018bfc fixed the same assertion, thought you might have some idea for this one. All: If you don't have a Mac, don't hesitate to attach a test patch, I can give it a try and report if the assertion is still there or not.
I just changed the title to retrieve it more quickly.
Is this still a problem or is it fixed, I ask because the bt in bug 92573 is similar to this one
(In reply to Caolán McNamara from comment #17) > Is this still a problem or is it fixed, I ask because the bt in bug 92573 is > similar to this one I've just git updated and it's building right now. However, I can say that with sources updated the 8th of July, it was still crashing with same messages.
Badfully, it still fails with same message.
I don't reproduce this with master sources updated today. I'm quite sure it's thanks to http://cgit.freedesktop.org/libreoffice/core/commit/?id=c837bfda8c646fe2f7ff789032dd9a6ee6fd396f. Alex, could you give it a new try?
Yep, no longer seems to fail anymore? Closing
Migrating Whiteboard tags to Keywords: (notBibisectable) [NinjaEdit]