Trolltech Home | Qt-interest Home | Recent Threads | All Threads | Author | Date
All threads index page 7

Qt-interest Archive, April 2007
Qt GUI limitations


Message 1 in thread

Hi,

I'm creating a data entry form with LOTS of controls on it. How many 
controls can safely be placed on one QMainWindow (using tabs and the like)?

What leads me to ask this question is, when I create over 200 
QCheckBoxes on a form, and then close it, I get the following output:

*** glibc detected *** ./QSuperTester: corrupted double-linked list: 
0x09edd7b0 ***
======= Backtrace: =========
/lib/libc.so.6[0x3b3f5e]
/lib/libc.so.6(cfree+0x90)[0x3b76f0]
/lib/libc.so.6(fclose+0x134)[0x3a33f4]
/usr/local/Trolltech/Qt-4.2.3/lib/libQtCore.so.4(_ZN13QFSFileEngine5closeEv+0x7f)[0x83c8df]
/usr/local/Trolltech/Qt-4.2.3/lib/libQtCore.so.4(_ZN5QFile5closeEv+0x60)[0x8016b0]
/usr/lib/libqextserialport.so.1(_ZN20Posix_QextSerialPort5closeEv+0x15)[0x2471b5]
./QSuperTester[0x8066e3c]
./QSuperTester[0x8066e4f]
./QSuperTester[0x80b5965]
/usr/local/Trolltech/Qt-4.2.3/lib/libQtCore.so.4(_ZN11QMetaObject8activateEP7QObjectiiPPv+0x610)[0x871030]
/usr/local/Trolltech/Qt-4.2.3/lib/libQtCore.so.4(_ZN11QMetaObject8activateEP7QObjectPKS_iPPv+0x3a)[0x87198a]
/usr/local/Trolltech/Qt-4.2.3/lib/libQtCore.so.4(_ZN16QCoreApplication11aboutToQuitEv+0x37)[0x8901e7]
/usr/local/Trolltech/Qt-4.2.3/lib/libQtCore.so.4(_ZN16QCoreApplication4execEv+0xce)[0x86133e]
/usr/local/Trolltech/Qt-4.2.3/lib/libQtGui.so.4(_ZN12QApplication4execEv+0x27)[0xbc1397]
./QSuperTester(_ZN7QWidget5eventEP6QEvent+0x62b)[0x804f0db]
/lib/libc.so.6(__libc_start_main+0xdc)[0x363f2c]
./QSuperTester(_ZNK7QDialog8sizeHintEv+0xa1)[0x804efb1]
======= Memory map: ========
00110000-00118000 r-xp 00000000 fd:00 2687518    /usr/lib/libSM.so.6.0.0
00118000-00119000 rwxp 00007000 fd:00 2687518    /usr/lib/libSM.so.6.0.0
00119000-00130000 r-xp 00000000 fd:00 2687517    /usr/lib/libICE.so.6.3.0
00130000-00131000 rwxp 00016000 fd:00 2687517    /usr/lib/libICE.so.6.3.0
00131000-00133000 rwxp 00131000 00:00 0
00133000-0013b000 r-xp 00000000 fd:00 2687012    
/usr/lib/libXrender.so.1.3.0
0013b000-0013c000 rwxp 00007000 fd:00 2687012    
/usr/lib/libXrender.so.1.3.0
0013c000-0013f000 r-xp 00000000 fd:00 2687020    /usr/lib/libXrandr.so.2.0.0
0013f000-00140000 rwxp 00002000 fd:00 2687020    /usr/lib/libXrandr.so.2.0.0
00140000-00142000 r-xp 00000000 fd:00 2687018    
/usr/lib/libXinerama.so.1.0.0
00142000-00143000 rwxp 00001000 fd:00 2687018    
/usr/lib/libXinerama.so.1.0.0
00143000-00152000 r-xp 00000000 fd:00 2687017    /usr/lib/libXext.so.6.4.0
00152000-00153000 rwxp 0000e000 fd:00 2687017    /usr/lib/libXext.so.6.4.0
00153000-00165000 r-xp 00000000 fd:00 2687313    /usr/lib/libz.so.1.2.3
00165000-00166000 rwxp 00011000 fd:00 2687313    /usr/lib/libz.so.1.2.3
00166000-0016a000 r-xp 00000000 fd:00 13566256   
/lib/libgthread-2.0.so.0.1200.9
0016a000-0016b000 rwxp 00003000 fd:00 13566256   
/lib/libgthread-2.0.so.0.1200.9
0016b000-0016d000 r-xp 00000000 fd:00 13567162   /lib/libdl-2.5.so
0016d000-0016e000 r-xp 00001000 fd:00 13567162   /lib/libdl-2.5.so
0016e000-0016f000 rwxp 00002000 fd:00 13567162   /lib/libdl-2.5.so
0016f000-00182000 r-xp 00000000 fd:00 13567028   /lib/libpthread-2.5.so
00182000-00183000 r-xp 00012000 fd:00 13567028   /lib/libpthread-2.5.so
00183000-00184000 rwxp 00013000 fd:00 13567028   /lib/libpthread-2.5.so
00184000-00186000 rwxp 00184000 00:00 0
00186000-001ab000 r-xp 00000000 fd:00 13567161   /lib/libm-2.5.so
001ab000-001ac000 r-xp 00024000 fd:00 13567161   /lib/libm-2.5.so
001ac000-001ad000 rwxp 00025000 fd:00 13567161   /lib/libm-2.5.so
001ad000-001b8000 r-xp 00000000 fd:00 13567165   
/lib/libgcc_s-4.1.1-20070105.so.1
001b8000-001b9000 rwxp 0000a000 fd:00 13567165   
/lib/libgcc_s-4.1.1-20070105.so.1
001b9000-001d8000 r-xp 00000000 fd:00 13567164   /lib/libexpat.so.0.5.0
001d8000-001da000 rwxp 0001e000 fd:00 13567164   /lib/libexpat.so.0.5.0
001da000-001dc000 r-xp 00000000 fd:00 2687496    /usr/lib/libXau.so.6.0.0
001dc000-001dd000 rwxp 00001000 fd:00 2687496    /usr/lib/libXau.so.6.0.0
001e0000-00238000 r-xp 00000000 fd:00 8291329    
/usr/local/Trolltech/Qt-4.2.3/lib/libQtNetwork.so.4.2.3
00238000-0023a000 rwxp 00057000 fd:00 8291329    
/usr/local/Trolltech/Qt-4.2.3/lib/libQtNetwork.so.4.2.3
0023a000-0023f000 r-xp 00000000 fd:00 2687497    /usr/lib/libXdmcp.so.6.0.0
0023f000-00240000 rwxp 00004000 fd:00 2687497    /usr/lib/libXdmcp.so.6.0.0
00240000-00242000 r-xp 00000000 fd:00 7312349    /usr/lib/gAborted

