Grammar and use of すればしただけ


I am having difficulty understanding this sentence. A comparison is being made
to the effect that as the cruel feeling flowed out I washed the sea water out
of the pants. But I am not sure about this. I understand that the だけ is the
equivalent of ほど. But the sentence remains unclear to me.

> そうすればしただけ、リエを泣かせた昼間の残酷な気持ちが流れ出ていくかのように、私はできるだけ丁寧に海水パンツを洗った．




This ～ば～だけ is almost the same as [the ～ば～ほど
construction](https://japanesetest4you.com/flashcard/learn-
jlpt-n3-grammar-%E3%81%B0%E3%81%BB%E3%81%A9-bahodo/) meaning "the more ～(, the
more ～)".

This そうすれば and した refer to something mentioned in the latter half of the
sentence, namely 丁寧に海水パンツを洗う. 海水パンツ (commonly abbreviated as
[海パン](https://jisho.org/search/%E6%B5%B7%E3%83%91%E3%83%B3)) is a single
phrase meaning _swim shorts_.

> そうすればしただけ、リエを泣かせた昼間の残酷な気持ちが流れ出ていくかのように、私はできるだけ丁寧に海水パンツを洗った。  
>  I washed my swim shorts as carefully as possible, thinking the more I
> washed it, the more my cruel feelings during the day that had made Rie cry
> would flow out of it.

