Use qOffsetStringArray() instead of an array of pairs of pointers.
This unearthed a problem with SIGNAL and SLOT calling qFlagLocation()
(meaning in debug mode, the array was runtime-initialized, not just
relocated), which we work around by using the new QT_STRINGIFY_
{SIGNAL,SLOT} macros now.
Saves 24 relocations, but, interestingly, saves only 4b in text size
on GCC 11.2 Linux AMD64 -O2 C++20 builds (TEXT and DATA combined)
while saving 760b on the equivalent Clang 10 libc++ build (expected,
in both cases: 24 * (sizeof(void*) - sizeof(quint16))):
Clang:
$ size qtbase/lib/libQt6Core.so.6.4.0
text data bss dec hex filename
5476156 90520 16185 5582861 55300d qtbase/lib/libQt6Core.so.6.4.0
$ ~/bin/relinfo.pl qtbase/lib/libQt6Core.so.6.4.0
qtbase/lib/libQt6Core.so.6.4.0: 6528 relocations, 3598 relative (55%), 2540 PLT entries, 2227 for local syms (87%), 0 users
$ ninja libQt6Core.so
[6/6] Creating library symlink qtbase/lib/libQt6Core.so.6 qtbase/lib/libQt6Core.so
$ size qtbase/lib/libQt6Core.so.6.4.0
text data bss dec hex filename
5475604 90312 16185 5582101 552d15 qtbase/lib/libQt6Core.so.6.4.0
$ ~/bin/relinfo.pl qtbase/lib/libQt6Core.so.6.4.0
qtbase/lib/libQt6Core.so.6.4.0: 6504 relocations, 3574 relative (54%), 2540 PLT entries, 2227 for local syms (87%), 0 users
GCC:
$ ~/bin/relinfo.pl qtbase/lib/libQt6Core.so.6.4.0
qtbase/lib/libQt6Core.so.6.4.0: 6300 relocations, 5343 relative (84%), 318 PLT entries, 1 for local syms (0%), 0 users
$ size qtbase/lib/libQt6Core.so.6.4.0
text data bss dec hex filename
6019871 75896 16952 6112719 5d45cf qtbase/lib/libQt6Core.so.6.4.0
$ ninja libQt6Core.so
[6/6] Creating library symlink qtbase/lib/libQt6Core.so.6 qtbase/lib/libQt6Core.so
$ ~/bin/relinfo.pl qtbase/lib/libQt6Core.so.6.4.0
qtbase/lib/libQt6Core.so.6.4.0: 6276 relocations, 5319 relative (84%), 318 PLT entries, 1 for local syms (0%), 0 users
$ size qtbase/lib/libQt6Core.so.6.4.0
text data bss dec hex filename
6020091 75672 16952 6112715 5d45cb qtbase/lib/libQt6Core.so.6.4.0
Pick-to: 6.3
Change-Id: I60749953f1a63d23d696a5a547cd924ec259ead3
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>