Skip to search.

Breaking News Visit Yahoo! News for the latest.

×Close this window

iolanguage · Io

The Yahoo! Groups Product Blog

Check it out!

Group Information

? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Real people. Real stories. See how Yahoo! Groups impacts members worldwide.

Messages

Advanced
Messages Help
Messages 6914 - 6943 of 13333   Oldest  |  < Older  |  Newer >  |  Newest
Messages: Show Message Summaries Sort by Date ^  
#6914 From: Thomas Sutton <thsutton@...>
Date: Thu Sep 1, 2005 7:47 am
Subject: Re: [Io] Io machine
grimkor
Send Email Send Email
 
On 01/09/05, Jason Grossman <Jason.Grossman@...> wrote:
> On 01/09/2005, at 2:34 pm, Thomas Sutton wrote:
>
> > I was under the impression that Io doesn't have a virtual machine
> > (i.e. an instruction set).
>
> Sure it does: IoVM.  OK, so the instructions are a little complicated
> for most chips.  That's where the microcode comes in.
>
> Did anyone really think I was serious?  (Don't admit it if you did.)
I was hoping that you weren't, but I wouldn't put it past some people.

On the other hand, there are chips out there that do this sort of
thing for other languages (e.g. the Java acceleration stuff for ARM
chips). Some of the weird new architectures, like TRIPS, are more
interesting. TRIPS is to EDGE what MIPS was to RISC. The TRIPS
architecture does instruction-level dataflow driven execution
(instructions wait around in their execution unit and "fire" when they
get their inputs).

#6915 From: Steve Dekorte <steve@...>
Date: Thu Sep 1, 2005 9:34 am
Subject: Re: [Io] Io machine
stevedekorte
Send Email Send Email
 
On Aug 31, 2005, at 11:08 PM, Steve Dekorte wrote:
> or at least this bit:
>
> ((key >> a) ^ (key >> b)) & mask

Actually, the mask only needs to tell it how many low bits should be
non-zero in the output and the rest just needs to to a good job of
mixing the bits of key in some deterministic way that is a function of
the parameters a and b. I imagine this could be done quite efficiently
in some custom logic.

-- Steve

#6916 From: Jason Grossman <Jason.Grossman@...>
Date: Thu Sep 1, 2005 10:14 am
Subject: Re: [Io] Io machine
jas0ngr0ssman
Send Email Send Email
 
On 01/09/2005, at 7:34 pm, Steve Dekorte wrote:

>
> On Aug 31, 2005, at 11:08 PM, Steve Dekorte wrote:
>> or at least this bit:
>>
>> ((key >> a) ^ (key >> b)) & mask
>
> Actually, the mask only needs to tell it how many low bits should be
> non-zero in the output and the rest just needs to to a good job of
> mixing the bits of key in some deterministic way that is a function of
> the parameters a and b. I imagine this could be done quite efficiently
> in some custom logic.

Sure.  Good idea.

I think (not sure) that this is not far off the level at which LISP
machines worked.  They didn't really implement a VM either (I think).
They were just very good at things that LISP needs, e.g. virtual memory
(a rarity in hardware back when LISP machines were popular) and caching
the bits of the stack that LISP functions were likely to use into
registers.  And they tagged every word of memory with a runtime type
--- which could be useful for Io, I guess.

This post is serious, so correct me if I'm wrong!

Jason

#6917 From: Mike Austin <mike_ekim@...>
Date: Thu Sep 1, 2005 9:27 pm
Subject: Re: Fun with partial application
mike_ekim
Send Email Send Email
 
Erik Max Francis wrote:
> Mike Austin wrote:
>
>
>>Erik Max Francis wrote:
>
>  >
>
>>>Mike Austin wrote:
>>>
>>>
>>>>Number add := Number getSlot("+")
>>>>Number setSlot("+", method(b,
>>>>  if (b == Nil, return block(b, self + b))
>>>>  self add(b)
>>>>))
>>>
>>>
>>>What editor do you use?  :-)
>>
>>What, it doesn't look that strange does it? :)
>>btw I usually use vi or dev-cpp.
>
>
> Nah, it was just the double indent starting with setSlot(..., method(...
> and the double dedent on one line with )) smacked of my io-mode.

Oh I only do that with setSlot()ing a method, and sometimes with do().  It
would be nice if I could say "Number \+ = method(...)" or something but it's
not that big a deal.

Mike

#6918 From: Erik Max Francis <max-gmane@...>
Date: Thu Sep 1, 2005 9:37 pm
Subject: Re: Fun with partial application
xihr
Send Email Send Email
 
Mike Austin wrote:

