Programming Languages are not slow, Implementations are
Applications are mere implementations of software and runtime is a by-product of the compiler. Arguing about how fast is a programming language is a common mistake and one that the industry keeps repeating. In this newsletter, I explain why that is a very shallow argument to look at language performance metrics and then decide based on that.

Static vs Dynamically Typed Languages
Dynamically typed languages no matter much they are optimized are slower than statically typed languages. Because by nature they are interpreted each time rather than compiled languages that are translated to binary or close to binary only once. So whenever you run an application that is dynamically typed, it has to perform compilation (interpretation can be viewed as something similar to compilation) and then run the application every single time. But does this slowness matter to you? That is a different question altogether.
Compilers
Compilers are incredibly complex software. Innovation is happening every day where new languages + runtimes try to match programmer productivity and runtime speed that is required by the industry. Let’s take Python as an example. It has multiple different compilers/interpreters.
CPython - Default compiler
Cython - Compiles Python to C
IronPython - Compiles to .NET CLR runtime
Jython - Compiles to the JVM
And more recently there is Graalvm. All of these have different performances for different reasons. IronPython and Jython are more used to integrate with libraries in the .NET or the Java world. Cython is used by many libraries which require CPU-intensive/performant code. One such library is spaCy which uses Cython code to be really fast. In all of these runtimes, the language i.e python does not matter as the runtimes are different.
Design
Regardless of the language, if your application design is not right then it will be slow. Examples -
If your data model is not right and you do unnecessary joins then the aggregate performance of your application will slow down.
Incorrect indexes/Missing indexes can slow down your app.
Not using the appropriate data structure/algorithm can significantly slow down your application.
These are just the common ones. It is important to have proper design regardless of what language you use.
Hardware
For most applications, commodity hardware works fine. But specialized apps require specialized hardware. Machine learning apps work well with GPUs rather than CPUs. Certain CPUs work better than others.
Conclusion
There are a lot of other factors that contribute to the speed of a programming language. The language itself does not matter much as it interfaces more with a developer rather than the machine. For the majority of the applications, any modern programming language would do fine. But there are other practical aspects like
Ease of learning.
Ecosystem/Libraries.
Availability of developers.
Licensing.
and a lot more. Maybe that’s for another post but the point to drive home here is that the speed of a programming language mostly does not come in the way unless there is a specialized application we are developing. There are a lot of other factors that need to be evaluated individually.