minor modification. make MAX_ITER_NUM smaller.
can work. 5.78 seconds for 500MB data