By the early 9th century, the efficient administration of Charlemagne's Empire was ensured by high-level civil servants, carrying the, then non-hereditary, titles of counts (in charge of a County), marquis (in charge of a March), dukes (military commanders), etc. During the course of the 9th and 10th centuries, continually threatened by Viking invasions, France became a very decentralised state: the nobility's titles and lands became hereditary, and the authority of the king became more religious than secular and thus was less effective and constantly challenged by powerful noblemen. Thus was established feudalism in France. Over time, some of the king's vassals would grow so powerful that they often posed a threat to the king.