Stocks are set to wind down the worst first half since 1970 in the week ahead, but the market could bounce as big investors adjust their asset allocation ahead of quarter end.