| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
0.5 is double a literal, and they force computation on double
while it would be more optimized on qreal if qreal is a float
Task-number: QTBUG-16673
Reviewed-by: Thierry
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If a class has QBasicTimer as member of a derived class QObjectPrivate,
the QBasicTimer will be destroyed after the timer has been cleaned.
The QBasicTimer will stop the timer in its destructor. But that means
that the same timer will be stoped twice, leading to ugly bugs.
Reviewed-by: Thiago
Reviewed-by: Brad
Task-number: QTBUG-16558
Task-number: QTBUG-16175
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
examples/webkit/imageanalyzer/imageanalyzer.h
examples/webkit/imageanalyzer/mainwindow.h
mkspecs/unsupported/qws/linux-x86-openkode-g++/qplatformdefs.h
src/corelib/io/qfsfileengine_iterator_unix.cpp
src/corelib/io/qfsfileengine_iterator_win.cpp
src/corelib/kernel/qcoreapplication.cpp
src/network/access/qnetworkaccessdatabackend.cpp
src/plugins/bearer/connman/qconnmanservice_linux.cpp
src/plugins/platforms/openvglite/qwindowsurface_vglite.h
src/s60installs/bwins/QtCoreu.def
src/s60installs/eabi/QtCoreu.def
src/s60installs/s60installs.pro
tools/assistant/tools/assistant/helpviewer_qwv.h
tools/qdoc3/test/qt-html-templates.qdocconf
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
QSystemSemaphore native RSemaphore handle was unnecessarily created
again on each acquire. The creation logic was also susceptible for
random failures when two or more threads tried simultaneously acquire
the semaphore.
Task-number: QTBUG-16615
Reviewed-by: Janne Koskinen
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When a Symbian application is launched using RApaLsSession::StartApp,
command line parameters can be given with CApaCommandLine::SetTailEndL
and will now be correctly interpreted by Qt applications as command
line parameters.
There are a couple of limitations:
1) The parameters given with CApaCommandLine::SetTailEndL will not
be available in main method's argv array; they can be
accessed via QCoreApplication::arguments function.
2) CApaCommandLine::SetTailEndL does support any arbitrary binary data
as parameter, but only 8-bit string data gets parsed properly into
QCoreApplication::arguments. For other kind of tail data, you need
to subclass QS60MainAppUi and implement ProcessCommandParametersL
callback.
Task-number: QTBUG-15987
Reviewed-by: axis
|
| |
| |
| |
| |
| |
| | |
Was removed by mistake in commit 02aecce59cb76ceb88f635203553
Reviewed-by: Peter Hartmann
|
| |\
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1:
QFont/Windows: restrict the pixel size accuracy
Update copyright year to 2011.
For non-developer builds, skip test that requires private API
tst_qhttpnetworkconnection: Compile fix
Change QHostInfoCache to use QElapsedTime instead of QTime.
Fix for qtdemo bug
|
| | |
| | |
| | |
| | | |
Reviewed-by: Trust Me
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The timer handle was only being closed when a timer was cancelled,
which resulted in a leak for one shot timers that have completed normally.
Instead the timer is now closed in a destructor (closing null handles is
safe, so it doesn't matter if the handle was never created - e.g. in the
case of a zero timer)
Also added a handle check before creating a timer to prevent a leak in
case the start function is called twice in the backend.
Task-number: QTBUG-16380
Reviewed-by: mread
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
QHash is slightly faster than QMap and should be preferred where
the key order has no meaning;
take() is faster than value() + remove()
Reviewed-by: Olivier Goffart
Merge-request: 1017
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
by setting the proper macro-guards;
regroup macro-guards for better readability (superfluous change, I know);
fix typos in the comments
was not splited into two commits to make it more clear why and how
that warning is fixed now
Merge-request: 955
Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
|
| |
| |
| |
| |
| |
| |
| | |
sysV shm isn't used in QSystemSemaphore
Merge-request: 998
Reviewed-by: Olivier Goffart
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
as POSIX man says, if semop() is interrupted by a signal,
it shall return -1 and set errno to EINTR.
in qcore_unix_p.h, we have EINTR_LOOP helper macro exactly for such cases ;)
Task-number: QTBUG-14434
Merge-request: 998
Reviewed-by: Olivier Goffart
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
like how we do that for ISO format
Reviewed-by: ddenis
Merge-request: 2536
Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
according to the write(2) docs:
When write requests greater than {PIPE_BUF} bytes to a pipe that
has available space at least 1 byte, if O_NONBLOCK is set,
write transfers what it can and returns the number of bytes written.
When write requests of {PIPE_BUF} or less bytes to a pipe that has no
enough space, or write requests for greater than {PIPE_BUF} bytes
to a pipe that has no space, if O_NONBLOCK is set,
write returns -1 and sets errno to EAGAIN.
Merge-request: 997
Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
|
| |
| |
| |
| |
| | |
Merge-request: 997
Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
|
| |
| |
| |
| | |
Reviewed-by: Bradley T. Hughes
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
master-integration
* 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1:
Add /DYNAMICBASE /NXCOMPAT to linker options in Visual Studio 2005 and higher
Fix compilation error on Solaris
Check elapsed time only once
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
d_type in dirent is a non-standard extension to POSIX available on some
platforms (namely BSDs, Mac, Linux, Symbian).
Taking the conservative approach and using this information only on
platforms known to support it.
Reviewed-by: Shane Kearns
|
| | |
| | |
| | |
| | |
| | | |
Task-number: QTBUG-16262
Reviewed-by: Bradley T. Hughes
|
|\ \ \
| |/ /
|/| /
| |/ |
|
| |
| |
| |
| |
| |
| | |
Task-number: QTBUG-16425
Reviewed-by: Gabriel
Reviewed-by: Markus Goetz
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
scm.dev.nokia.troll.no:qt/qt-file-engines-refactor into master-integration
* 'earth/file-engine-refactor' of scm.dev.nokia.troll.no:qt/qt-file-engines-refactor:
Fix qfile test crash with glibc
Fix qfile test errors
Update def files
Add autotests for AutoCloseHandle / DontCloseHandle and RFile adoption
QFile API: add API to specify if adopted file handles should be closed
|
| |\ \
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
scm.dev.nokia.troll.no:qt/qt-file-engines-refactor into master-integration
* 'earth/file-engine-refactor' of scm.dev.nokia.troll.no:qt/qt-file-engines-refactor:
Fix qfile test crash with glibc
Fix qfile test errors
Update def files
Add autotests for AutoCloseHandle / DontCloseHandle and RFile adoption
QFile API: add API to specify if adopted file handles should be closed
|
| | |\ \
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
scm.dev.nokia.troll.no:qt/qt-file-engines-refactor into master-integration
* 'earth/file-engine-refactor' of scm.dev.nokia.troll.no:qt/qt-file-engines-refactor:
Fix qfile test crash with glibc
Fix qfile test errors
Update def files
Add autotests for AutoCloseHandle / DontCloseHandle and RFile adoption
QFile API: add API to specify if adopted file handles should be closed
|
| | | |\ \
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
scm.dev.nokia.troll.no:qt/qt-file-engines-refactor into master-integration
* 'earth/file-engine-refactor' of scm.dev.nokia.troll.no:qt/qt-file-engines-refactor:
Update def files
Add autotests for AutoCloseHandle / DontCloseHandle and RFile adoption
QFile API: add API to specify if adopted file handles should be closed
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
QFile behaviour has been to not close file handles adopted by
open(FILE*, OpenMode) and open(int fd, OpenMode) functions. This is
inconvenient for frameworks which want to return an opened QFile to
the user. In this case it would be better to transfer ownership of the
handle to the QFile.
New overloads are added which take an additional parameter from the
QFile::FileHandleFlags flags. Currently only one bit is used to provide the
AutoCloseHandle option, but it is extensible.
The AutoCloseHandle option tells the QFile backend that it should
close the handle when close() is called, rather than the default
behaviour which remains to flush the handle and leave it open.
The DontCloseHandle option is the inverse of this, specifying the old
behaviour of flushing but not closing the file handle.
Symbian OS file handles are not compatible with int, they are an opaque
data type which contains two integers.
The first identifies to the kernel the file server session
The second identifies to the file server the subsession object (the file)
The reason for this is that it has a microkernel architecture, the
kernel has no support for files - all files and file systems are handled
by a user mode process called the "file server".
So for symbian, a new QFile::open() overload is added for adopting a
symbian RFile handle.
The API mirrors the existing API for POSIX file handles, but takes an
RFile reference rather than an integer file descriptor.
Task-number: QT-2924
Reviewed-by: joao
Reviewed-by: mread
Reviewed-by: Oswald Buddenhagen
|
|\ \ \ \ \ \
| |/ / / / /
|/| | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
master-integration
* 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
Prevented infinite loop in QMoviePrivate::next().
Added int overloads to QPoint operator* and operator*=.
tst_qmessagebox: add debug to know why it fails
QMessageBox wrong Show/Hide Details button label
|
| |\ \ \ \ \
| | |/ / / /
| |/| | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
master-integration
* 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
Prevented infinite loop in QMoviePrivate::next().
Added int overloads to QPoint operator* and operator*=.
tst_qmessagebox: add debug to know why it fails
QMessageBox wrong Show/Hide Details button label
|
| | |/ / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
For increased performance to avoid having to convert to qreal and back.
Separating the qreal overload into float and double overloads is also
necessary to avoid compiler errors about ambiguous overloads.
Task-number: QTBUG-15872
Reviewed-by: Eskil Abrahamsen Blomfeldt
|
|\ \ \ \ \
| |/ / / /
|/| | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
master-integration
* 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1: (39 commits)
Whitespace change
Fix for coding conventions.
Fix resource leak in QCLuceneStandardAnalyzer::QCLuceneStandardAnalyzer.
Fix resource leak in QCLuceneStopAnalyzer::QCLuceneStopAnalyzer.
Assistant: Get rid of bogus warning.
add missing license header
Add inter-process binary shader cache for MeeGo
Track average wait times under our maximum spin time threshold
Store and track spin times in nanosecond resolution
Optimize adaptive spinning mutex code
Improve QMutex contention performance on Linux
Improve QMutex contention performance on Mac OS X
Disable spinning under lock contention on single CPU machines
Remove unnecessary testAndSetAcquire from QMutex::lockInternal()
Move contender count maintenance to QMutexPrivate
test contention when using 2 mutexes
Ensure that every thread does contend in the contention tests
Add baseline test data to measure test overhead
Test contention performance for long (10ms) critical sections
Add a benchmark for contended and uncontended QMutex performance
...
|
| |\ \ \ \
| | |/ / /
| |/| | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
master-integration
* 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1: (33 commits)
Add inter-process binary shader cache for MeeGo
Track average wait times under our maximum spin time threshold
Store and track spin times in nanosecond resolution
Optimize adaptive spinning mutex code
Improve QMutex contention performance on Linux
Improve QMutex contention performance on Mac OS X
Disable spinning under lock contention on single CPU machines
Remove unnecessary testAndSetAcquire from QMutex::lockInternal()
Move contender count maintenance to QMutexPrivate
test contention when using 2 mutexes
Ensure that every thread does contend in the contention tests
Add baseline test data to measure test overhead
Test contention performance for long (10ms) critical sections
Add a benchmark for contended and uncontended QMutex performance
Removed QMutexPrivate::self() declaration
Add QElapsedTimer::nsecsElapsed() const
Delay creation of the process manager
Make the QRasterPaintEngineState copy constructor cheaper.
Micro-optimization for QSpanData::setup()
define FSCTL_SET_REPARSE_POINT in test header
...
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Further observation shows that spin times slightly over the average wait time
produce the best results. This change keeps a heavily weighted average
of the wait times under 1.5ms (1.5 times the max spin threshold), and adjusts
the spin time to be 150% of the average wait time.
Introduce spin time adjustments when spin locking works, and adjust to
between 150% of the average wait time and the maximum threshold.
Reviewed-by: joao
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Use the new QElapsedTimer::nsecsElapsed() and store all values in qint64
instead of int.
The maximum spin time threshold is now 1000000ns, or 1ms. Spinning for longer
than 1ms is just a waste of time, CPU, and battery.
Reviewed-by: joao
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Change the adaptive spinning code to be elapsed time based instead of
iteration based. The new approach will quickly reduce the amount of
allowed spinning time when it detects that lock contention is resolved
by waiting instead of spinning. We get better results by dynamically
adjusting for elapsed running time instead of trying to fine tune
iteration counts that won't work for all CPU types, speeds, etc.
From observation, lock performance suffers if the spin time is higher
than the minimum wait time. Because of this, QMutex never increases the
spin time, it only reduces the spin time to the minimum observed wait time.
For very long wait times, we disable spinning completely (and always resolve
contention by waiting).
Use QThread::yieldCurrentThread() when spinning on a contended mutex. Comment
from the code: be a good citizen... yielding lets something else run if
there is something to run, but may also relieve memory pressure if not.
Reviewed-by: joao
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Use futex(2) to implement QMutexPrivate::wait() and ::wakeup(). This
makes QMutex perform more or less identically the same as
pthread_mutex_t when contended.
We have to use the contender count in a different way due to the way
that futex() waiting works. Waiting on a futex atomically checks that
the value has not changed from the expected value and then puts the
thread to sleep. So, on Linux, the contender QAtomicInt will only ever
be one of three values: 0 for unlocked, 1 for locked, 2 for contended.
This does mean that there is a slight chance for unfairness due to the
fetch-and-store to zero in the wakeUp() function, but unfortunately this
cannot be avoid as the code is now.
Reviewed-by: joao
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Use a Mach semaphore to implement QMutexPrivate::wait() and ::wakeup(). This
makes QMutex perform more or less identically the same as pthread_mutex_t when
contended.
Reviewed-by: joao
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Spinning is just wasted time on these systems.
Reviewed-by: joao
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
QMutexPrivate::wait() will take care of doing another test for the lock
before putting the thread to sleep, so we can avoid another if().
Reviewed-by: joao
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Make the cross-platform implementation of QMutex in qmutex.cpp only use
testAndSetAcquire(0, 1) and testAndSetRelease(1, 0) like in the new inline
functions in qmutex.h
This will allow us to open up for more platform-specific optimizations to
improve performance of contended QMutexes.
Reviewed-by: joao
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This function is not used or implemented anywhere.
Reviewed-by: joao
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Allow sub-millisecond resolution on systems where it is possible. On UNIX,
with monotonic clock support we get full nanosecond resolution, microsecond
otherwise. On Windows we convert the performance counters to nanoseconds if
availble, otherwise we only have millisecond resolution. On Mac, the mach time
is converted to nanoseconds. On Symbian, we have microsecond resolution.
Reviewed-by: joao
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The *nix process manager would create a pipe on every startup. In order
to improve startup speed, the QProcessManager is now created when first
needed.
Reviewed-by: Robert Griebl
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
introduce QXmlStreamWriter::hasError(). set the error flag when any
write error occurs. ignore subsequent writes after the first error.
Reviewed-by: denis
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
don't throw away the already known length just to call strlen() on it
over and over again.
Reviewed-by: denis
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
writeEscaped() can simply call write() once it's done escaping
Reviewed-by: denis
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
it's only ever called with ascii data, and the input encoding semantics
weren't all that clear anyway.
Reviewed-by: denis
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
add new status flag WriteFailed.
use it in flushWriteBuffer().
remove the boolean return values from write(), putString() and
putNumber(), as they were ignored anyway - flushWriteBuffer() does it
correctly now.
Task-number: QTBUG-376
Reviewed-by: mariusSO
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
add new status flag WriteFailed.
use it in all write functions.
Task-number: QTBUG-376
Reviewed-by: mariusSO
|