Use qregister(u)int in qsimd.cpp x86 code

This way, the same codebase works for x86, x86-64 LP64 and x86-64 ILP32
(a.k.a. x32).

Task-number: QTBUG-35463
Change-Id: Iffcecc6a4c03267fb64e287c2d6226d078d7d115
Reviewed-by: hjk <hjk121@nokiamail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Update the macro that MSVC 2013 defines for AVX code generation

http://msdn.microsoft.com/en-us/library/b0084kay(v=vs.120).aspx says:
  __AVX__       Defined when /arch:AVX is specified.

Now we know what flag it is, we don't need to use our _M_AVX flag
anymore. We're also now assuming that Microsoft will follow the same
pattern for AVX2 (i.e., __AVX2__), so this commit also removes the
check for _M_AVX2.

The other defines that were defined alongside AVX2 are removed because
they have no use currently in Qt.

Change-Id: I64a026b2206dbd0d2dffa7c803bee969c9b94a94
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Fix configure & qmake compilation with a future MSVC version

When MSVC supports ref-qualified members, we need to ensure that
qstring_compat.cpp can see the non-qualified definitions in qstring.h,
which means no precompiled header.

Alternatively, for a bootstrapped build we could not compile
qstring_compat.cpp or #ifndef the functions.

Change-Id: I8ece34503060f0b4b0f8f2df2fb9b0fb1311e269
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Add other integer overloads to QFlag's constructor

This avoids "change of sign" warnings as found by ICC when the high
bit is set. This often happens when you do
    X & ~Y

as ~Y probably has bit 31 on. If the enum is unsigned, then there's a sign conversion.

Change-Id: Ia5f221d928ac0155f4504a70c4046e60c25fbf3b
Reviewed-by: Kurt Pattyn <pattyn.kurt@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Fix setWindowFlags() for QMdiSubWindow.

It was impossible to hide/show the close button after a QMdiSubWindow
was created.

Task-number: QTBUG-9933
Task-number: QTBUG-27274

[ChangeLog][QtWidgets][QMdiSubWindow] Fixed setWindowFlags() for QMdiSubWindow.

Change-Id: I7db9a1bef5ba8a8ace729acb85682c8b3de9c33c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
QGraphicsSceneIndex: replace polymorphism with a function pointer

QGraphicsSceneIndexIntersector was used as a kind of polymorpic predicate in
items_helper(). But it had only one function and the instances of it, which
were kept around in QGraphicsSceneIndexPrivate, were re-initialised on every
call to items_helper(), which means that one can just as well pass that
miniscule amount of data to the function itself.

Replaced the polymorphism with a function pointer and the comparison state
(which is conceptually const if it wasn't for the requirement to assign
to it all the time) with a const void * argument.

Effects on Linux AMD64 GCC 4.9-trunk release stripped:
  text:   -1584B
  data:    -376B
  relocs:   -26

I've wrapped the functions in a namespace. The only reason for this is
to keep the functions, previously defined in class bodies, at the same
indentation level so as not to destroy the git-blame history for them.

Change-Id: I8e1f48030047a3c54e881de7c77a3325b3e1f509
Reviewed-by: Alexis Menard <alexis@webkit.org>
Reviewed-by: Andreas Aardal Hanssen <andreas@hanssen.name>