4 ms·
I wonder if I can use this to learn a large c++ codebase like Chromium. One of the issues I had trying to learn chromium was that in order to play and experimen
by bobajeff 2y ago
I wonder if I can use this to learn a large c++ codebase like Chromium. One of the issues I had trying to learn chromium was that in order to play and experiment with their classes/functions I needed to spend several minutes to link my little test code with their static libraries just to be able to see if my understanding of them was correct. Which is just too long of time for such experiments so I gave up.
- hackit2 2y agoLast time I checked out Chromium code base it was about 300-400 Megs of uncompressed cpp files. Lets not also forget the fact you also needed to run some code generator script that generated another 200 Megs of DOM files, or interface files. At that point in time I gave up and went to sleep and never touched it again.
- lioeters 2y agoI really hope Ladybird is able to stay relatively small and approachable, it would be wonderful to have as a truly customizable open-source browser that's not a massive codebase that takes forever to compile and develop.
- hackit2 2y agoI do think there are some geniuses working on the Chromium code base, and I would imagine there are really good reasons for doing it their way. I would imagine also Ladybird over time will face the same problems, and come up with similar solutions as Chromium team. All I know is most of the large scale C/C++ code bases eventually become these monolithic giant code bases that require some really specialised software tools to compile and link.
- pjmlp 2y agoNot only C and C++, I have seen this scale with most Fortune 500 projects I have been involved.
- pragma_x 2y agoI agree on all fronts. This parallels the last time I looked at, and gave up building a backend for LLVM. And that was after giving up doing the same for GCC. Those codebases are _impenetrable_. It's clear as mud how one would hook a jumbo codebase into the REPL. If it's possible, that would be a game changer.
- jcelerier 2y agoI added LLVM JIT support to https://ossia.io https://ossia.io a few years ago, it's not too bad, but a big issue is that the JIT does not support all the necessary features used by the frontend in terms of relocations, etc. So it happens relatively often that C++ code will compile to LLVM IR without issue, but then fail at the JIT step because some relocation is not supported by the JIT engine yet. Most of the code is here : https://github.com/ossia/score/tree/master/src/plugins/score-plugin-jit/JitCpp https://github.com/ossia/score/tree/master/src/plugins/score... with the actual LLVM API interoperation contained there : https://github.com/ossia/score/tree/master/src/plugins/score-plugin-jit/JitCpp/Compiler https://github.com/ossia/score/tree/master/src/plugins/score... It's been used for fun projects, for instance for this paper about data sonification : https://www.researchgate.net/profile/Maxime_Poret/publication/374732205_Proof_of_Concept_of_a_Generic_Toolkit_for_Sonification_The_Sonification_Cell_in_Ossia_Score/links/65eeb38a9ab2af0ef8aec1b1/Proof-of-Concept-of-a-Generic-Toolkit-for-Sonification-The-Sonification-Cell-in-Ossia-Score.pdf https://www.researchgate.net/profile/Maxime_Poret/publicatio...