--
 [ signature omitted ] 

Message 2 in thread

On 30/04/07, John Voltz <ninevoltz@xxxxxxxxxxxx> wrote:
> Hi,
>
> I'm creating a data entry form with LOTS of controls on it. How many
> controls can safely be placed on one QMainWindow (using tabs and the like)?
>
> What leads me to ask this question is, when I create over 200
> QCheckBoxes on a form, and then close it, I get the following output:
>
> *** glibc detected *** ./QSuperTester: corrupted double-linked list:
> 0x09edd7b0 ***
> ======= Backtrace: =========
> /lib/libc.so.6[0x3b3f5e]
> /lib/libc.so.6(cfree+0x90)[0x3b76f0]
> /lib/libc.so.6(fclose+0x134)[0x3a33f4]
> /usr/local/Trolltech/Qt-4.2.3/lib/libQtCore.so.4(_ZN13QFSFileEngine5closeEv+0x7f)[0x83c8df]
> /usr/local/Trolltech/Qt-4.2.3/lib/libQtCore.so.4(_ZN5QFile5closeEv+0x60)[0x8016b0]
> /usr/lib/libqextserialport.so.1(_ZN20Posix_QextSerialPort5closeEv+0x15)[0x2471b5]
> ./QSuperTester[0x8066e3c]
> ./QSuperTester[0x8066e4f]
> ./QSuperTester[0x80b5965]
> /usr/local/Trolltech/Qt-4.2.3/lib/libQtCore.so.4(_ZN11QMetaObject8activateEP7QObjectiiPPv+0x610)[0x871030]
> /usr/local/Trolltech/Qt-4.2.3/lib/libQtCore.so.4(_ZN11QMetaObject8activateEP7QObjectPKS_iPPv+0x3a)[0x87198a]
> /usr/local/Trolltech/Qt-4.2.3/lib/libQtCore.so.4(_ZN16QCoreApplication11aboutToQuitEv+0x37)[0x8901e7]
> /usr/local/Trolltech/Qt-4.2.3/lib/libQtCore.so.4(_ZN16QCoreApplication4execEv+0xce)[0x86133e]
> /usr/local/Trolltech/Qt-4.2.3/lib/libQtGui.so.4(_ZN12QApplication4execEv+0x27)[0xbc1397]
> ./QSuperTester(_ZN7QWidget5eventEP6QEvent+0x62b)[0x804f0db]
> /lib/libc.so.6(__libc_start_main+0xdc)[0x363f2c]
> ./QSuperTester(_ZNK7QDialog8sizeHintEv+0xa1)[0x804efb1]
> ======= Memory map: ========
> 00110000-00118000 r-xp 00000000 fd:00 2687518    /usr/lib/libSM.so.6.0.0
> 00118000-00119000 rwxp 00007000 fd:00 2687518    /usr/lib/libSM.so.6.0.0
> 00119000-00130000 r-xp 00000000 fd:00 2687517    /usr/lib/libICE.so.6.3.0
> 00130000-00131000 rwxp 00016000 fd:00 2687517    /usr/lib/libICE.so.6.3.0
> 00131000-00133000 rwxp 00131000 00:00 0
> 00133000-0013b000 r-xp 00000000 fd:00 2687012
> /usr/lib/libXrender.so.1.3.0
> 0013b000-0013c000 rwxp 00007000 fd:00 2687012
> /usr/lib/libXrender.so.1.3.0
> 0013c000-0013f000 r-xp 00000000 fd:00 2687020    /usr/lib/libXrandr.so.2.0.0
> 0013f000-00140000 rwxp 00002000 fd:00 2687020    /usr/lib/libXrandr.so.2.0.0
> 00140000-00142000 r-xp 00000000 fd:00 2687018
> /usr/lib/libXinerama.so.1.0.0
> 00142000-00143000 rwxp 00001000 fd:00 2687018
> /usr/lib/libXinerama.so.1.0.0
> 00143000-00152000 r-xp 00000000 fd:00 2687017    /usr/lib/libXext.so.6.4.0
> 00152000-00153000 rwxp 0000e000 fd:00 2687017    /usr/lib/libXext.so.6.4.0
> 00153000-00165000 r-xp 00000000 fd:00 2687313    /usr/lib/libz.so.1.2.3
> 00165000-00166000 rwxp 00011000 fd:00 2687313    /usr/lib/libz.so.1.2.3
> 00166000-0016a000 r-xp 00000000 fd:00 13566256
> /lib/libgthread-2.0.so.0.1200.9
> 0016a000-0016b000 rwxp 00003000 fd:00 13566256
> /lib/libgthread-2.0.so.0.1200.9
> 0016b000-0016d000 r-xp 00000000 fd:00 13567162   /lib/libdl-2.5.so
> 0016d000-0016e000 r-xp 00001000 fd:00 13567162   /lib/libdl-2.5.so
> 0016e000-0016f000 rwxp 00002000 fd:00 13567162   /lib/libdl-2.5.so
> 0016f000-00182000 r-xp 00000000 fd:00 13567028   /lib/libpthread-2.5.so
> 00182000-00183000 r-xp 00012000 fd:00 13567028   /lib/libpthread-2.5.so
> 00183000-00184000 rwxp 00013000 fd:00 13567028   /lib/libpthread-2.5.so
> 00184000-00186000 rwxp 00184000 00:00 0
> 00186000-001ab000 r-xp 00000000 fd:00 13567161   /lib/libm-2.5.so
> 001ab000-001ac000 r-xp 00024000 fd:00 13567161   /lib/libm-2.5.so
> 001ac000-001ad000 rwxp 00025000 fd:00 13567161   /lib/libm-2.5.so
> 001ad000-001b8000 r-xp 00000000 fd:00 13567165
> /lib/libgcc_s-4.1.1-20070105.so.1
> 001b8000-001b9000 rwxp 0000a000 fd:00 13567165
> /lib/libgcc_s-4.1.1-20070105.so.1
> 001b9000-001d8000 r-xp 00000000 fd:00 13567164   /lib/libexpat.so.0.5.0
> 001d8000-001da000 rwxp 0001e000 fd:00 13567164   /lib/libexpat.so.0.5.0
> 001da000-001dc000 r-xp 00000000 fd:00 2687496    /usr/lib/libXau.so.6.0.0
> 001dc000-001dd000 rwxp 00001000 fd:00 2687496    /usr/lib/libXau.so.6.0.0
> 001e0000-00238000 r-xp 00000000 fd:00 8291329
> /usr/local/Trolltech/Qt-4.2.3/lib/libQtNetwork.so.4.2.3
> 00238000-0023a000 rwxp 00057000 fd:00 8291329
> /usr/local/Trolltech/Qt-4.2.3/lib/libQtNetwork.so.4.2.3
> 0023a000-0023f000 r-xp 00000000 fd:00 2687497    /usr/lib/libXdmcp.so.6.0.0
> 0023f000-00240000 rwxp 00004000 fd:00 2687497    /usr/lib/libXdmcp.so.6.0.0
> 00240000-00242000 r-xp 00000000 fd:00 7312349    /usr/lib/gAborted
>
> --
> To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with "unsubscribe" in the subject or the body.
> List archive and information: http://lists.trolltech.com/qt-interest/
>
>
Be sure this has nothing to do with number of widgets (at least directly).
If you any further help, then Frame Stack and/or a look at the
relevant source will be needed.

