c.1300, "space, area, extent, circumference," from Old French compas "circle, radius, pair of compasses" (12c.), from compasser "to go around, measure, divide equally," from Vulgar Latin *compassare "to pace out" (source of Italian compassare, Spanish compasar), from Latin com- "together" (see com-) + passus "a step" (see pace (n.)).
The mathematical instrument so called from mid-14c. The mariners' directional tool (so called since early 15c.) took the name, perhaps, because it's round and has a point like the mathematical instrument. The word is in most European languages, with a mathematical sense in Romance, a nautical sense in Germanic, and both in English.