5 ms·
I didn’t know compiler farms were a thing, but it makes perfect sense. During university, our computer security class involved finding exploits in Firefox. It
by alephnan 5y ago
I didn’t know compiler farms were a thing, but it makes perfect sense.
During university, our computer security class involved finding exploits in Firefox. It took 8 hours to compile on our average student grade compute. There were probably faster incremental ways to build, but navigating the Firefox open source code base was hard to entry point as a student. Effectively, most people got to compile Firefox a few times, but no one went further than making any code changes or discoveries. Navigating the Firefox build and tool chain is probably an undergrad course in and of itself, much less make any meaningful merge request or finding a vulnerability.
Overall, horribly designed curriculum. The expectation was for undergrads to find a zero day in Firefox. The professor was a researcher from Microsoft, but didn’t seem like he had realistic expectations for undergrads. Maybe they were throwing darts, hoping one student finds an novel exploit, and they can be cited. In the end, no student found an exploit or made any code changes. I was the only who found a DoS code payload for Firefox, but it was neither a zero day (poking around a known less developed API) nor high risk. It merely crashed Firefox on any webpage which contained this 2 lines of JavaScript. In the end, I got the lowest grade in the class because the professor changed the rubric after no one else found anything. Finding this exploit went from 80% of the grade to 5%, and participation credit went from 10% to 70%.
- pabs3 5y agoA couple of tools to make compile farms easier to use: https://distcc.github.io/ https://distcc.github.io/ https://github.com/icecc/icecream https://github.com/icecc/icecream
- lloydatkinson 5y agoWow that sounds like a really frustrating and demotivating experience. Seems totally ridiculous and beyond any realistic expectations - I’m surprised nobody involved didn’t raise concerns. I had a similar but not as bad experience. The lecturer was brand new and wanted us to design a programming language after a single vague PowerPoint and the worst introduction to yacc or lex or whatever they are. We were also undergraduates. After several weeks of complaints he provided an example language and parser etc. Still it was simply too hard and in the end nobody could do it. I believe I managed to add a minor feature to his example language as my submission. I managed to get a reasonably high grade simply because I freely admitted I struggled with the entire task but could explain language theory and made comparisons with other languages I know and what features I would have added if I could. Some people totally wrote that whole module off and planned around the scoring system where one failed module in a year would just be discounted and an averaged score created.
- coldtea 5y ago>Wow that sounds like a really frustrating and demotivating experience. Seems totally ridiculous and beyond any realistic expectations What, the 3 hour compile time? That's an OS+utils, there are projects that take more... Ever tried compiling QT+KDE?
- pjmlp 5y agoBack in the SuSE 6.3 days that would take a whole night.
- brimble 5y agoOld Gentoo user chiming in. My "I won't be using my computer today" builds were either major desktop environment (or anything that forced me to rebuild the GTK or QT shared libs), and... OpenOffice. Good lord, that one took forever. Firefox probably came next after those.
- mindentropy 5y agoOh man I was a Gentoo user once. That was funny and brought a lot of memories back. I was building KDE from source and it took 1.5 days to build I think lol.
- joezydeco 5y agoTry Yocto with Qt. Ugh. I have a 48-core server just for this task.
- jcelerier 5y agoHow are you building your Qt ? I just tested on my machine (i7-6900k, 8C/16T from 6 years ago), building 5.15: qtbase, qtdeclarative, graphicaleffects,multimedia,quick controls2, serial port, svg, wayland and websockets takes 8 minutes total... it's hardly the end of the world and that's already more than needed for 99.9% of Qt apps. And I don't even use ccache. make -j16 5343,12s user 307,95s system 1198% cpu 7:51,67 total here's my configure line: ~/libs/qt5/configure -nomake tests -nomake examples -debug -confirm-license -opensource -platform linux-clang -linker lld
- gjvc 5y agohttps://ccache.dev/ https://ccache.dev/
- actionfromafar 5y agoSounds like a pretty good simulation of the corporate workspace, though! I'm sure it was not intentional at all, but it is pretty funny. Complete with lower pay (or at least less career opportunities) for working extra hard on the Death March project about to be cancelled.
- cryptos 5y agoYou name it! Most of the code I've written in my carrier was for projects eventually canceled.
- fao_ 5y agoI'm kind of surprised there was no code caching. I compiled the linux kernel on an X200 in the last year or two and essentially there was a wait of 1 - 3 hours for a minor change. 3 hours if you build from scratch, 1 hour if you do a minor change and rebuild. It was excruciating and the machine ran hot, but I'd be surprised that it took 8 hours for a rebuild, after building the first time, unless you are literally destroying all of the build artifacts and rebuilding from scratch, every single time.
- anthk 5y agoccache.
- fao_ 5y agoI mean, sure, I guess you can do that. But a basic Makefile does this too. So does every other build system on earth.
- gjvc 5y agoYou have completely missed the point of what ccache does and how it works.
- humanrebar 5y agoA tool like ccache will work across multiple workspaces, unlike Makefile. You can prewarm it with an overnight cron job. And in some configurations, you can share it across the organization.
- chakkepolja 5y agoSounds like my college where teachers expected us to use ML or blockchain in DBMS and Networks projects, just throwing darts so that they can turn something into a paper.
- mdaniel 5y agothis whole thread reminds me of the blog where someone used AWS Lambda as a pseudo-distcc to compile LLVM in 90s: https://blog.nelhage.com/post/building-llvm-in-90s/ https://blog.nelhage.com/post/building-llvm-in-90s/