LPS-43952 Replace google's reverse implementation by our own