Re: [ROOT] Latest problem on windows explained! (Really!)

From: Nick van Eijndhoven (Nick@phys.uu.nl)
Date: Wed Oct 30 2002 - 09:35:47 MET


Hi Philippe,
Congratulations !
This is really very good news.
As far as I understand your analysis, some of the ROOT facilities
(you mention gROOT->LoadClass) are not protected for multi-thread.
Could the problem of the infinite loop after .q when a TBrowser had
been opened also be related to a somewhat similar 'disease' ?
Also this problem is only seen on windows (as far as I can check
mainly/only on win98).

                                                 Cheers,
                                                  Nick.

-- 
Dr. Nick van Eijndhoven mailto:nick@phys.uu.nl http://www.phys.uu.nl/~nick
--------------------------------------------------------------------------
Org.:    Utrecht University, Faculty of Physics and Astronomy
Address: Princetonplein 5, NL-3584 CC Utrecht, The Netherlands
Phone:   +31-30-2532331(direct) +31-30-2531492(secr.)  Fax: +31-30-2518689
CERN:    +41-22-7679751(direct) +41-22-7675857(secr.)  Fax: +41-22-7679480
Offices: Buys Ballot laboratory Room 710 (Utrecht)   B23 1-020 (CERN)
--------------------------------------------------------------------------
 

Philippe Canal wrote:
> 
> Hi,
> 
> I understood (and fixed) the problems on Window 98, XP, 2000 where ROOT
> was mysteriously, randomly crashing or giving error messages like 'this
> "text file name" is a binary file' or other weird behaviors.
> 
> This problem was only appearing at startup time and only on Windows.
> 
> The code will be fixed shortly in the CVS repository.
> 
> Cheers,
> Philippe
> 
> And now for the gory details
> 
> In the constructor of TRint::TRint we had:
> 
>    ProcessLine("#include <RtypesCint.h>");
> 
>    gROOT->LoadClass("TGeometry",   "Graf3d");
>    gROOT->LoadClass("TTree",       "Tree");
>    ....
>    ProcessLine(Form(".L %s",logon),kTRUE);
> 
> The problem comes from the fact that on Windows ProcessLine has the
> execution of its CINT part delayed (1st problem) while gROOT->LoadClass
> has the execution of its CINT part done immediately (and not protected
> for multi-thread).
> 
> Both the calls are asking CINT to load a file and in this case,
> __sometimes__ the loading of RtypesCint.h is happening __while__ loading
> the libraries thus over-writing (randomly) part of one of the loading.
> 
> The problem did indeed worsen since ROOT 3.03/07 with the introduction
> of the first ProcessLine.



This archive was generated by hypermail 2b29 : Sat Jan 04 2003 - 23:51:16 MET