Sheet.getMergedRegions() was added in POI 3.13 for bug 57893, which has O(n) running time. Prior to this, functions used a for-loop around Sheet.getMergedRegion(i), which had poor performance on both HSSF and XSSF. SheetUtil and perhaps other files haven't been updated yet to use the more efficient code.
Correction: only XSSF had an O(N^2) cost using [Sheet.getMergedRegion(i) for i in range(Sheet.getNumMergedRegions())]. HSSF internally stores merged regions as a list, Added in r1716362. This change is internal to POI and shouldn't affect users of POI.