[Development] Sub-arch optimisations (was: How qAsConst and qExchange lead to qNN)

Thiago Macieira thiago.macieira at intel.com
Tue Nov 22 04:00:43 CET 2022

On Sunday, 20 November 2022 18:38:08 PST Thiago Macieira wrote:
> I've just finished a qtbase build on Linux with two sub-architectures and
> the symbol comparison of all the resulting libraries has shown zero
> difference..

Done. All modules now built in multi-subarch mode. I've submitted a few 
cleanup commits to the modules to fix issues that don't depend on the new 

My script is showing symbol differences between the two builds. It looks like 
all the qml_register_types_* symbols are missing and half of QtLocation. I'll 
need to investigate tomorrow.

Meanwhile, I've also completed the first part of the macOS switch to v3:
Tested locally and the build is ok. I'll add the QT_BUILD_ARCH support to it 
when I'm finished on Linux.

> [*] I had an idea an hour ago, thinking about the qxcb plugin and remembered
> the old KDE Brockenbores solution.

Didn't work so well. It's possible to link to an executable, but requires 
removing one bit from the dynamic section. I managed it, but it's probably not 
worth the hassle:

$ ls -l libexec/moc
-rwxr-xr-x 1 tjmaciei users 2592 Nov 21 18:48 libexec/moc
 $ ldd libexec/moc | sed 's/(.*//'        
 moc.so => /home/tjmaciei/obj/qt/qt6/qtbase/libexec/binlib/haswell/moc.so 
 libpcre2-16.so.0 => /lib64/libpcre2-16.so.0 
 libstdc++.so.6 => /lib64/libstdc++.so.6 
 libm.so.6 => /lib64/libm.so.6 
 libgcc_s.so.1 => /lib64/libgcc_s.so.1 
 libc.so.6 => /lib64/libc.so.6 
$ libexec/moc --version
moc 6.5.0
$ libexec/binlib/haswell/moc.so --version
moc.so 6.5.0

Thiago Macieira - thiago.macieira (AT) intel.com
  Cloud Software Architect - Intel DCAI Cloud Engineering

More information about the Development mailing list