QHostAddress: Improve code generation
authorThiago Macieira <thiago.macieira@intel.com>
Mon, 10 Aug 2015 20:08:15 +0000 (13:08 -0700)
committerJędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
Wed, 19 Aug 2015 06:13:33 +0000 (06:13 +0000)
commitdd92002416270c56c795cce81fb9f0e55c1b2ddd
tree220bf20215468061670059ab61b2a7f3d30d4966
parentb479d5befbf6f6ed1bffef0dbccecf504263e1d6
QHostAddress: Improve code generation

Mostly related to IPv6, because Q_IPV6ADDR is an array of char, so the
compilers were generating byte access to each value. Instead, force
access as 32- and 64-bit in most places that make sense (64-bit access
decays to 32-bit on 32-bit machines). In one isLoopback(), this is now a
128-bit access for best improvement.

Some smaller improvements relating to SpecialAddress by combining the
three IPv4 special addresses.

Change-Id: I7de033f80b0e4431b7f1ffff13f932b1cd7b5d21
Reviewed-by: Richard J. Moore <rich@kde.org>
src/network/kernel/qhostaddress.cpp
tests/auto/network/kernel/qhostaddress/tst_qhostaddress.cpp