1 2 3 Previous Next 31 Replies Latest reply: Sep 20, 2014 8:46 AM by user522630 Go to original post RSS
      • 15. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
        user522630

        Hi Fedor,

         

        I have just used the current Boost (trunk) repository and a new assertion error occurs. Here is the link for the text file containing the assertion error: https://dl.dropboxusercontent.com/u/6899028/assertionError2.txt. Do note that -std=c++11 is not used here, although I will try to re-compile Boost with C++11 soon.

         

        P.S. The compilation of Boost (trunk) repository fails when -std=c++11 is used, due to the use of <complex> and <bitset>.

         

        Regards,

        Brian

        • 16. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
          user522630

          Hi Steve,

           

          I am now using the 12.4 Beta July Refresh. When compiling Firefox 24.5 ESR on the file mfbt/decimal/Decimal.cpp, a new assertion error occurs when compiled using -std=c++11, which was previously not caught in the 12.4 Beta Mar Refresh:

           

          >> Assertion:   (../lnk/stmtbind.cc, line 341)

               while processing /export/home/cpe479/mozilla-esr24/mfbt/decimal/moz-decimal-utils.h at line 80.

           

          However, the reduced version of the code segment for moz-decimal-utils.h compiled using -std=c++11 did not result in any Assertion Errors, so my guess is that the Assertion Error might be caused by Mozilla's implementation. The link for the code is at http://pastebin.mozilla.org/5520170.

           

          Also, I am unable to reproduce the code used in Boost trunk repository that caused the Assertion Error below (the Boost trunk was compiled using the 12.4 Beta Mar Refresh before the July Release, without using the -std=c++11 flag) :

           

          >> Assertion: (../lnk/structtype.cc, line 274)

            while processing ./boost/date_time/gregorian/greg_duration.hpp at line 27.

           

          Could anyone help to shed some light on these 2 Assertion Error issues? Also, does Solaris Studio 12.4 have compiler flags that can temporarily disable assertions?

           

          Thanks.

           

          Regards,

          Brian

          • 17. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
            Fedor-Oracle

            > Assertion:   (../lnk/stmtbind.cc, line 341)

            We have a bug filed on it, which has not yet been fixed:

                19005756 c++11 -noex: assertion in stmtbind.cc on temporary objects destruction handling

            To workaround this failure you can try disabling inlining  (+d).

             

            > Assertion: (../lnk/structtype.cc, line 274)

            This looks like a bug fixed couple months ago (so the fix should be present in July Beta):

              18601652 -std=c++03, -std=c++11 Assertion: (../lnk/structtype.cc, line 272 )

             

            > does Solaris Studio 12.4 have compiler flags that can temporarily disable assertions?

             

            Sorry, it is not possible.

            The main purpose of these assertions is to ensure consistent state of the compiler through the compilation.

            It makes no sense to continue after the assertion is violated because it means compiler is screwed up seriously.

            And failing compilation is much much better than compiling silently into bad code.

             

            regards,

              Fedor.

            • 18. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
              user522630

              Hi Fedor,

               

              When compiling Firefox 30.0 with -std=c++11 on file memory/mozalloc/VolatileBufferFallback.cpp with slight modifications on the file mfbt/Atomics.h from:

               

              #if defined(__clang__) || defined(__GNUC__)

               

              to:

               

              #if defined(__clang__) || defined(__GNUC__) || defined(SOLARIS)

               

              it crashes with a new Assertion error (other errors are present but not included due to <atomics> not yet supported in C++11):

               

              >> Assertion:   (../lnk/ppexpr.cc, line 479)

                  while processing ../../dist/include/mozilla/RefPtr.h at line 17.

               

              For now, I will try to compile without C++11 and see whether this problem goes away.

               

              Regards,

              Brian

              • 19. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
                Fedor-Oracle

                Ugh.. cant ever remember seeing assertions from preprocessor.

                If you can provide a reduced testcase that would be great.

                 

                Though it might happen to be a memory corruption (which makes it even more important to catch but also more difficult to reproduce).

                 

                regards,

                  Fedor.

                • 20. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
                  user522630

                  Hi Fedor,

                   

                  Another new assertion error, but only happens when compiled with -features=no%except on latest Boost (trunk):

                   

                  sun.compile.c++ bin.v2/libs/thread/build/sun/release/address-model-32/instruction-set-native/link-static/stdlib-sun-stlport/threading-multi/pthread/thread.o

                  "./boost/system/system_error.hpp", line 65: Warning: try and catch ignored when compiling with -noex.

                  "./boost/thread/pthread/thread_data.hpp", line 178: Warning: throw expression ignored when compiling with -noex.

                  "./boost/exception/diagnostic_information.hpp", line 90: Warning: try and catch ignored when compiling with -noex.

                  "./boost/exception/diagnostic_information.hpp", line 179: Warning: try and catch ignored when compiling with -noex.

                  "./boost/exception/detail/exception_ptr.hpp", line 333: Warning: try and catch ignored when compiling with -noex.

                  "./boost/exception/detail/exception_ptr.hpp", line 335: Warning: throw expression ignored when compiling with -noex.

                  "./boost/exception/detail/exception_ptr.hpp", line 439: Warning: try and catch ignored when compiling with -noex.

                  "./boost/exception/detail/exception_ptr.hpp", line 478: Warning: try and catch ignored when compiling with -noex.

                  "./boost/thread/future.hpp", line 351: Warning: throw expression ignored when compiling with -noex.

                  "./boost/thread/future.hpp", line 3114: Warning: try and catch ignored when compiling with -noex.

                  "./boost/thread/future.hpp", line 3141: Warning: try and catch ignored when compiling with -noex.

                  "./boost/throw_exception.hpp", line 69: Warning: throw expression ignored when compiling with -noex.

                  "./boost/thread/pthread/mutex.hpp", line 128:     Where: While instantiating "boost::throw_exception<boost::lock_error>(const boost::lock_error&)".

                  "./boost/thread/pthread/mutex.hpp", line 128:     Where: Instantiated from non-template code.

                  >> Assertion:   (../lnk/vardescr.h, line 109)

                      while processing libs/thread/src/pthread/thread.cpp at line 60.

                   

                      "/opt/SolarisStudio12.4-beta_jul14-solaris-x86/bin/CC" -library=stlport4 -features=tmplife -features=tmplrefstatic -features=extensions -features=no%except -norunpath -template=no%extdef -xannotate=no -xO4 -xO4 -mt -erroff=%none -m32 -DBOOST_ALL_NO_LIB=1 -DBOOST_ATOMIC_STATIC_LINK=1 -DBOOST_SYSTEM_STATIC_LINK=1 -DBOOST_THREAD_BUILD_LIB=1 -DBOOST_THREAD_DONT_USE_CHRONO -DBOOST_THREAD_POSIX -DNDEBUG -I"." -c -o "bin.v2/libs/thread/build/sun/release/address-model-32/instruction-set-native/link-static/stdlib-sun-stlport/threading-multi/pthread/thread.o" "libs/thread/src/pthread/thread.cpp"

                   

                  ...failed sun.compile.c++ bin.v2/libs/thread/build/sun/release/address-model-32/instruction-set-native/link-static/stdlib-sun-stlport/threading-multi/pthread/thread.o...

                  ...failed updating 1 target...

                  ...updated 25 targets...

                   

                  Regards,

                  Brian

                  • 21. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
                    user522630

                    Hi Steve and Fedor,

                     

                    For the assertion test case examples, is it OK if I re-produce the code samples that has assertion enabled (i.e. inclusion of assert.h, defining its own assert variables and performing the manual assert to trigger the compile-time assertion errors)? Kindly advise. Thanks.

                     

                    Regards,

                    Brian

                    • 22. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
                      Fedor-Oracle

                      Compiler assertions have nothing to do with user-code asserts.

                       

                      Compiler asserts when its internal assumptions about program state are invalidated.

                      The only way to reproduce the failure is to create a self-contained testcase that consists

                      a particular C++ language that confuses the compiler.

                      • 23. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
                        Fedor-Oracle

                        I can reproduce vardescr.h 109 assert on July Beta but not on current development compiler.

                        You can use +d (disable frontend inlining) to work around this failure.

                         

                        regards,

                          Fedor.

                        • 24. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
                          user522630

                          Hi Fedor,

                           

                          Another assertion error, which was already posted in a previous post (Assertion:   (../lnk/classutils.cc, line 299) - CC: Sun C++ 5.13 Beta2 2014/06/17), when compiling BOOST 1.55 with -std=c++11:

                           

                          Error: Template parameter T may not be used as a part of an expression.

                          Error: Template parameter T may not be used as a part of an expression.

                          >> Assertion:   (../lnk/tempparse.cc, line 818)

                              while processing ./boost/utility/detail/result_of_iterate.hpp at line 149.

                           

                              "/opt/SolarisStudio12.4-beta_jul14-solaris-x86/bin/CC" -std=c++11 -features=tmplife -features=tmplrefstatic -features=extensions -norunpath -xannotate=no +d -Qoption iropt -Rloop_reform -xO4 -mt -erroff=%none -m32 -KPIC -DBOOST_ALL_NO_LIB=1 -DBOOST_ATOMIC_DYN_LINK=1 -DBOOST_SYSTEM_DYN_LINK=1 -DBOOST_THREAD_BUILD_DLL=1 -DBOOST_THREAD_DONT_USE_CHRONO -DBOOST_THREAD_POSIX -DNDEBUG -I"." -c -o "bin.v2/libs/thread/build/sun/release/address-model-32/instruction-set-native/stdlib-sun-stlport/threading-multi/pthread/thread.o" "libs/thread/src/pthread/thread.cpp"

                           

                          If -std=c++11 is omitted, the compilation goes through without any problems.

                           

                          Regards,

                          Brian

                          • 25. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
                            Fedor-Oracle

                            I can not reproduce this failure.

                            On Beta2 build for me it fails this way:

                            "SolarisStudio12.4-beta_jul14-solaris-x86/lib/compilers/include/CC/gnu/bits/stl_pair.h", line 289: Error: Using deleted function 'std::pair<const void*, boost::detail::tss_data_node>::pair(std::pair<const void*, boost::detail::tss_data_node>&&)'.

                            "boost_1_55_0/libs/thread/src/pthread/thread.cpp", line 706:     Where: While instantiating "std::make_pair<const void*&, boost::detail::tss_data_node>(const void*&, boost::detail::tss_data_node&&)".

                            "boost/boost/boost_1_55_0/libs/thread/src/pthread/thread.cpp", line 706:     Where: Instantiated from non-template code.

                            1 Error(s) detected.

                             

                            And on current development compiler is just passes compilation.

                             

                            What platform are you running it on?

                             

                            regards,

                              Fedor.

                            • 26. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
                              user522630

                              Hi Fedor,

                               

                              I am currently running on Solaris 11.2. I got this error before when compiling BOOST 1.55 in -std=c++11:

                               

                              "SolarisStudio12.4-beta_jul14-solaris-x86/lib/compilers/include/CC/gnu/bits/stl_pair.h", line 289: Error: Using deleted function 'std::pair<const void*, boost::detail::tss_data_node>::pair(std::pair<const void*, boost::detail::tss_data_node>&&)'.

                              "boost_1_55_0/libs/thread/src/pthread/thread.cpp", line 706:     Where: While instantiating "std::make_pair<const void*&, boost::detail::tss_data_node>(const void*&, boost::detail::tss_data_node&&)".

                              "boost/boost/boost_1_55_0/libs/thread/src/pthread/thread.cpp", line 706:     Where: Instantiated from non-template code.

                               

                              After applying the corrections as described by Steve in Assertion failure from ccfe in Solaris Studio 12.4 beta July refresh, the error no longer appears. Instead the tempparse assertion error results.

                               

                              Regards,

                              Brian

                              • 27. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
                                user522630

                                Hi Steve and Fedor,

                                 

                                Currently, are there bug reports filed against 2 assertion errors? Kindly advise. Thanks.

                                 

                                >> Assertion:   (../lnk/tempparse.cc, line 818)

                                    while processing ./boost/utility/detail/result_of_iterate.hpp at line 149.

                                >> Assertion:   (../lnk/funcsym.cc, line 1679)

                                    while processing text_woarchive.pre.cpp at line 0

                                 

                                Regards,

                                Brian

                                • 28. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
                                  Fedor-Oracle

                                  The latter problem has CR filed:

                                    18835390 Boost-1.55 interprocess/test/bufferstream_test Assertion:../lnk/funcsym.cc

                                  It has recently been fixed.

                                   

                                  regards,

                                    Fedor.

                                  • 29. Re: Assertions in 12.4 beta (How do we report crashes for 12.4 beta?)
                                    user522630

                                    Hi Steve & Fedor,

                                     

                                    I am trying to see whether I can reproduce a code segment for this new Assertion Error when compiling Qt 4.8.6 below using July Refresh, though it may be hard to do so:

                                     

                                    CC -c -xlibmil -xlibmopt -D_XOPEN_SOURCE=500 -D__EXTENSIONS__ -xlibmieee -xbuiltin=%all -features=tmplife,tmplrefstatic,extensions -norunpath -D__FUNCTION__=__func__ -template=no%extdef -xannotate=no -mt +d -DNDEBUG -DTRIMMED -xO4 -Qoption iropt -Rloop_reform -O2 -mt -xldscope=hidden -KPIC -DQDESIGNER_SDK_LIBRARY -DQDESIGNER_EXTENSION_LIBRARY -DQDESIGNER_UILIB_LIBRARY -DQDESIGNER_SHARED_LIBRARY -DQT_DESIGNER -DQT_FORMBUILDER_NO_SCRIPT -DQT_NO_DEBUG -DQT_XML_LIB -DQT_GUI_LIB -DQT_CORE_LIB -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -DQT_SHARED -I../../../../mkspecs/solaris-cc -I. -I../../../../include/QtCore -I../../../../include/QtGui -I../../../../include/QtXml -I../../../../include -Iextension -Isdk -Iuilib -Ishared -I../../../shared/qtpropertybrowser -I../../../shared/deviceskin -I../../../../src/tools/rcc -I../../../shared/findwidget -I../../../shared/qtgradienteditor -I.moc/release-shared -I.uic/release-shared -I/usr/sfw/include -o .obj/release-shared/abstractformwindowmanager.o sdk/abstractformwindowmanager.cpp

                                    "../../../../include/QtCore/../../src/corelib/tools/qstring.h", line 351: Warning: function int(const QString&,const QString&) overloads int(const QString&)const because of different language linkages.

                                    "../../../../include/QtCore/../../src/corelib/tools/qstring.h", line 353: Warning: function int(const QString&,const QString&,Qt::CaseSensitivity) overloads int(const QString&,Qt::CaseSensitivity)const because of different language linkages.

                                    "../../../../include/QtCore/../../src/corelib/tools/qstring.h", line 357: Warning: function int(const QString&,const QLatin1String&,Qt::CaseSensitivity) overloads int(const QLatin1String&,Qt::CaseSensitivity)const because of different language linkages.

                                    "../../../../include/QtCore/../../src/corelib/tools/qstring.h", line 368: Warning: function int(const QString&,const QString&) overloads int(const QString&)const because of different language linkages.

                                    >> Assertion:   (../lnk/bind2.cc, line 2371)

                                        while processing sdk/abstractformwindowmanager.cpp at line 146.


                                    Regards,

                                    Brian