Efficient execution of large-scale application codes is a primary requirement in many cases. High efficiency can only be achieved by utilizing architecture-independent efficient algorithms and... Show moreEfficient execution of large-scale application codes is a primary requirement in many cases. High efficiency can only be achieved by utilizing architecture-independent efficient algorithms and exploiting specific architecture-dependent characteristics of a given computer architecture. However, platform specific versions of source code must be avoided to limit development and maintenance complexity. Usually, the problem can be formulated on an abstract level (mathematical equations, English). At that level, the problem is completely known, and there is no reference to the hardware on which the problem will be solved. Unfortunately, often the advantages of a high level of abstraction are overshadowed by a loss of performance compared to handwritten code. Therefore, a problem-specific code generator, called Ctadel, has been developed in order to exploit architecture-independent and dependent optimizations. We show how to extend Ctadel with more advanced numerical techniques and a interfaces to numerical libraries. A number of numerical models from Hirlam, a numerical weather prediction application in use by a number of meteorological institutes like the Dutch royal meteorological institute (KNMI) where specified using our specification language. We compared the performance of the generated program code with hand-written code. In most case, the code generated by Ctadel performs as well or even better than the hand-written code. Show less