[Development] New QUrl implementation

Thiago Macieira thiago.macieira at intel.com
Wed Jan 4 17:48:17 CET 2012


On Wednesday, 4 de January de 2012 13.24.20, Thiago Macieira wrote:
> I've run all the benchmarks I could on the photoviewer example. I managed to
> crash my system twice while doing hardware event collection.
> 
> The impact of the QUrl changes in the example is: inconclusive
> 
> QUrl's contribution to the example is negligible in both cases. The number
> of samples collected in QUrl functions is way too small to enable any kind
> of insight. I cannot even conclude which functions were *called*.

Ok, now running the QUrl benchmark for better results.

Spreadsheet:
https://docs.google.com/spreadsheet/ccc?key=0AvVqQ9a3_pIudFgyT2Jodm5DRXp3NHM5S1FNZXkzTVE

Web page:
https://docs.google.com/spreadsheet/pub?key=0AvVqQ9a3_pIudFgyT2Jodm5DRXp3NHM5S1FNZXkzTVE&single=true&gid=0&output=html

VTune result images attached,

Highlights:

* EVERYTHING tested is faster 
  (though unfortunately nothing reaches 1 robe)
* On average, over the entire run, it was 2.84x times faster (tick counter) or 
  3x faster (run time under VTune)
* As you can see in the "old.png" image, most of the time of the old code is 
  spent in malloc, percent encoding and UTF-8 encoding. The new code does the 
  UTF-8 and percent encoding in one pass, saving in memory memory allocations.

The "old" code is qtbase at 52fc669. The "new" one is 96a5f8e. They are the 
same Qt build options, which were:
	gcc x86-64 64-bit 4.6.0 (20110428 (Red Hat 4.6.0-6))
	-march=core2 -mtune=corei7-avx -maccumulate-outgoing-args -std=c++0x -O3

Important: the "new" branch contains 70 changes in corelib on top of the 
"old". Of those, only 25 are directly related to QUrl. The rest may or may not 
have contributed improvements too, like the new atomics, but I cannot be 
bothered to test without them.

I can't figure out how to get VTune to give me a call graph, so I can't tell 
exactly how much time is spent under the parsing routines. I think I need to 
use a function that is complaining that Linux 3.1 isn't supported.

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center
     Intel Sweden AB - Registration Number: 556189-6027
     Knarrarnäsgatan 15, 164 40 Kista, Stockholm, Sweden
-------------- next part --------------
A non-text attachment was scrubbed...
Name: new.png
Type: image/png
Size: 44617 bytes
Desc: not available
URL: <http://lists.qt-project.org/pipermail/development/attachments/20120104/f83d43fa/attachment.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: old.png
Type: image/png
Size: 45353 bytes
Desc: not available
URL: <http://lists.qt-project.org/pipermail/development/attachments/20120104/f83d43fa/attachment-0001.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/development/attachments/20120104/f83d43fa/attachment.sig>


More information about the Development mailing list