v13 port because otherwise backports will result in conflicts always
(cherry picked from commit 14d03a9446)
14d03a9446