Re: [xslt] Cloning xsltStylesheet structures



Daniel Veillard wrote:


> 
>   Actually, there is very little informations associated to running
> transformation kept in the stylesheet itself. And those are cache informations
> used to speed up some of the processing.
>   I would expect concurent transformations to be able to reuse the same
> xsltStylesheetPtr for different processes. 


I am either not being clear or missing something (I have just looked at 
the definition of the "struct xsltStylesheet" [1]), but it includes 
elements such as the pointer on the source document and the list of 
variables and parameters which are dependent of the transformation which 
is being run even though the stylesheet may be the same.

How can we share a xsltStylesheetPtr if these are different?

Thanks

Eric

[1] http://xmlsoft.org/XSLT/html/libxslt-xsltinternals.html#XSLTSTYLESHEET


>   The cache informations [*] could be moved on the transformation context
> or the new libxml2 thread API could be reused to protect them, then
> parallel reuse of a compiled stylesheet would be garanteed to be safe.
> 
> Daniel
> 
> [*] this is the previous node which matched the predicate kept when using
>     predicates in selectors. The XPath optimizer may also modify the compiled
>     stylesheet (changing the XPath evaluation trees for faster evaluation
>     depending on the usage pattern) but this is disabled as soon as reentrancy
>     in the XPath engine is detected.
> 
> 



-- 
See you in Orlando for XML 2001.
                                     http://www.xmlconference.net/xmlusa/
------------------------------------------------------------------------
Eric van der Vlist       http://xmlfr.org            http://dyomedea.com
http://xsltunit.org      http://4xt.org           http://examplotron.org
------------------------------------------------------------------------




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]