I think you’re right!
In your example the last 36 minutes could be done without exclusive locking.
What exactly is your use case? Do you want to minimize the time the repository is exclusively locked? The reduction of pruning time is actually work in progress (I made an PR to improve this a lot). This might already help in your specific use case (as soon as the PR is reviewed and merged).