Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Dec 11 07:59
    adam-7 commented #98
  • Dec 11 07:49
    adam-7 commented #98
  • Dec 11 07:40
    adam-7 commented #98
  • Dec 10 14:26

    feeley on clang-options

    (compare)

  • Dec 10 14:02
    Travis gambit/gambit@72b7ca2 (feeley/clang-options) passed (1306)
  • Dec 10 13:25
    feeley opened #454
  • Dec 10 13:21
    feeley closed #358
  • Dec 10 13:21
    feeley commented #453
  • Dec 10 13:20
  • Dec 10 13:20

    feeley on 64bit-stream-index

    (compare)

  • Dec 10 13:20

    feeley on master

    Allow 64 bit stream index Merge pull request #453 from ga… (compare)

  • Dec 10 13:20
    feeley closed #453
  • Dec 10 13:19
    Travis gambit/gambit@37408fa (feeley/64bit-stream-index) passed (1303)
  • Dec 10 13:18
    feeley closed #32
  • Dec 10 13:01
    svenha commented #98
  • Dec 10 12:45
    svenha commented #248
  • Dec 10 12:42
    feeley opened #453
  • Dec 10 12:41

    feeley on 64bit-stream-index

    Allow 64 bit stream index (compare)

  • Dec 10 12:36
    Travis gambit/gambit (master) passed (1302)
  • Dec 10 12:35
    Travis gambit/gambit (master) passed (1301)
amirouche
@amirouche
you don't know scheme?
ben.txt
@bentxt
I've meant the compilation process. How do you integrate the standard library? I guess 'reverse' is written in scheme and therefor should be usable for the universal backend.
amirouche
@amirouche
ben.txt
@bentxt
@amirouche thanks. does this build a library _gambit.js inside gambits source tree?
Marc Feeley
@feeley
@bentxt yes it builds lib/_gambit.js which is most of the normal Gambit Scheme library
@amirouche I've looked at your JS performance experiment... what is the Scheme code that you are compiling? factorial wouldn't be my first choice of benchmark because very soon you need bignums to compute factorials of > 20 or so
I typically use fib which exercices function calls and fixnum arithmetic and it is very easy to scale to a larger time by incrementing the argument
when you say "almost as fast as JS" do you mean compared to factorial written directly in JS or through your compiler?
John Cowan
@johnwcowan
I sometimes ask candidates if they know of an O(1) way to implement factorial. Only one or two have actually come up with the answer.
amirouche
@amirouche
@feeley ok for fib, tx for the hint. As fast as iterative factorial written in JavaScript (which is the fatest factorial compared to recursive and tail recursive)
@johnwcowan using a memo?
@feeley it is a tail recursive factorial
John Cowan
@johnwcowan
Using a precomputed array of all possible factorials that can be represented as 64-bit floats.
There are really very few.
amirouche
@amirouche
amirouche
@amirouche
@johnwcowan I missed an opportunity to look smart
John Cowan
@johnwcowan
As I say, almost everyone does.
ben.txt
@bentxt
@feeley @amirouche ok that is producing a 21M large _gambit.js file, I guess I'll try other solutions then, ... thanks anyway
Marc Feeley
@feeley
@bentxt As was mentioned before, if your application is small (you need reverse and just a few other things), then you should build your own runtime library and you will get a reasonable JS code size, especially if you minify the code. See the mentioned link.
amirouche
@amirouche
I am around if you want to discuss the issue I just posted at gambit/gambit#404
Marc Feeley
@feeley
@amirouche did you see my response? call/cc is just:
(define (call/cc f)
  (##continuation-capture
   (lambda (k)
     (f (lambda (r) (##continuation-return-no-winding k r))))))
Marc Feeley
@feeley
if you wonder about the rationale for those continuation primitives they are explained here: http://www.iro.umontreal.ca/~feeley/papers/FeeleySW01.pdf
amirouche
@amirouche
tx a lot!
I think I have all i need :)
Marc-André Bélanger
@belmarca
> (##include "~~lib/_std#.scm")
*** ERROR IN "/usr/local/Gambit/v4.9.3/lib/_std#.scm"@11.2 -- Unbound variable: define-library-type-of-exception
Marc Feeley
@feeley
(##include "~~lib/_gambit#.scm")
Marc-André Bélanger
@belmarca
😣thanks
amirouche
@amirouche
use TAB + ENTER or click TODO to validate input
Marc-André Bélanger
@belmarca
13kb for everything amirite?
amirouche
@amirouche
amirite?
Marc-André Bélanger
@belmarca
"am I right" :)
amirouche
@amirouche
where do you see this number?
it is at least 1Mb if you count only JavaScript depedencies, and that is the helpers.js that contains ReactJS
Marc-André Bélanger
@belmarca
chrome says about 1.2Mb for everything
ok
amirouche
@amirouche
yeah it looks like that
I am wondering if I will not continue with the full build because not having access to string function is rather painful
until the tree shaking code lands in master...
even if it is 21M, it much less than pypyjs which IIRC is 60Mb also in local dev setup, you are not really slow down by the big size of the runtime.
amirouche
@amirouche
Actually pypyjs is 31Mb but split into many files which slows down the page a lot: https://hyperdev.fr/pypyjs-todomvc/
Marc-André Bélanger
@belmarca
can't you "JS FFI"?
Marc-André Bélanger
@belmarca
like a thin wrapper for these functions only
Phiroc
@Phiroc
hello, does anyone know how to access the iCloud filesystem on iOS from the Gambit-powered "Not Emacs" editor on iOS? Furthermore, is there an "ls" or "pwd" command of some sort? Many thanks.
amirouche
@amirouche
@belmarca there is a way to "JS FFI" but string representation in Gambit is different from the JavaScript one
nymacro
@nymacro
What is the approved solution to re-loading an compiled object? I am putting Geiser's new Gambit integration through its paces, but have stumbled on a couple little annoying things based on interactive use
nymacro
@nymacro
I am currently using (load "blah")
Bradley Lucier
@gambiteer
The only way I know is to recompile it.
Marc-André Bélanger
@belmarca
@amirouche but what you produce is a .js file?