3 ms·
You are not wrong, but the original point was that GDScript is slow because its syntax is similar to Python's and Python is slow. That just doesn't make any sen
by alpaca128 6y ago
You are not wrong, but the original point was that GDScript is slow because its syntax is similar to Python's and Python is slow. That just doesn't make any sense.
> The default language in the engine is basically python, so it could cause a performance bottleneck.
- follower 6y agoAh, I didn't notice that detail of the discussion, thanks. If "basically python" means "scripting language" vs "C++" then I can see why by that standard "performance" could be a concern to someone. But, yeah, doesn't seem to be a Python/GDScript specific concern.
- shoo 6y agopython is slow because the extreme flexibility of the language makes it very difficult for compilers/interpreters to perform analysis that could allow optimisations this doesn't have anything to do with the syntax. we could completely replace python syntax with e.g. pyc bytecode or serialised AST data but the language would still be challenging to execute efficiently as the language is still exactly the same one can get a few ideas of how python could perhaps be made faster by reading about all the restrictions that rpython imposes https://rpython.readthedocs.io/en/latest/rpython.html https://rpython.readthedocs.io/en/latest/rpython.html