> Oh I only do that with setSlot()ing a method, and sometimes with do().  It
> would be nice if I could say "Number \+ = method(...)" or something but it's
> not that big a deal.

Yeah, same.  Initially I was thinking it would be nice if you could
quote it similar to way the way you can get around operators in Prolog,
but that really wouldn't make sense for Io.

--
Erik Max Francis && max@... && http://www.alcyone.com/max/
San Jose, CA, USA && 37 20 N 121 53 W && AIM erikmaxfrancis
    Moral indignation is jealousy with a halo.
    -- H.G. Wells

#6919 From: "therandthem" <therandthem@...>
Date: Thu Sep 1, 2005 7:18 pm
Subject: Database Servers
therandthem
Send Email Send Email
 
When the time is right, this http://sqlrelay.sourceforge.net/ seems
like the existing framework to use.

Thanks,

McKinley

#6920 From: Kevin Edwards <edwakev@...>
Date: Fri Sep 2, 2005 12:29 am
Subject: Re: [Io] Re: Lexical do() now easy with multiple protos
edwakev
Send Email Send Email
 
Mike Austin wrote:
> I always get confused with all the scoping methods - self, target,
> sender, thisContext, etc.  Can someone draw a diagram or something?
> :)

It took me a while to figure it out, too; the terminology can be
confusing.  Maybe an example would help:

   ob := Object clone
   ob meth := method(a,b,print)
   ob meth(1,2,3)

Calling "meth(1,2,3)" creates a 'locals' object with the following
slots:

   proto = Locals
   a = 1
   b = 2
   sender = Lobby  (the locals object the method was called from)
   self = ob
   target = ob
   thisBlock = ob getSlot("meth")
   thisMessage = "meth(1,2,3)" asMessage
   thisContext = a circular reference to this locals object

The "print" message is then sent to that locals object, which prints
the slots described above.

I tried to explain the details in the notes that I posted:
http://pipapo.org/iowiki/KevinEdwardsNotes

I think the concept might also be confusing because there are two
message sends involved in a method call:

1) "meth(1,2,3)" (thisMessage) is sent to the object "ob" (target),
which basically means: get the value in ob's "meth" slot, and activate
(execute) it.

2) Then, in the execution of the method object, a new 'locals' object
is created, which becomes the target of the method's internal message.

I hope that helps. :)

Kevin

#6921 From: "mfeathers256" <mfeathers@...>
Date: Sat Sep 3, 2005 12:50 pm
Subject: io vm docs down?
mfeathers256
Send Email Send Email
 
Has this gone someplace else?  It's the link through from
io|docs|manual|english|vm

http://www.iolanguage.com/source/Io/IoVM/_docs/index.html

Michael

#6922 From: Steve Dekorte <steve@...>
Date: Sat Sep 3, 2005 3:12 pm
Subject: lexical do
stevedekorte
Send Email Send Email
 
While thinking about ways to improve the expression evaluator, a simple
way to implement a lexical do occurred to me:

Object lexicalDo := method(thisMessage setNextMessage(thisMessage
argAt(0)))

It seems to work nicely.

-- Steve

#6923 From: Steve Dekorte <steve@...>
Date: Sat Sep 3, 2005 3:41 pm
Subject: Re: [Io] lexical do
stevedekorte
Send Email Send Email
 
On Sep 3, 2005, at 8:12 AM, Steve Dekorte wrote:
> While thinking about ways to improve the expression evaluator, a simple
> way to implement a lexical do occurred to me:
>
> Object lexicalDo := method(thisMessage setNextMessage(thisMessage
> argAt(0)))

Sorry, I spoke too soon. The newer expression evaluator doesn't support
this.

-- Steve

#6924 From: QuantumG <qg@...>
Date: Sun Sep 4, 2005 11:28 pm
Subject: Debugger for Io
trent_w16
Send Email Send Email
 
Using my MessageView widget I've made a simple debugger for Io:

     http://rtfm.insomnia.org/~qg/iodebug/

Let me know if there's any problems.

Trent

#6925 From: QuantumG <qg@...>
Date: Thu Sep 8, 2005 6:00 am
Subject: GTK+ bindings for Io
trent_w16
Send Email Send Email
 
Available here:

     http://rtfm.insomnia.org/~qg/iogtk/

Based on a DynLib extension I've written that lets you call arbitary
functions exported from shared libraries on x86 machines.  If someone
would like this on another architecture I'll try to do it..  But if
we're talking about PowerPC I'll probably need some help :)

Trent

