optimize my_idamax
modify: use volatile to prevent optimization in time/compare1
a>b is not !(a<=b) for floating point number
optimise