[#25, #27] use array summary for calculating CPI and SPI instead of hash last