#6926 From: Jon Kleiser <jon.kleiser@...>
Date: Thu Sep 8, 2005 8:01 am
Subject: List docs fixes needed
jon_kleiser
Send Email Send Email
 
Some comments about what should be fixed (in the 20050830 Bin. docs):

slot           what to do
-------------- ---------------------------
addIfAbsent    replace with appendIfAbsent
anyOne         replace random
appendIfAbsent replace addIfAbsent (above)
average        undocumented
mapInPlace     replace map
popFirst       undocumented
sum            undocumented

/Jon

#6927 From: Christian Thaeter <chth@...>
Date: Thu Sep 8, 2005 10:47 am
Subject: New Infrastructure
chth@...
Send Email Send Email
 
After some discussions on Irc I posted a few notes on my wiki, please
review them and add comments:

http://www.pipapo.org/iowiki/NewInfrastructure

Some Notes:

This will become a real fork of the Io project.

Yes, Steve agreed on this idea.

I want any Io contributor to join these efforts.

The goal is to work into Steves hands, taking away the things he cant
handle from him and let him focus on improving Io.

I only want to seed and support this fork but don't want to maintain
everything longer than nesseary, volunteers needed!


	 Christian

#6928 From: Jon Kleiser <jon.kleiser@...>
Date: Thu Sep 8, 2005 11:43 am
Subject: Box with negative height or width
jon_kleiser
Send Email Send Email
 
In the current version of Io (20050830), Boxes with negative height
or width don't contain any Points. At least that's what I conclude
from this:

Io> Box clone set(vector(0,0),vector(4,-4)) containsPoint(vector(2,-2))
==> Nil

Io> Box clone set(vector(0,0),vector(-4,4)) containsPoint(vector(-2,2))
==> Nil

Io> Box clone set(vector(0,0),vector(-4,-4)) containsPoint(vector(-2,-2))
==> Nil

This was a surprise to me. Are there any strong opinions on this? If
not, I suggest that Box containsPoint should be modified ...

/Jon

#6929 From: QuantumG <qg@...>
Date: Thu Sep 8, 2005 12:17 pm
Subject: Re: [Io] Box with negative height or width
trent_w16
Send Email Send Email
 
Jon Kleiser wrote:

>This was a surprise to me. Are there any strong opinions on this? If
>not, I suggest that Box containsPoint should be modified ...
>
>
>

Feel free to fix it.

Trent

#6930 From: Jon Kleiser <jon.kleiser@...>
Date: Thu Sep 8, 2005 2:06 pm
Subject: Re: [Io] Box with negative height or width
jon_kleiser
Send Email Send Email
 
>Jon Kleiser wrote:
>
>>This was a surprise to me. Are there any strong opinions on this? If
>>not, I suggest that Box containsPoint should be modified ...
>>
>>
>>
>
>Feel free to fix it.
>
>Trent

Here it is: <http://folk.uio.no/jkleiser/io/IoBox.c>

... a fix to allow Boxes with negative width, height, or depth to
contain Points.

In addition to the three lines (in the function IoBox_containsPoint)
that negates values for the three dimensions, I also swapped the use
of the variables w and h, since it (for me) is more natural to say "x
+ w" than "x + h" ;-)

/Jon

#6931 From: Steve Dekorte <steve@...>
Date: Thu Sep 8, 2005 4:41 pm
Subject: Re: [Io] GTK+ bindings for Io
stevedekorte
Send Email Send Email
 
On Sep 7, 2005, at 11:00 PM, QuantumG wrote:
> Available here:
>
>     http://rtfm.insomnia.org/~qg/iogtk/
>
> Based on a DynLib extension I've written that lets you call arbitary
> functions exported from shared libraries on x86 machines.  If someone
> would like this on another architecture I'll try to do it..  But if
> we're talking about PowerPC I'll probably need some help :)

Nice work! I'm adding a link on the community page.

-- Steve

#6932 From: Mike Austin <mike_ekim@...>
Date: Thu Sep 8, 2005 7:26 pm
Subject: Right aligning numbers
mike_ekim
Send Email Send Email
 
I thought there was once a width() or pad() type of function in Io to right
align numbers when converting to a string, with an optional pad character.  Am
I missing something?

Mike

#6933 From: QuantumG <qg@...>
Date: Fri Sep 9, 2005 6:03 am
Subject: Re: [Io] GTK+ bindings for Io
trent_w16
Send Email Send Email
 
Steve Dekorte wrote:

>Nice work! I'm adding a link on the community page.
>
>

