[osg-users] [build] Multi-threading crashing on start-up (2.8.3, XP, VS2008)

Robert Osfield robert.osfield at gmail.com
Wed Apr 27 00:56:33 PDT 2011


Hi Michele,


Am I correct in understanding that you've built OpenThreads to use
QT's inbuilt threading support, i which case you must have set the
BUILD_OPENTHREADS_WITH_QT to ON via ccmake or CMakeSetup.  Is this
correct?

I didn't implement and have not personally used the Qt build of
OpenThreads so can't comment specifically on it's implementation and
fucntion.   I don't believe many users use this option so it may well
be that you'll need to pitch in an help debug it.

For the case of thread affinity, if the code extract you have quoted
is correct then Qt doesn't yet have thread affinity support so this
method will be in effect be an non op and should just return.

Robert.


On Wed, Apr 27, 2011 at 4:54 AM, Michele Fiorentino
<fiorentino at poliba.it> wrote:
> Hi,
>
> i detail the error...
> //-----------------------------------------------------------------------------
> //
> // Description:  set processor affinity for the thread
> //
> // Use: public
> //
> int Thread::setProcessorAffinity(unsigned int cpunum)
> {
>  ----------->   QtThreadPrivateData* pd = static_cast<QtThreadPrivateData*>(_prvData);
>    pd->cpunum = cpunum;
>    if (!pd->isRunning) return 0;
>
>    // FIXME:
>    // Qt doesn't have a platform-independent thread affinity method at present.
>    // Does it automatically configure threads on different processors, or we have to do it ourselves?
>    return -1;
> }
>
> Thank you!
>
> Cheers,
> Michele
>
> ------------------
> Read this topic online here:
> http://forum.openscenegraph.org/viewtopic.php?p=38800#38800
>
>
>
>
>
> _______________________________________________
> osg-users mailing list
> osg-users at lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>



More information about the osg-users mailing list