How to properly bisect Julia's git history in search of bugs?

I noticed that current nightly is slower to import packages than 1.7.1. Julia is easy enough to compile from scratch, so I tried to use git bisect to find when that happened. Naively I tried bisecting between v1.7.1 and master but the bisecting commit was at a location where Julia was broken (Julia compiled, but package precompiles/imports did not work).

Are there any rules of thumb of how to use bisect with julia? I did use the --first-parent flag in the hope of checking only merge commits, not descending into some arbitrary commit midway through a pull request. I think a mistake I made is to use v1.7.1 as it is branched out away from the main git history, so bisect had to look at the common root. But I do not know the julia branching conventions to know where to start the bisect.

I’m not sure if this is the solution to your problem, but one thing I’ve found helps is running make cleanall before make. Especially when jumping over large numbers of commits, this helps a lot.

Also, you can bisect with HEAD~400 for arbitrary values of 400 to make sure you are looking at a linear set of commits.

1 Like

Yes, it turns out the issue has nothing to do with a broken mid-PR julia, rather it was just a dirty make. make cleanall is enough for me to successfully use git bisect now.

For those interested, it seems the slowdown is not due to any one particular thing. @time using Makie varied significantly between 1.7.1 and now, with multiple jumps in both directions.