Using soft-core processors on FPGAs offers the opportunity to customize the system design in order to accelerate the application. While this has always been possible manually by hardware designers, it requires distinct knowledge of design methods and of the microarchitecture of the soft-core. In this paper we show that a mature compiler like the GCC can be used for automatic generation of processor customizations directly from the C code of the application. To this end, we have extended the GCC to automatically select candidate sequences of the whole application and transform them into hardware extensions.