Cherry-pick of #3157