pthreads and sproc

Dave Semeraro semeraro at ncsa.uiuc.edu
Fri Jan 21 16:43:34 EST 2000


Hello users...

This message is addressed to the no doubt huge IRIX sproc user base. I have
the following problem. I am using a vtk nightly release of Dec 9, on an IRIX
6.5 octane. Compilation goes fine. I am using MESA for the off screen
capability.
I compile vtk without tcl or python and with contrib and patented. The
configure
script finds the pthread stuff and wants to use that. However, I am interested
in using John Shalf's threaded contour filter (on an onyx system). Therein
lies
the problem. John advised me that his code uses sproc rather than pthreads due
to performance issues. I therefore change the -DVTK_USE_PTHREADS switch to 
-DVTK_USE_SPROC and remove the -lpthreads library link in system.make.
Everything
compiles fine but there are problems at run time. 

vtkMesaRenderWindow segfaults in a malloc in vtkOSMesaCreateWindow if I
compile
the library with sproc instead of pthreads. the test code looks like this.

#include "vtkMesaRenderer.h"
#include "vtkMesaRenderWindow.h"
void main( int argc, char *argv[])
{
char a;
     vtkMesaRenderer *ren=vtkMesaRenderer::New();
     ren->DebugOn();
     vtkMesaRenderWindow renWin=vtkMesaRenderWindow::New();
     renWin->DebugOn();
     renWin->SetOffScreenRendering(1);
     renWin->AddRenderer(ren);
     renWin->SetSize( 300, 300);
     renWin->Print(cout);
cout << "enter any key followed by <Enter> to exit >> ";
cin >> a;
}

This code works fine if I compile vtk with pthreads but is whacked with sproc.
Does anyone know why? 

Best Regards,

Dave


Dave Semeraro Ph.D.
Site Scientific Visualization Lead
ASC MSRC Wright Patterson Airforce Base

Visualization and Virtual Environments Group
NCSA University of Illinois
605 E. Springfield Ave.
Champaign, IL 61820
semeraro at ncsa.uiuc.edu
(217) 244-1852


-----------------------------------------------------------------------------
This is the private VTK discussion list.  Please keep messages on-topic.
Check the FAQ at: <http://www.automatrix.com/cgi-bin/vtkfaq>
To UNSUBSCRIBE, send message body containing "unsubscribe vtkusers" to
<majordomo at gsao.med.ge.com>.  For help, send message body containing
"info vtkusers" to the same address.     Live long and prosper.
-----------------------------------------------------------------------------




More information about the vtkusers mailing list