Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-52315

Crash in QFreeList with ICC

    XMLWordPrintable

Details

    • Bug
    • Resolution: Incomplete
    • P2: Important
    • None
    • 5.6.0, 5.7.0 Alpha
    • Core: Other
    • Intel C++ Compiler 2016 Update2 & Intel Compiler 17.0 Pre-Release (Beta) integrated with VS 2015 Update 1 on Windows 10 x64 10.0.10586

    Description

      I am a user of Intel Parallel Studio XE for C++ Windows. I have been trying to compile Qt 5.6 and 5.7 in Intel64 mode (using the console environment provided by "ipsxe-comp-vars.bat intel64 vs2015" and have not run into any difficulties, both on ICC 16.0 Update 2 and ICC 17.0 Beta. I'm building for debug and release, static. However, it seems that are still some problems with how ICC deals with constexpr functions

      configure.bat
       -platform win32-icc
      -c++std c++11
      -optimized-tools
      -debug-and-release
      -static
      -static-runtime
      -mp
      -no-ltcg
      -avx
      -no-avx2
      -no-avx512
      -prefix C:\dev\qtdev\
      -opengl desktop
      -no-icu
      -no-openssl
      -nomake tests
      -nomake examples
      -no-compile-examples
      -qt-zlib
      -skip qtconnectivity
      -skip qtsensors
      -skip qtwebsockets
      -skip qtwebchannel
      -skip qtwebengine
      -skip qtserialbus
      -skip qtwayland
      -skip qtxmlpatterns
      -no-qml-debug
       -skip qtactiveqt
      -skip qtenginio
      -skip qtlocation
      -skip qtquickcontrols
      -skip qtquickcontrols2
      -skip qtscript
      -skip qtdeclarative
      -skip qtxmlpatterns
      -skip qtserialbus
      

      The MainWindow always crashes:

        asd4.exe!QtPrivate::QFunctorSlotObject<class __10<lambda0>,UNKNOWN,double,UNKNOWN,UNKNOWN,read_qthread_cpp_c15e2b56,0,struct QtPrivate::List<>,void>::`vector deleting destructor'(unsigned int) C++
      >>> asd4.exe!QFreeList<void, QtTimerIdFreeListConstants>::allocate(int offset, int size) Line 171 C++
        asd4.exe!QFreeList<void, QtTimerIdFreeListConstants>::next() Line 246 C++
        asd4.exe!QAbstractEventDispatcherPrivate::allocateTimerId() Line 93 C++
        asd4.exe!QAbstractEventDispatcher::registerTimer(int interval, Qt::TimerType timerType, QObject * object) Line 258 C++
        asd4.exe!QObject::startTimer(int interval, Qt::TimerType timerType) Line 1646 C++
        asd4.exe!QPMCache::insert(const QString & key, const QPixmap & pixmap, int cost) Line 342 C++
        asd4.exe!QPixmapCache::insert(const QString & key, const QPixmap & pixmap) Line 565 C++
        asd4.exe!cachedPixmapFromXPM(QPixmap *, const char * * xpm) Line 5235 C++
        asd4.exe!QCommonStyle::standardPixmap(QPixmap *, QStyle::StandardPixmap sp, const QStyleOption * option, const QWidget * widget) Line 5455 C++
        asd4.exe!QWindowsStyle::standardPixmap(QPixmap *, QStyle::StandardPixmap standardPixmap, const QStyleOption * opt, const QWidget * widget) Line 522 C++
        asd4.exe!QWindowsXPStyle::standardPixmap(QPixmap *, QStyle::StandardPixmap standardPixmap, const QStyleOption * option, const QWidget * widget) Line 3890 C++
        asd4.exe!QWindowsVistaStyle::standardPixmap(QPixmap *, QStyle::StandardPixmap standardPixmap, const QStyleOption * option, const QWidget * widget) Line 2424 C++
        asd4.exe!QCommonStyle::standardIcon(QIcon *, QStyle::StandardPixmap standardIcon, const QStyleOption * option, const QWidget * widget) Line 6117 C++
        asd4.exe!QWindowsStyle::standardIcon(QIcon *, QStyle::StandardPixmap standardIcon, const QStyleOption * option, const QWidget * widget) Line 2399 C++
        asd4.exe!QWindowsXPStyle::standardIcon(QIcon *, QStyle::StandardPixmap standardIcon, const QStyleOption * option, const QWidget * widget) Line 4016 C++
        asd4.exe!QWindowsVistaStyle::standardIcon(QIcon *, QStyle::StandardPixmap standardIcon, const QStyleOption * option, const QWidget * widget) Line 2550 C++
        asd4.exe!QMenuBarExtension::QMenuBarExtension(QWidget * parent) Line 90 C++
        asd4.exe!QMenuBarPrivate::init() Line 719 C++
        asd4.exe!QMenuBar::QMenuBar(QWidget * parent) Line 752 C++
        asd4.exe!Ui_asd4Class::setupUi(QMainWindow * asd4Class) Line 38 C++
        asd4.exe!asd4::asd4(QWidget * parent) Line 6 C++
        asd4.exe!main(int argc, char * * argv) Line 11 C++
      
      // Breakpoint:
      // allocate a block of the given \a size, initialized starting with the given \a offset
          static inline ElementType *allocate(int offset, int size)
          {
              // qDebug("QFreeList: allocating %d elements (%ld bytes) with offset %d", size, size * sizeof(ElementType), offset);
       >>>    ElementType *v = new ElementType[size];
              for (int i = 0; i < size; ++i)
                  v[i].next.store(offset + i + 1);
              return v;
          }
      

      Is this a ICC 16.0 U2 and 17.0 BETA bug and can this be fixed through editing qcompilerdetection.h?
      http://stackoverflow.com/questions/35764069/static-assert-and-intel-c-compiler
      https://software.intel.com/en-us/forums/intel-c-compiler/topic/610395

      Attachments

        1. QtWidgetsExample.zip
          7 kB
        2. compile.log
          10 kB
        3. stack.txt
          3 kB
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            thiago Thiago Macieira
            fboni Francisco Boni Neto
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes