CPS Update

2013-02-15 Thread Noah Lavine
Hello, The wip-rtl-cps branch has been rebased again (on top of wip-rtl). It now includes support for toplevel references and sets, thanks mostly to Andy's work on supporting them in RTL. (Although you shouldn't kick that part of it too hard just yet; I think I know where it will break.) Other

Re: CPS Update

2013-02-16 Thread Noah Lavine
features going. After that I would definitely like define* and lambda*. Noah /Stefan On Sat, Feb 16, 2013 at 1:53 AM, Noah Lavine noah.b.lav...@gmail.com wrote: Hello, The wip-rtl-cps branch has been rebased again (on top of wip-rtl). It now includes support for toplevel references

Re: CPS Update

2013-02-16 Thread Noah Lavine
Hello, On Sat, Feb 16, 2013 at 2:14 PM, Mark H Weaver m...@netris.org wrote: Noah Lavine noah.b.lav...@gmail.com writes: Oh, you're right. I was thinking about that because I don't run the Tree-IL optimizers when I test it, so I don't get any Tree-IL primitives. I think you should

RTL Call Issue

2013-02-18 Thread Noah Lavine
Hello, I've hit an interesting issue in the RTL call instruction. I find that I can't execute a call instruction where the return frame starts at the same place that the procedure to call is at - it must start past there. That doesn't match my expected behavior, but I'm not sure if my

Re: propose deprecation of generalized-vector-*

2013-02-18 Thread Noah Lavine
On Mon, Feb 18, 2013 at 11:25 AM, Mike Gran spk...@yahoo.com wrote: From: Noah Lavine noah.b.lav...@gmail.com I haven't worked with the array functionality, so I might be missing something, but I don't see why this is natural for array-ref. One could imagine a Matlab-like syntax where

Re: [Guile-commits] GNU Guile branch, wip-rtl-cps, updated. v2.1.0-180-g0d0808a

2013-02-19 Thread Noah Lavine
need boxes. (But it will be able to soon!) Noah On Tue, Feb 19, 2013 at 12:53 AM, Mark H Weaver m...@netris.org wrote: Hi Noah, Noah Lavine noah.b.lav...@gmail.com writes: commit 0d0808ae3f7390ffb250b9deb6706ad4158cce0e Author: Noah Lavine noah.b.lav...@gmail.com Date: Mon Feb 18 14

Re: [Guile-commits] GNU Guile branch, wip-rtl-cps, updated. v2.1.0-180-g0d0808a

2013-02-19 Thread Noah Lavine
Oh, and thanks a lot for reviewing the CPS stuff! I really appreciate it, and I think it will make the end result a lot better than whatever I could do on my own. Noah On Tue, Feb 19, 2013 at 9:28 AM, Noah Lavine noah.b.lav...@gmail.comwrote: Hello, Yes, I completely agree with this. I

Re: CPS Update

2013-02-19 Thread Noah Lavine
Hello, On Sat, Feb 16, 2013 at 4:18 PM, Mark H Weaver m...@netris.org wrote: Hi Noah, On Sat, Feb 16, 2013 at 2:14 PM, Mark H Weaver m...@netris.org wrote: [...] Noah Lavine noah.b.lav...@gmail.com writes: You mean if a function modifies another function that called

Re: [Guile-commits] GNU Guile branch, wip-rtl-cps, updated. v2.1.0-180-g0d0808a

2013-02-19 Thread Noah Lavine
Hello, On Tue, Feb 19, 2013 at 11:03 AM, Mark H Weaver m...@netris.org wrote: Hi Noah, Noah Lavine noah.b.lav...@gmail.com writes: Yes, I completely agree with this. I didn't do that immediately because I'm trying to get the infrastructure for the general case working. I plan

CPS Organization

2013-02-20 Thread Noah Lavine
Hello, I just pushed a somewhat big commit to the CPS branch. It didn't have much content, but it moved register allocation to its own file. It also tries to move in the direction of making logically separate operations into their own passes, which Andy wanted. I think it's mostly good, but I

Re: propose deprecation of generalized-vector-*

2013-02-21 Thread Noah Lavine
Hello, On Wed, Feb 20, 2013 at 8:13 PM, Daniel Llorens daniel.llor...@bluewin.chwrote: On Feb 18, 2013, at 16:55, Andy Wingo wrote: It could make sense, yes. What do others think? What happens for array-set!? Care to propose a patch? Patch is attached. It looks a bit unwieldy

Re: Programming racket like in guile

