Re: Slowness problem with GTK-Doc



On Fri, 2017-02-17 at 22:06 +0100, Stefan Sauer wrote:
On 02/13/2017 07:59 PM, Sébastien Wilmet wrote:

On Mon, Feb 13, 2017 at 12:48:56PM +0100, Milan Crha wrote:

On Sat, 2017-02-11 at 18:35 +0100, Sébastien Wilmet wrote:

For big projects like GTK+, building the docs takes several
hours on
my machine, and there are anyway too many warnings, with huge
'unused' files…
just out of interest, do you run gtk-doc with address sanitizer
(libasan) preloaded? I just faced myself, when running gtk-doc
with
ASAN preloaded, that it takes ages to finish, but without it the
same
project finished within minutes (evolution-data-server speaking,
size
of its gtk-doc is comparable to gtk+, I believe).
Thanks for the hint, but I don't have libasan installed. So it must
be
something else. I thought everybody had the same slowness problem
with
gtk-doc. I have an Intel core i5, so there is a problem if it takes
several hours to build the GTK+ docs. I can try with
evolution-data-server.
The slowness is due to the xslt processor. libxslt is still single
threaded, slow as hell and mostly in maintenance mode. I am now aware
of
a better xslt processor. The only sane way from my POV would be to
ditch
docbook and migrate full to markdown. I'd love to do this in gtk-doc
-
what we need is a complete migration plan and some help writing the
code. Once we have a plan we could probably write most of the code
during some hackfest.

It's true that libxslt is single threaded and mostly in maintenance
mode. But it historically has pretty good performance benchmarks when
compared to other single-threaded XSLT processors.

I've pointed out in the past that the big performance problem isn't the
XSLT processor, but the XSLT stylesheets we're feeding into them. The
docbook-xsl stylesheets that gtk-doc uses are slow. That's why Yelp
doesn't use them. Switching to the yelp-xsl stylesheets will give
better performance.

All that said, I agree with dropping DocBook as an intermediary. I also
think the C docs should go through the same build process as the docs
for bindings. There should be a just-semantic-enough markup to convert
symbols in prose to the correct bindings symbols, and the markdown or
whatever flavor needs to be parsable into an AST to make that happen.

But in the short term, switching to yelp-xsl would make builds faster.

--
Shaun





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