This Week In Veloren 84

4 minute read 07 September 2020

This week, lots of small updates were made. Airshipper 0.4.0 was released! We take a look at a photo gallery of what has been going on.

- AngelOnFira, TWiV Editor

Contributor Work

Thanks to this week's contributors, @xMAC94x, @imbris, @DoctaRay, @TheThirdSpartan, @zesterer, @notoria, @Pfau, @Sharp, @Capucho, @termac, @law4x, and @scottc!

The August edition of the Rust Gamedev Newsletter is out! We also hit 5000 commits on our Gitlab repo! We also have 5000+ members on our Discord, and most importantly, less than 450 crate dependencies!

@Capucho got the new server-cli merged and it is working on the WGPU branch. @TheThirdSpartan worked on personalizing chat messages, and added more detailed death messages. @Pfau interacted a lot with the active players to see what could be improved in the short term. Hopefully, these can be addressed in the next few weeks.


@zesterer has been working on improving the developer workflow surrounding sites. He wants to make them faster to generate, and more accessible to other devs. @Sam created a system that can handle beam-like attacks. He and @Slipped are doing some research on how to implement keyframe animations. More on this in the coming weeks. @DoctaRay refactored how fullscreen toggling works.

Compilation Breakdown by @AngelOnFira

I was reading an article about speeding up Rust compilation. It then led me to another article that was more specific to visualizing how fast Rust compiled your program. In the context of Veloren, this could be quite useful. We are dependent on over 500 crates, and clean builds take often around 20 minutes on most computers. A breakdown of what takes the longest could help improve compile times.

This particular visualization came from just adding -Z timings to cargo build. Specifically, cargo +nightly build -Z timings. Nightly is required, as it is an unstable feature. This creates an HTML file that you can open in the browser. You can download it here if you'd like to take a look at it yourself. If you want to read more about the timings flag, you can read the documentation on it

Input information

Above is some of the preliminary information. We can see what binaries and libraries we're building by default. We can also see how many items have to be compiled from scratch, the "dirty units". I'm using a CPU with 16 threads, so the total compile time is significantly lower than what we would see on our CI runners, or other contributors' computers.

Unit compilation timeline

Next, I took a look at all of the individual compile jobs that took more than 13 seconds. Most jobs take significantly less, so this only shows the 27 most impactful of the 509 jobs. veloren-voxgen is a good benchmark to look at, as it's the final unit that has to link any previous dependency units. This cannot be done concurrently. Anything that approaches the amount of time veloren-voxgen takes should really be looked into.

Looking at this graph, we also see that each job has a blue section and a purple section. The purple represents the amount of time that a unit is spending on codegen. The blue is the rest of the time, presumably waiting for dependencies to be ready.

Here we have another breakdown of the timing of each unit. We can see how much time it took just for codegen, as well as the features it was compiling.

Finally, we can see a graph of CPU usage over the entire process.

Happy Birthday to @Gemu this week! See you next time!

Support our devs!

Veloren Open Collective

@Pfau: Patreon

@Songtronix: Patreon

@YuriMomo: Patreon

@xMAC94x: Patreon

@Acrimon: Patreon