2013-02-23 Thread Noah Lavine
That makes sense, but if the promotion ever happens, then there might be a bunch of old code using (compat racket ...) that would need to be converted, and we would have to keep the (compat racket ...) modules around for compatibility with old code. If there's any possibility that we will want to

Re: Programming racket like in guile

2013-02-23 Thread Noah Lavine
Hello, On Fri, Feb 22, 2013 at 9:32 PM, Ian Price ianpric...@googlemail.comwrote: Daniel Hartwig mand...@gmail.com writes: For those parts specific to racket, did you consider the (language racket ..) namespace, where an eventual language definition could be placed also? That sounds

Re: propose deprecation of generalized-vector-*

2013-02-28 Thread Noah Lavine
Hello, On Thu, Feb 28, 2013 at 2:10 PM, Daniel Llorens daniel.llor...@bluewin.chwrote: On Feb 22, 2013, at 01:22, Noah Lavine wrote: I agree about the speed issue, but I hope it will get better soon. The RTL VM will fix some of it, and native compilation will fix more. That's on Scheme

Re: propose deprecation of generalized-vector-*

2013-02-28 Thread Noah Lavine
, Noah Lavine noah.b.lav...@gmail.comwrote: Hello, On Thu, Feb 28, 2013 at 2:10 PM, Daniel Llorens daniel.llor...@bluewin.ch wrote: On Feb 22, 2013, at 01:22, Noah Lavine wrote: I agree about the speed issue, but I hope it will get better soon. The RTL VM will fix some of it, and native

Re: propose deprecation of generalized-vector-*

2013-03-03 Thread Noah Lavine
Hello again, On Fri, Mar 1, 2013 at 4:01 AM, Daniel Llorens daniel.llor...@bluewin.chwrote: think this comes down to a more fundamental difference - I still don't think that functions should automatically map over arrays, and you do. If they did automatically map, then I would agree with

Re: Thread-unsafe initialization problems in Guile

2013-03-05 Thread Noah Lavine
I've only read the most recent article you posted, but if I understand correctly, there is a third option: (3) somehow find a way to generate a portable memory barrier instruction. Is that currently possible? I'm not sure that it is. Probably option (2) is best if we can do it. Noah On Thu, Feb

Re: Thread-unsafe initialization problems in Guile

2013-03-05 Thread Noah Lavine
Hello, On Tue, Mar 5, 2013 at 10:24 PM, Mark H Weaver m...@netris.org wrote: Hi Noah, Noah Lavine noah.b.lav...@gmail.com writes: I've only read the most recent article you posted, but if I understand correctly, there is a third option: (3) somehow find a way to generate a portable

Re: What's the plan of Guile on GSoC 2013?

2013-03-07 Thread Noah Lavine
Hi, On Thu, Mar 7, 2013 at 11:29 AM, Ludovic Courtès l...@gnu.org wrote: So, ideas? :-) How about continuing the Emacs-Guile integration? I would be really excited to finally see that happen. Noah

Re: CPS Update

2013-03-08 Thread Noah Lavine
to sketch out the whole compiler first to get the organization right. Now I need to go through and fix all of that. But overall, I think the CPS compiler is going well. Best, Noah On Fri, Feb 15, 2013 at 7:53 PM, Noah Lavine noah.b.lav...@gmail.comwrote: Hello, The wip-rtl-cps branch has been

Re: set! semantics

2013-03-17 Thread Noah Lavine
Hello, I believe that keeping the box identity but not the box value is the correct behavior of continuations under the Scheme standard. I agree it's not intuitive, though. I have been thinking that we could eliminate variable boxes for mutable variables when we can prove that the continuation

Re: Numeric improvements in stable-2.0

2013-03-20 Thread Noah Lavine
Wow, that's great. Thank you! Noah On Wed, Mar 20, 2013 at 2:49 PM, Mark H Weaver m...@netris.org wrote: Hello all, I wanted to briefly highlight some of the improvements to numerics that I've recently pushed to stable-2.0. * 'number-string' now reliably outputs enough digits to produce

Re: [PATCH] Bindings for ‘sendfile’

2013-03-20 Thread Noah Lavine
Hi, sendfile looks very useful! I've thought for a while that if I had time (which I know I won't) I would make a module called (linux) with bindings for non-POSIX Linux kernel features. What do you think of this idea? If so, what do you think of putting sendfile there and expanding it with

Re: [PATCH] Bindings for ‘sendfile’

2013-03-21 Thread Noah Lavine
Hello, Yes, you're completely right - making it work on all platforms is much better than what I had proposed. I'm glad you're doing this. Thanks, Noah On Thu, Mar 21, 2013 at 5:15 AM, Ludovic Courtès l...@gnu.org wrote: Hi Noah, Noah Lavine noah.b.lav...@gmail.com skribis: I've thought

Re: Special variables to relax boxing

2013-03-21 Thread Noah Lavine
Hi, Stefan and Mark, I think you are talking past each other. Stefan is offering a very concrete definition of what he wants, and Mark is looking for a more abstract version. Here is what I think Stefan wants, in the language of R5RS' storage model: A variable is simply a name for a particular

Re: [PATCH] Add-native-hashtable-helper-functions

2013-03-26 Thread Noah Lavine
I would be afraid that without an entry in the manual, people won't know the functions exist, even if the docstrings are enough to explain what they do. Noah On Tue, Mar 26, 2013 at 6:40 AM, Nala Ginrut nalagin...@gmail.com wrote: Added three helper functions, they're so explicit that don't

Re: redo-safe-variables and redo-safe-parameters

2013-03-26 Thread Noah Lavine
Hello, Two quick thoughts on this: 1. It's confusing to say undo and redo, because those aren't in the Scheme standard, and I don't know of any SRFIs that have them either. Instead, maybe you could say using continuations to implement computations that restart. Or, using continuations to

Re: redo-safe-variables and redo-safe-parameters

2013-03-26 Thread Noah Lavine
of this, but we'll see. Noah On Tue, Mar 26, 2013 at 4:43 PM, Stefan Israelsson Tampe stefan.ita...@gmail.com wrote: Relly kind of you to answer this quickly, good thoughts! On Tuesday, March 26, 2013 02:05:41 PM Noah Lavine wrote: Hello, Two quick thoughts on this: 1. It's confusing to say

Re: redo-safe-variables and redo-safe-parameters

