What does "to do so" refer to in the following sentence:
Although these ambiguities formed a backdrop to the heated debates in the formulation of the WDR, the real controversy concerned the role of institutions: did they “fill in” for market failures, or did they often help to preserve existing inequalities, frequently giving rise to inefficiencies in the attempt to do so?
Development economics through decades, by Shahid Yusuf (2008), p. 147