Discussion
Loading...

#Tag

  • About
  • Code of conduct
  • Privacy
  • About Bonfire
Simon Brooke boosted
Stewart V. Wright
@svw@fosstodon.org  路  activity timestamp yesterday

@simon_brooke

Agreed. #CommonLisp on Android ( #cl_repl) is capable and plenty fast enough on a Pixel 8a running your factorial code. 馃槑

You can make CL faster than the C/C++ used by NumPy: https://stewart123579.github.io/blog/posts/code/calculating-a-dot-product/#python-vs-dot-r-vs-dot-lisp-timing

@alwayscurious @vashti

SVW Thunk'd

Calculating a DOT product

You can get high speed, numerical calculation output without having to resort to bug-prone, highly tuned and optimised, unreadable code.
Partial screenshot with the following text:

鈥婹ML-USER [1]
(defun fact (n) "Compute the factorial o...

鈥媟eal time : 0.000 secs
run time : 0.000 secs
gc count : 1 times
consed : 654512 bytes
Partial screenshot with the following text: 鈥婹ML-USER [1] (defun fact (n) "Compute the factorial o... 鈥媟eal time : 0.000 secs run time : 0.000 secs gc count : 1 times consed : 654512 bytes
Partial screenshot with the following text: 鈥婹ML-USER [1] (defun fact (n) "Compute the factorial o... 鈥媟eal time : 0.000 secs run time : 0.000 secs gc count : 1 times consed : 654512 bytes
  • Copy link
  • Flag this post
  • Block
Simon Brooke
@simon_brooke@mastodon.scot  路  activity timestamp 2 days ago

@alwayscurious @vashti define fast. I can compute the factorial of 1,000 in under one millisecond on an ordinary laptop in several different #Lisp dialects, without optimisation.

Is that not fast enough for you?

https://gist.github.com/simon-brooke/fcb59705950c5ad515e18fba065510ae

Stewart V. Wright
@svw@fosstodon.org replied  路  activity timestamp yesterday

@simon_brooke

Agreed. #CommonLisp on Android ( #cl_repl) is capable and plenty fast enough on a Pixel 8a running your factorial code. 馃槑

You can make CL faster than the C/C++ used by NumPy: https://stewart123579.github.io/blog/posts/code/calculating-a-dot-product/#python-vs-dot-r-vs-dot-lisp-timing

@alwayscurious @vashti

SVW Thunk'd

Calculating a DOT product

You can get high speed, numerical calculation output without having to resort to bug-prone, highly tuned and optimised, unreadable code.
Partial screenshot with the following text:

鈥婹ML-USER [1]
(defun fact (n) "Compute the factorial o...

鈥媟eal time : 0.000 secs
run time : 0.000 secs
gc count : 1 times
consed : 654512 bytes
Partial screenshot with the following text: 鈥婹ML-USER [1] (defun fact (n) "Compute the factorial o... 鈥媟eal time : 0.000 secs run time : 0.000 secs gc count : 1 times consed : 654512 bytes
Partial screenshot with the following text: 鈥婹ML-USER [1] (defun fact (n) "Compute the factorial o... 鈥媟eal time : 0.000 secs run time : 0.000 secs gc count : 1 times consed : 654512 bytes
  • Copy link
  • Flag this comment
  • Block
Log in

BT Free Social

BT Free is a non-profit organization founded by @ozoned@btfree.social . It's goal is for digital privacy rights, advocacy and consulting. This goal will be attained by hosting open platforms to allow others to seamlessly join the Fediverse on moderated instances or by helping others join the Fediverse.

BT Free Social: About 路 Code of conduct 路 Privacy 路
Bonfire community 路 1.0.0 no JS en
Automatic federation enabled
  • Explore
  • About
  • Public Groups
  • Code of Conduct
Home
Login