2013-03-26 Thread Noah Lavine
(set! last #t) (apply values ret (lambda y (unless last (fluid-set! (vector-ref guards i) a) ...) On Tue, Mar 26, 2013 at 10:07 PM, Noah Lavine noah.b.lav...@gmail.com wrote: Yes, I think parameters and fluids

Re: redo-safe-variables and redo-safe-parameters

2013-03-26 Thread Noah Lavine
have to use (fluid-ref ...) to get their value. Noah On Tue, Mar 26, 2013 at 6:01 PM, Stefan Israelsson Tampe stefan.ita...@gmail.com wrote: On Tuesday, March 26, 2013 05:38:03 PM Noah Lavine wrote: Okay. Let me see if I understand this correctly: Let's say, hypothetically, that there were

Re: redo-safe-variables and redo-safe-parameters

2013-03-27 Thread Noah Lavine
this is a reasonable extension of that idea. Best, Noah On Wed, Mar 27, 2013 at 3:13 AM, Stefan Israelsson Tampe stefan.ita...@gmail.com wrote: On Tuesday, March 26, 2013 06:36:46 PM Noah Lavine wrote: Okay. I don't see a use for number 1. Could you explain why it's important? It seems easier

Re: redo-safe-variables and redo-safe-parameters

2013-03-27 Thread Noah Lavine
Hello, On Wed, Mar 27, 2013 at 9:22 AM, Stefan Israelsson Tampe stefan.ita...@gmail.com wrote: On Wed, Mar 27, 2013 at 1:42 PM, Noah Lavine noah.b.lav...@gmail.com wrote: Hello, Let me see if I understand the point of set! and set~. I think the goal is to have a variable

Re: redo-safe-variables and redo-safe-parameters

2013-03-27 Thread Noah Lavine
On Wed, Mar 27, 2013 at 11:04 AM, Stefan Israelsson Tampe stefan.ita...@gmail.com wrote: Hi Noha, On Wed, Mar 27, 2013 at 3:29 PM, Noah Lavine noah.b.lav...@gmail.com wrote: Hello, On Wed, Mar 27, 2013 at 9:22 AM, Stefan Israelsson Tampe stefan.ita...@gmail.com wrote: I don't

Re: redo-safe-variables and redo-safe-parameters

2013-03-27 Thread Noah Lavine
Hello, On Wed, Mar 27, 2013 at 12:15 PM, Stefan Israelsson Tampe stefan.ita...@gmail.com wrote: Hmm, your really are right in the sense that the common ideom in computer language design is to type a variable at the declaration of the variable. So basically a user would then do something like

Re: redo-safe-variables and redo-safe-parameters

2013-03-27 Thread Noah Lavine
On Wed, Mar 27, 2013 at 5:44 PM, Noah Lavine noah.b.lav...@gmail.comwrote: Since it's definable with such a simple macro, I don't think it's appropriate for a SRFI. Sorry, I just realized that that's not a sensible objection. If it's a better interface than parameters, then it certainly

Re: Extremely high overhead of 'par-map'

2013-03-29 Thread Noah Lavine
I agree. Do you have any idea what's causing the overhead? I tried to benchmark it, but got a segmentation fault. I think we have plenty of work to do here. :-) Noah On Fri, Mar 29, 2013 at 2:00 AM, Mark H Weaver m...@netris.org wrote: I wrote: Nala Ginrut nalagin...@gmail.com writes:

Re: Extremely high overhead of 'par-map'

2013-03-29 Thread Noah Lavine
this where the cost of each function is very small. I realize it's not a great solution because you still have to iterate through the list to get to the later elements. A hypothetical vector-par-map would solve that. Noah On Fri, Mar 29, 2013 at 4:24 PM, Noah Lavine noah.b.lav...@gmail.comwrote

Re: redo-safe-variables and redo-safe-parameters

2013-03-31 Thread Noah Lavine
Hi, A few points: 1. I really, really think that it is a bad idea for the type of a variable to change depending on how it is used (i.e. set! vs. set~). That means that you should remove points 12 and 14, and maybe some other points. 2. You shouldn't specify the semantics in terms of code, but

Re: CPS Update

2013-04-03 Thread Noah Lavine
On Sat, Mar 9, 2013 at 3:31 AM, Andy Wingo wi...@pobox.com wrote: On Fri 08 Mar 2013 23:57, Noah Lavine noah.b.lav...@gmail.com writes: Somewhat shockingly, I think that's almost every language feature. Wow, nice work :-)) Sounds like great stuff. I hope to join you in this work once

Patches for wip-rtl

2013-04-20 Thread Noah Lavine
Hello, I've attached three patches for wip-rtl. The first is somewhat different than the other two: it fixes an error that occurred when moving the linker to its own file. (system vm rtl) and (system vm linker) both contain a function called link-string-table, and (system vm rtl) was calling the

Re: Patches for wip-rtl

2013-04-21 Thread Noah Lavine
that sound reasonable? If not, it should be simple to insert some check there the nargs is big enough not to corrupt anything. Noah On Sat, Apr 20, 2013 at 7:30 PM, Noah Lavine noah.b.lav...@gmail.comwrote: Hello, I've attached three patches for wip-rtl. The first is somewhat different than

Re: Patches for wip-rtl

2013-04-21 Thread Noah Lavine
And here's another patch that fixes an off-by-one error in the bind-rest instruction. This solves the problems I was having in my earlier email about an abort in the VM. Best, Noah On Sun, Apr 21, 2013 at 11:23 AM, Noah Lavine noah.b.lav...@gmail.comwrote: Hello, Please don't worry about

Re: Patches for wip-rtl

2013-04-22 Thread Noah Lavine
Hello, On Mon, Apr 22, 2013 at 4:27 PM, Andy Wingo wi...@pobox.com wrote: Hi Noah, Do I understand you correctly that you're just making a sequence of non-idiomatic instructions because you know that doing the assert-nargs-ee will check nargs? I would think in a normal case you'd want to

Re: Patches for wip-rtl

2013-04-22 Thread Noah Lavine
Hello, On Mon, Apr 22, 2013 at 4:39 PM, Andy Wingo wi...@pobox.com wrote: Hi :) Thanks for working on the RTL VM! Thanks for doing most of the work! I'm happy to help. :-) First of all, sorry about that linker error. I'm trying to make RTL programs more debuggable by hacking on the

Re: The 2.0.9 VM cores in enqueue (threads.c:309)

2013-04-29 Thread Noah Lavine
Hello, On Mon, Apr 29, 2013 at 6:10 AM, Mark H Weaver m...@netris.org wrote: Any ideas? Thanks, Mark It should be possible to use a watchpoint in GDB to figure out what code is corrupting that piece of memory. It probably won't tell us exactly what's going on, but it would be

Re: [Feature Request] Some ideas on 'mmap'

2013-04-30 Thread Noah Lavine
Hello, Apologies if this is well-known and I just forgot it, but can bytevectors be read-only? I think we'd need that to handle read-only mmap'ed memory. (If not, I hope we could allow read-only bytevectors.) Bytevectors include size, so there's no need to put that in a struct, but I'm not sure

Re: wip-rtl disassembler

2013-05-02 Thread Noah Lavine
That's great! Thanks a lot for doing so much RTL stuff. Noah On Thu, May 2, 2013 at 4:11 AM, Andy Wingo wi...@pobox.com wrote: A brief note to say that (system vm disassembler) in wip-rtl now has a functioning disassemble-program that finds function bounds using the ELF symbol table. It's

Re: Patches for wip-rtl

2013-05-04 Thread Noah Lavine
Hello, On Tue, Apr 23, 2013 at 6:13 AM, Andy Wingo wi...@pobox.com wrote: Heya, On Tue 23 Apr 2013 04:38, Noah Lavine noah.b.lav...@gmail.com writes: Ah I see what you mean. There are two uses of variables in the VM: one for calls to variable-ref or variable-set, and the other

Re: wip-rtl disassembler

2013-05-06 Thread Noah Lavine
On Sun, May 5, 2013 at 4:17 PM, Andy Wingo wi...@pobox.com wrote: At this point the disassembler is working much better, and works at the REPL now via ,x. Also, procedure-name now works. I'm now moving to implement source line information and other metadata via .debug_info / .debug_line /

Re: The Road to 2.2

2013-05-18 Thread Noah Lavine
numbers and local variables. But how do we actually produce RTL assembly from Scheme? Well, there we don't have a finished story. Noah Lavine made a branch to compile tree-il, our high-level intermediate language, to a continuation-passing-style (CPS) form. This is a useful transformation

Re: The Road to 2.2

2013-05-21 Thread Noah Lavine
On Sun, May 19, 2013 at 6:02 PM, Ludovic Courtès l...@gnu.org wrote: Andy Wingo wi...@pobox.com skribis: On Sat 18 May 2013 15:44, Noah Lavine noah.b.lav...@gmail.com writes: I have a very small question, based on something I think you said earlier - since the container will be ELF

Re: CPS thoughts

2013-05-21 Thread Noah Lavine
Hello, On Tue, May 21, 2013 at 3:46 PM, Andy Wingo wi...@pobox.com wrote: You should have two names: the original ones and the gensyms that come from tree-il. Creating new gensyms should happen when copying or fabricating new nodes, as peval does, but in most cases you don't need to do it,

Re: CPS thoughts

2013-05-22 Thread Noah Lavine
An update: I just rebased wip-rtl-cps on top of wip-rtl-may-2013 and pushed. The most interesting thing was how trivial it was: all I had to do was make a one-line change in how I called `begin-program'. Best, Noah On Wed, May 22, 2013 at 12:33 AM, Noah Lavine noah.b.lav...@gmail.comwrote

Testing with Custom Evaluators

2013-06-14 Thread Noah Lavine
Hello, Apologies for not Guiling in a while! I just finished up a patch I was talking about a while ago. It lets you run the test suite with a custom evaluator. This is useful if you're testing new evaluators (or compilers!). Along the way, I also added the ability for the test suite to test

Re: order of evaluation

2013-06-17 Thread Noah Lavine
Hello, I always thought that at some point we'd want a form that explicitly didn't fix the order of evaluation. Maybe the for it is now. I imagine something like this: (foo (a (b)) (c (d))) = (unspecified-order ((A (let ((B (b))) (a B)) (C (let ((D (d))) (c D

Re: Errors in libguile 1.8.8 while compiling gnucash on Windows

2013-07-07 Thread Noah Lavine
Hello, I think This list is the right place to send patch files. I don't know if people will look at them too closely, though, because that's an old version of Guile. Can Gnucash use Guile 2? Best, Noah On Sat, Jul 6, 2013 at 9:33 PM, Randy Galbraith randy.galbra...@gmail.comwrote: Hi Guile

Re: CPS language and Tree-IL-CPS-RTL compiler

2013-08-29 Thread Noah Lavine
be many more bugs. I've folded all of his patches into this patchset, so please consider him the joint author of all of this. In any case the bugs have forced him to page much of this code into his head so we are better equipped as a project because of that ;-) Thank you also to Noah Lavine

Re: Memory accounting in libgc

2014-03-18 Thread Noah Lavine
Hello, This reminds me of a related but distinct issue - region-based allocation. Hypothetically, you could use regions to implement a limited form of this accounting, if you could ask the question, what is the size of this memory region? It certainly wouldn't do as much as custodians, but it

Re: Welcome Mark as new co-maintainer

2014-05-27 Thread Noah Lavine
I have only been a lurker for a while now, but I've seen how much excellent work Mark has put into Guile. This is a very well-deserved honor. Congratulations! On Tue, May 27, 2014 at 11:38 PM, David Pirotte da...@altosw.be wrote: Le Tue, 27 May 2014 23:34:32 +0200, l...@gnu.org (Ludovic

<    1   2   3   4