Agile But Safe: Learning Collision-Free High-Speed Legged Locomotion