Bumpy ride in loiter (and several crashes)

I update my firmware to day because I had earlier problem that every time when I switch to loiter after aggressive flying in stabilize mode it will shoot to sky or drop like rock.

Now it works almost well but it give quite bumpy ride in loiter mode. Motors react really aggressively to something but I don’t find what and why. Result of aggressive throttle bumping cause that altitude accuracy is ~10m in short term by log and by eye it looks that it can be even worse.

It is possible that this is now just incompatible tunings with new software but if someone more experienced person can watch that log and give hint where I need to start re tuning it would be nice.

In log it is clearly visible in loiter mode that something triggers that it give lot of throttle and that cause expected peak in accl and copter starts climb. But I dont find what sensor and pid cause that throttle peak in first place.

I start loose my faith to 3.0.x firmware altitude hold. Crash after crash. I have now crashed 5 times my copter because that altitude hold just does not work. I have tried tune it many ways and looks that nothing helps. Lastest crash was that it just drop from sky when I turn loiter on. Some times when I turn it on it shoots to sky and some times it just drops. There is sample when I was so lucky that it start goes up youtube.com/watch?v=A3I8yUKRYs4

There is same kind episode when I switch loiter on but that time I had FPV goggles and I was very near sea so I over react and drop it down before it fly to over sea. youtube.com/watch?v=ui6m9f7wZUs

And today I was not give even change to me because that time it want go down in same second when I switch loiter on:

So after aggressive flying in stabilize mode or drift mode copter will shoots to sky or drop to ground if you enable mode what include altitude hold. In older firmware that can cause if copter is moving fast but looks that after 3.0.x copter needs settle down quite long time or you hit to “bug”.
My guess is that it does not read reset value for target altitude form proper place or it will update altitude hold pids also on stabilze mode but does not reset them when you change to altitude hold -> PID output is so way off in start that it does not have time to fix them. That is just guessing but fact is that there is something seriously wrong in altitude hold!

In latest 2.9.x series firmware that altitude hold was pure gold. It just works. But problems starts in 3.x series and with several different version of software it is just generally poor in flight and random generator when you switch is on. I am sorry but I must call that total failure of rewriting.
If we compare that to earlier videos youtube.com/watch?v=Hj-kYdRaemo even in very strong wind that old altitude hold was quite stable.

Edit: I add log of that latest crash and also image of log where we see that some reason copter thinks that it is in steady climb even it is not.

Hmm looks that accl is out of calibration again. In that lastest log it shows most of time negative value for AccZ That maybe cause that drop. I dont know why it does not affect in first loiter session and mostly I dont know why it is offset again.

I think it would be good idea to make pre arm check what warn if sum vector of accelerometers does give zero when you try arm your copter. That allows you to start flight from non flat surface but it does not allow you take of if your sensor is out of calibration.