Code Monkey home page Code Monkey logo

Comments (7)

michaeljones avatar michaeljones commented on June 12, 2024

Hey,

A very fair point. Breathe has had almost no optimisation at this point. In particular, the xml is not only processed but actually parsed a-new every time. Ridiculous but then I've never used at quite the level you have, which was foolish of me!

One minor issue that has been on my mind is that early in the project I read a recommendation about not keeping the xml in memory as doxygen projects can get quite large. But there must be a better approach than what we're currently doing.

Caching the parsed xml should be easily done, I've been meaning to do it, and should improve things considerably. Further optimisations might be necessary but will be harder wins for the most part I would think. Still, I should look into Python profilers as there can often be unexpected and easily fixed sources of these problems.

I'll try to do the basic improvement of caching the parsing results today and try to see how it affects building the docs for your project.

Cheers,
Mike

from breathe.

michaeljones avatar michaeljones commented on June 12, 2024

Hi,

I've pushed some changes to help with this. Should improve things quite a bit.

It certainly did on your non-expanded docs branch but when I tried the expanded docs branch there were a couple of typos on lines 278-280 in conf.py (a few extra commas) which I fixed but then it started failing on CDomainHandler code which might well be a flaw in Breathe but I don't have time right now to investigate further.

Let me know if you think it is something I need to look at.

Hope the improvements help a bit. The end result for non-expanded was that it was parsing about 114 xml files where as before it was parsing the same files a total of ~2300 time in all. A bit better!

Cheers
Mike

from breathe.

mbolivar avatar mbolivar commented on June 12, 2024

Thanks for the quick work!

I'll try this out later tonight and let you know how it goes.

from breathe.

mbolivar avatar mbolivar commented on June 12, 2024

Hi,

Just a quick update. I did try it out, and it does indeed go way faster, but I had a couple of other issues building the expanded docs that I didn't have time to diagnose further, and I'm a bit busy for the next couple of days. I'm looking forward to testing this out further over the week, however. Thanks again!

from breathe.

michaeljones avatar michaeljones commented on June 12, 2024

Thank you for the update mate. Kind of you to take the time. I do like to hear how these changes work out!

Good luck finding the time to play with it.
Michael

from breathe.

mbolivar avatar mbolivar commented on June 12, 2024

Hello again,

I'm back to close this issue after a long hiatus. I'm pleased to report that michaeljones/bcf6aef3bc67030733dd (today's master) is speedy and works well enough for the following ~1700 "doxygenfoo" directives to compile quickly and without too much incident:

leaflabs/leaflabs-docs@9312329

Thanks again for your hard work on Breathe!

from breathe.

michaeljones avatar michaeljones commented on June 12, 2024

Thanks for dropping back to close that. Much appreciated.

I'm happy it is performing better for you now. It was definitely an easy win to put in some caching, further improvements might require some profiling but hopefully that won't be needed for a bit.

Thanks again,
Michael

from breathe.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.