September 9, 2016
This year, the FreeBSD Foundation sponsored my first trip to the University of Cambridge FreeBSD DevSummit (BSDCam). August is a great time to visit and the folks at Cambridge are doing amazing projects.
My goal for this trip was to engage some of the Clang/LLVM developer community to work towards a Clang/LLVM enabled build of FreeBSD MIPS64. This is work that I’ve been pursuing for a few months in an effort to remove one blocking item from the base system’s eventual removal of GNU GCC.
Getting to Cambridge is quite a journey. Flying to the UK from the USA is always a bit of a journey, followed by an Underground trip to King’s Cross Station. Getting a train to Cambridge is quite easy, however I would recommend spending more than 30 seconds figuring out which one to use. I spent a lovely two hours visiting every stop between London and Cambridge. There are quicker routes, so ask around instead of leaping on the train that has a “Cambridge” in its destination marquee.
I stayed at the provided accommodations on Churchill College. The modern art collection is ridiculously good. Spend some time walking around the buildings, you’ll find it worthwhile.
Day 1 of the Devsummit (and the rest of the days) was held in the William Gates building of the computer laboratory and we had many, many things to discuss.
I participated in the “Energy Awareness” discussion in the morning. The ARM developers present were very interested in trying to understand the state of FreeBSD power management. It was very apparent from our discussions that there is no generic framework available in either power management or hooks into the process scheduler to utilize better power management process scheduling (no attempts to schedule processes on CPUs that are powered off, for example). The discussions were archived on the FreeBSD wiki.
I was able to interact with Ruslan Bukin regarding his work in the RISC-V support currently available in FreeBSD. We collaborated on creating a few FreeBSD ports for emulators that are currently in review to assist in the development of RISC-V.
The second set of ports for RISC-V support were to enable a GCC toolchain for development. This also led to a long interaction with Mathieu Arnold regarding how to deal with github’s concept of external projects being included in a base project. In the end, Mathieu surprised me with a review to deal with it! That’s the best part, in my opinion, of being able to be in a room with developers on our project, just getting problems solved that may or may not be in your specific area of expertise.
After a dinner out on Day 1, Day 2 was filled with even more very knowledgeable people talking about things that were important to them. I participated in the morning session with regards to toolchains. We very narrowly missed discussing what “tiers” mean in FreeBSD, as this tends to go off into discussions that aren’t related to toolchains!
As far as highlights, we were given updates on the impending LLD use as a replacement for GNU binutils, identified that we have a MIPS64 toolchain in our base system that doesn’t correspond to anything in GNU binutils upstream and properly noted that SPARC64 support in our systems is for machines that were EOL’d by Sun/Oracle in 2008.
I very narrowly dodged the FreeBSD Tracing discussion meeting that appeared to be the highlight of the Developers Summit for a lot of people. The interest in application and functional testing seemed very high and the notes from the discussion are well worth an overview.
Sitting down with Alfredo Mazzinghi on Day 2, we spent a bit of time trying to determine what was still needed with regards to booting a LLVM/Clang compiled version of FreeBSD MIPS64. We noted using QEMU that the output assembly was odd. We didn’t make much progress here, but I was able to communicate the patches to LLVM/Clang that are required to build FreeBSD MIPS64.
The results of the debugging session were sent along to some of the folks who work on LLVM/Clang for Imagination Tech. The result of which was a few updates to the LLVM/Clang toolchain that finally resulted in a booting FreeBSD MIPS64 kernel when compiled with an external compiler. I will be publishing a few FreeBSD system updates and commits for review to add another architecture to our build system that works with a non-GNU tool set. Removing our dependency on the base system GCC 4.2.1 has been a priority of my work in assisting the build of Tier-2 packages.
I spent most of Day 3 discussing and demonstrating the QEMU bsd-user cross build environments for packages. There was some interest in doing this for the Cheri backend developed at Cambridge. I feel like we’ve done a bad job of advertising the cross-build environment utilizing QEMU bsd-user as an aid in porting and development of non-x86 architectures. The folks who were present were interested in the techniques, and the live demo went over well.
This FreeBSD Developer’s Summit is growing in importance for the project. It allows the folks who work in industry (myself included) a good opportunity to interact with the folks in academic research areas and perhaps solve some of each other’s issues.