Walking when others do is often sensible. I have walked past people who were still running, using much less effort/energy. Depends what result you want - a good time/place, or running the whole way, or at least as much as possible. I usually go for the former, though occasionally in shortish trail type fell races I will try to run the whole way, and every now and then I succeed.