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

QT_HASH_SEED does not ensure test stability accross different platforms/compilers/machines due to SSE4.2 support

    XMLWordPrintable

Details

    • 4ba740b3bac6e1824c18614f579d106eee930d42

    Description

      qHash() implementations for string-like types (QString, QByteArray...) has two different implementations depending on whether the compiler and CPU support SSE 4.2. Each implementation provides different results for the same input, which makes it impossible to ensure unit-tests stability across different machines (developer workstation and CI for example).

      qhash.cpp:hasFastCrc32() should either return false if QT_HASH_SEED is set or it should be at least documented that QT_NO_CPU_FEATURE=sse4.2 must be set to ensure identical behaviour across different platforms/compilers/CPUs.

      Attachments

        Issue Links

          For Gerrit Dashboard: QTBUG-47566
          # Subject Branch Project Status CR V

          Activity

            People

              thiago Thiago Macieira
              dvratil Daniel Vrátil
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews