DEV Community

Discussion on: The Peregrine programming language - A Python-like language that's as fast as C.

Collapse
 
gaggerytsai profile image
GaggeryTsai

.. Python could resolve the performance issue with @lru_cache for the memorization to improve the example of Fibonacci. It is matter of memory consumption. That would be great if you can show both the performance and memory consumption comparison between Python and Swallow for this example to show case how good the Swallow language is. Otherwise I doubt Swallow is using more memory.

Collapse
 
saptakbhoumik profile image
SaptakBhoumik

Well using @lru_cache will be cheating. If you run a multithreaded python program and a simgle threaded c program then it is very likely that python will win