|
|
|
|
|
by bdbenton5255
385 days ago
|
|
It does, actually, as the syntax is a result of the language's design and a simpler and more human-like syntax requires a higher level of abstraction that reduces efficiency. The design of a language, including its syntax, has a great bearing on its speed and efficiency. Compare C with Assembly, for example, and you will see that higher level languages take complex actions and simplify them into a more terse syntax. You will also observe that languages such as Python are not nearly as suitable for lower level tasks like writing operating systems where C is much more suitable due to speed. Languages like Python and Ruby include a higher level of built-in logic to make writing in them more natural and easy at the cost of efficiency. |
|
JAX and Triton compile your python code to incredibly fast GPU kernels. If you want to run pure python, then there are JIT based runtimes like Jython or PyPy that run your code faster.
What it boils down to is the fact that CPython is an incredibly slow runtime and CPython dominates due to interoperability with C extensions.
I don't know why, but I've seen a lot of people act as if the C language is some kind of voodoo thing as if C being fast is due to mere superstition. "Everyone knows C is the fastest, therefore C is the fastest" What you're doing is the equivalent of reading tea leaves or horoscopes or being an audiophile.