I've updated the page to now include the code for my debugger ported to
GTK+.  To get this to work I had to disable a check in IoObject_forward..

     if (10000 < Stack_totalSize(state->currentRetainStack))
     {
            [print error message and die]

I have no idea why this is firing.  Any chance you can explain what the
retain stack is and why it would be overflowing?  Appreciate it.

Thanks,

Trent

#6934 From: Jon Kleiser <jon.kleiser@...>
Date: Fri Sep 9, 2005 11:48 am
Subject: Vector bugs/problems
jon_kleiser
Send Email Send Email
 
First the problem:

If I have a script that does the following ...

b := Box clone set(vector(0, 0), vector(6, 6))
c := b containsPoint(vector(1, 1))
v := vector(2, 2)
v Max(b origin)

... then I get "Io Assertion: Vectors not of equal size".

It seems that containsPoint extends the Box origin (and size) vector
from 2d to 3d (adding a 0). My opinion is: Either the containsPoint
should not touch those vectors, or Max (and Min) should be modified
to work on vectors of different size (or both).

Then the bug:

v := vector(2, 2)
v Min(vector(1, 1))
==> vector(2, 2)

---
I'm using IoDesktop version 20050830 on OSX.

/Jon

#6935 From: QuantumG <qg@...>
Date: Fri Sep 9, 2005 12:45 pm
Subject: Re: [Io] GTK+ bindings for Io
trent_w16
Send Email Send Email
 
I've added an object browser app to the GTK+ bindings page.

    http://rtfm.insomnia.org/~qg/iogtk/

I havn't connected any action to double click.. I figure popping up an
editor would be nice.

Trent

#6936 From: newgroup@...
Date: Fri Sep 9, 2005 6:55 am
Subject: Re: [Io] GTK+ bindings for Io
newgroup@...
Send Email Send Email
 
QuantumG wrote:
> I've updated the page to now include the code for my debugger ported to
> GTK+.  To get this to work I had to disable a check in IoObject_forward..
>
>     if (10000 < Stack_totalSize(state->currentRetainStack))
>     {
>            [print error message and die]
>
> I have no idea why this is firing.  Any chance you can explain what the
> retain stack is and why it would be overflowing?  Appreciate it.

Hi,
looks nice, but this is what i get when i run the debugger:

--- console output start

user@PC Io % ./io debug.io
cursorPixBuf: -2145973680
>>>> perhaps a gtk error doesn't matter

File asString: unable to read file 'foo.io'

Label                 Line       Char    Message
------------------------------------------------
debug                 133        3117    doFile("foo.io")

>>>> i don't have foo.io doesn't matter too

cmd:

Io Object forward: stack overflow

Label                 Line       Char    Message
------------------------------------------------
gtk                   135        3286    getText
debug                 107        2621    getText
[unlabeled]           0          0       clicked(o, arg)
[unlabeled]           0          0       [unnamed]([unnamed], [unnamed])
gtk                   48         1210    main
gtk                   44         1175    run

>>>> This might be interesting

--- console output end

I have gtk 2.6.10 installed which is being used.

Manfred
______________________________________________________________________
XXL-Speicher, PC-Virenschutz, Spartarife & mehr: Nur im WEB.DE Club!
Jetzt gratis testen! http://freemail.web.de/home/landingpad/?mc=021130

#6937 From: QuantumG <qg@...>
Date: Sat Sep 10, 2005 7:51 am
Subject: Re: [Io] GTK+ bindings for Io
trent_w16
Send Email Send Email
 
newgroup@... wrote:

>cmd:
>
>Io Object forward: stack overflow
>
>

Yep, you need to apply my latest dynlib-extension.diff patch.. I turn
off this check.  I don't know why it fires.. I've asked Steve, no
response as yet.

Trent

#6938 From: Steve Dekorte <steve@...>
Date: Sat Sep 10, 2005 1:45 pm
Subject: Re: [Io] Box with negative height or width
stevedekorte
Send Email Send Email
 
On Sep 8, 2005, at 7:06 AM, Jon Kleiser wrote:
  > Here it is: <http://folk.uio.no/jkleiser/io/IoBox.c>
>
> ... a fix to allow Boxes with negative width, height, or depth to
> contain Points.
>
> In addition to the three lines (in the function IoBox_containsPoint)
> that negates values for the three dimensions, I also swapped the use
> of the variables w and h, since it (for me) is more natural to say "x
> + w" than "x + h" ;-)

Thanks Jon, I've added your change.

-- Steve

#6939 From: Steve Dekorte <steve@...>
Date: Sat Sep 10, 2005 4:41 pm
Subject: Release 2005 09 10 - updates
stevedekorte
Send Email Send Email
 
http://www.iolanguage.com/downloads/

Release 2005 09 10 - updates
============================
- moved implementation of ? to Io
- VM autodocs now auto include _ioCode docs
- improved List shuffle method (suggested by John D. Mitchell)
- fix for Box containsPoint() (by Jon Kleiser)
- DynLib changes to support gtk binding (by QuantumG)

#6940 From: Mike Austin <mike_ekim@...>
Date: Sat Sep 10, 2005 8:38 pm
Subject: SkipDBRecord->key == 1 causes crash at end of Continuation.io
mike_ekim
Send Email Send Email
 
Somehow SkipDBRecord->key gets set to "1" instead of a ByteArray pointer when
Continuation.io exits.  This is as far as I've debuged, Steve can you look at
it?  BTW, most of the tests in _test are out of date so they are not much use.

inline int SkipDBRecord_compareKey_(SkipDBRecord *self, Datum key)
{
      int result;
      printf("here2 > %d\n", self->key);
      result = ByteArray_compareDatum_(self->key, key);
      printf("here2 <\n");
      return result;
}

[...]
here2 > 5658224
here2 <
here2 > 5762144
here2 <
here2 > 1
Segmentation fault (core dumped)


Mike

#6941 From: Mike Austin <mike_ekim@...>
Date: Sat Sep 10, 2005 9:07 pm
Subject: IoList_map() source, please add
mike_ekim
Send Email Send Email
 
It's basically the mapInPlace source, but uses and returns a new list.  I can't
understand why it hasn't been added.

IoList *IoList_proto(void *state)
{
      [...]
      {"map",            IoList_map},
      [...]
}

IoObject *IoList_map(IoList *self, IoObject *locals, IoMessage *m)
{
      /*
      method: map([index,] value, message)
      description: Set each value with the return of message. Returns a new list.
      */

      IoState *state = IOSTATE;
      IoSymbol *slotName;
      IoSymbol *valueName;
      IoMessage *doMessage;
      register int i;
      register int putIndex = 0;
      IoList *outList = IoList_new(IOSTATE);

      IoMessage_foreachArgs(m, self, &slotName, &valueName, &doMessage);

      /*IoState_retain_(IOSTATE, self);*/
      IoState_pushRetainPool(state);

      for (i = 0; i < List_size(LISTIVAR(self)); i++)
      {
          IoState_clearTopPool(state);
          {
              IoObject *value = (IoObject *)LIST_AT_(LISTIVAR(self), i);
              if (!ISNIL(slotName))
              {
                  IoObject_setSlot_to_(locals, slotName, IONUMBER(i));
              }
              IoObject_setSlot_to_(locals, valueName, value);
              {
                  IoObject *result = IoMessage_locals_performOn_(doMessage,
                                     locals, locals);
                  int status = IoMessage_stopStatus(doMessage);

                  if (status != MESSAGE_STOP_STATUS_CONTINUE)
                  {
                      if (status) goto done;
                      IoList_rawAtPut(outList, putIndex++, result);
                  }
                  IoMessage_resetStopStatus(doMessage);
              }
          }
      }
      done:
      List_setSize_(LISTIVAR(outList), putIndex); // needed?
      IoState_popRetainPool(state);

      return outList;
}

#6942 From: Steve Dekorte <steve@...>
Date: Sun Sep 11, 2005 12:56 am
Subject: Re: [Io] SkipDBRecord->key == 1 causes crash at end of Continuation.io
stevedekorte
Send Email Send Email
 
On Sep 10, 2005, at 1:38 PM, Mike Austin wrote:
> Somehow SkipDBRecord->key gets set to "1" instead of a ByteArray
> pointer when
> Continuation.io exits.

I don't get any errors on OSX either on the command line or via gdb:

% ./io /Users/steve/IoProject/Io/IoVM/_tests/Concurrency/Continuation.io
1 - in main, sent async message, yielding
2 - in foo, pausing
3 - in main, after yield
4 - in foo, after pause
5 - in main, after resume

Could this be an issue with coros on your platform?

-- Steve

#6943 From: Steve Dekorte <steve@...>
Date: Sun Sep 11, 2005 1:00 am
Subject: Re: [Io] IoList_map() source, please add
stevedekorte
Send Email Send Email
 
On Sep 10, 2005, at 2:07 PM, Mike Austin wrote:
> It's basically the mapInPlace source, but uses and returns a new list.
>  I can't
> understand why it hasn't been added.

Thanks Mike, I've added it.

-- Steve

Messages 6914 - 6943 of 13333   Oldest  |  < Older  |  Newer >  |  Newest
Add to My Yahoo!      XML What's This?

Copyright © 2010 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines NEW - Help