Remove runtime detection of SSE2

If the compiler supports SSE2, we'll use our SSE2-optimised code
unconditionally. Runtime detection is left for SSSE3 code.

The SSE2 codebase is big and thus a timebomb if an inline function
gets leaked out and run without runtime check. In reality, it's
extremely unlikely people running CPUs without SSE2 support are
running Qt 5 at this moment (they're either too old or too new,
e.g. Intel Quark).

The SSSE3 codebase is a lot more manageable.

Task-number: QTBUG-30440
Change-Id: I3e586e4434e820365d5316b650ee3061d0acf767
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Remove runtime detection of Neon on ARM CPUs

Now the only way to enable Neon support is to change the mkspec.

[ChangeLog][Important Behavior Changes] Qt no longer checks for
support for the Neon FPU on ARM platforms at runtime. Code optimized
for Neon must be enabled unconditionally at compile time by ensuring
the compiler supports Neon. You may need to edit your mkspec for that.

Task-number: QTBUG-30440
Change-Id: I4df9b2bf3cd022f8ed70f02f16878cb2cb3fe6fb
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Make qt_memfill{16,32} unconditional

These two functions used to cause a runtime detection of the CPU
features in order to improve their performance. Since the last two
commits, there's no runtime detection of either SSE2 or Neon support,
so there's no point in attempting runtime detection.

Task-number: QTBUG-30440
Change-Id: I54fe92787c983003c2cc867ee636daec30063033
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Automatically turn on SSE2 code generation throughout Qt

...unless the user passed the -no-sse2 option to the compiler.

[ChangeLog][Important Behavior Changes] Qt now automatically generates
code for processors supporting SSE2 on i386 platforms. To disable
this, pass the -no-sse2 option during Qt configuration. Since this
feature has been present on CPUs for 10 years and since Qt no longer
checks for runtime support for SSE2, we strongly encourage users to
leave the default setting on for best performance.
 - For Linux distributions that must retain support for CPUs without
   SSE2, we recommend doing two builds of Qt and installing the
   SSE2-enabled libraries in the LIBDIR/sse2 directory. Tools,
   plugins, and examples are not affected.
 - See discussion on the Qt development mailing list:
   http://lists.qt-project.org/pipermail/development/2013-November/014085.html

Change-Id: I7f9b1f58a9f66b6e5fe295bac15f87d34343695e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Ensure that the mkspec and source dirs are passed to moc on Windows

Those paths need not be in INCLUDEPATH: qmake always adds them to the
compiler command-line and we should match the behavior if we expand
INCLUDEPATH here.

Change-Id: I89508d15ac534b54ae873a42c4ad9764408042b5
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Optimize INV_PREMUL

Our inverse premultiply is rather unoptimized. It's major weakness is
using three divide operation which are the slowest integer operations.

This patch reduces the three divisions to just one but using an
approximation that is accurate for all uchar values.

The patch also adds a general short-cut for alpha==255.

Together these improvements makes it 2 to 16 times faster depending on
how many 0 and 255 alpha values are encountered.

Change-Id: I96d7098a1bc320793b0d0526637acd1fdb5a43eb
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>