-- 
 [ signature omitted ] 

Message 3 in thread

On Monday 30 April 2007, John Voltz wrote:
> I'm creating a data entry form with LOTS of controls on it. How many
> controls can safely be placed on one QMainWindow (using tabs and the
> like)?

The limit is your memory and your patience. On most systems it becomes very 
slow long before you hit the memory limit which you'll hit long before any 
architectural limits.

> What leads me to ask this question is, when I create over 200
> QCheckBoxes on a form, and then close it, I get the following output:
>
> *** glibc detected *** ./QSuperTester: corrupted double-linked list:
> 0x09edd7b0 ***

This sounds familiar: the glibc has a few detection routines that alert you 
if it thinks your memory management is corrupted. This could be one or 
multiple of:

a) a double free - make sure each object is deleted EXACTLY once 
(deleteLater() can be dangerous in certain situations - eg. in the 
destructor of the parent widget)

b) you wrote a negative index of an array (eg. ptr=new char[5]; 
ptr[-3]=0;) - this would overwrite the memory management information of 
glibc

c) you have a buffer overflow and wrote beyond some array into the range of 
the memory info of the next object

d) your memory modules (physical RAM) are broken (good detector: do you get 
compiler errors on long and complex compiles, like the Linux kernel or 
KDE?)

e) you use a buggy version of glibc (is it a development version?)

f) something completely different

What exactly is QSuperTester by the way?


	Konrad

Attachment:

Attachment: pgpgKdrOj3sqX.pgp
Description: PGP signature