Résumé : The aim of this dissertation is to investigate the role of optimization in the automatic modular design of control software for robot swarms. One of the main challenges in swarm robotics is to design the behavior of the individual robots so that a desired collective mission can be performed. Optimization-based design methods utilize an optimization algorithm to search for well-performing instances of control software. In optimization-based design, past research has mainly focused on proving the feasibility of optimization-based design methods for given missions. With this approach, researchers could tackle a wide range of missions. However, only a few works compare the role of the components of any chosen optimization-based design method. In particular, very little attention has been devoted to the optimization algorithm, arguably the central element in optimization-based design. In the context of my research, I focused on automatic modular design, an optimization-based design approach that combines modules into higher-level control architectures. Automatic modular design has shown to produce control software that not onlyperforms well in simulation but that also transfers well into reality.In this dissertation, I present a study of different types of optimization algorithms: local-search, model-free racing, and model-based. I defined three automatic modular design methods and compared them against state-of-the-art methods from the literature. I assessed and compared these design methods in experiments for several missions, both in simulation and on real robots. In particular, I showed that, while the choice of the optimization algorithm has an impact on the performance of the generated control software, it appears to not compromise the ability to cross the reality gap satisfactorily.The work presented in this dissertation represents a first step towards systematically investigating the role of optimization in optimization-based design. More work is still needed to further our understanding of it.