I imagine it’s about checkpointing the calculation as it’s very long.
Point is, if the system crashes, you want to be able to resume the calculation without losing too much progress, so you want to periodically write progress to disk.
That takes some CPU cycles away from the calculation, and if your disk driver is inefficient, it will take away more.
The question did too, it isn’t immediately apparent why you’d write to disk to calculate pi if you haven’t worked in a place that churned a lot of numbers before.
I imagine it’s about checkpointing the calculation as it’s very long.
Point is, if the system crashes, you want to be able to resume the calculation without losing too much progress, so you want to periodically write progress to disk.
That takes some CPU cycles away from the calculation, and if your disk driver is inefficient, it will take away more.
AHH ok yeah that does make some sense.
The question did too, it isn’t immediately apparent why you’d write to disk to calculate pi if you haven’t worked in a place that churned a lot of numbers before.