r3wp [groups: 83 posts: 189283]
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

World: r3wp

[!REBOL3-OLD1]

Steeve
11-Dec-2008
[8872]
perhaps a work to do in the wiki
BrianH
11-Dec-2008
[8873]
I can explain, but not give you code yet because it depends on user-defined 
datatypes and we don't even have the syntax for those yet.
Steeve
11-Dec-2008
[8874]
ok i take it
BrianH
11-Dec-2008
[8875]
Perhaps you have noticed that in R2 there are 4 function types, 5 
with rebcode builds: function!, native!, action!, routine!. Each 
of these behaves completely differently on the inside, but are called 
the same on the outside. This is because each of these datatypes 
defines a different execution model. R3 will have allow the user 
to create their own datatypes, and that includes function types. 
All a datatype needs to do to be a function type is to act like a 
function on the outside. How it behaves on the inside is up to it.
Steeve
11-Dec-2008
[8876]
but in what langage will be writed the inner code of such new functions 
? (rebol, c, ...)
BrianH
11-Dec-2008
[8877]
User-defined datatypes (UDT) depend on the R3 plugin model (that's 
not done yet either) and plugins are a REBOL module wrapper around 
native code. UDTs can be defined in REBOL code or a mix of REBOL 
and native.
Steeve
11-Dec-2008
[8878]
ok
BrianH
11-Dec-2008
[8879]
One thing you are missing is that the input data of the MAKE action 
of a datatype does not have to be the same as what is on the inside 
of the value created. That means that you could pass a block of code 
or string containing another language's syntax to MAKE and the datatype's 
MAKE handler can translate that data to whatever internal format 
it needs. This means we can compile.
Steeve
11-Dec-2008
[8880]
this means we could compile some c code in the fly with something 
like tcc
BrianH
11-Dec-2008
[8881]
Yes, that is one of my plans.
Steeve
11-Dec-2008
[8882]
sounds sweet
BrianH
11-Dec-2008
[8883x2]
The datatype's execution engine deals with the internal data that 
the MAKE handler creates, not the input syntax. This means that the 
internal data could be anything: bytecode, native code, graph structures, 
whatever.
You can't get a reference to the internal data in R3 like you can 
in R2, so no hot patching.
Steeve
11-Dec-2008
[8885]
using struct! ?
BrianH
11-Dec-2008
[8886]
I mean the value returned by the body-of reflector of a function 
is at best an unbound deep copy of the body, not the original. You 
can't patch functions. This means that your datatype could return 
a copy of the input data, a disassembly of your bytecode, or nothing 
if you like.
Steeve
11-Dec-2008
[8887]
hum i see
BrianH
11-Dec-2008
[8888x2]
This was a security fix.
Nonetheless, I am doing whatever I can to speed up regular R3 whereever 
it is reasonable to do so. The profiler is my friend :)
[unknown: 5]
11-Dec-2008
[8890]
what is the name of the REBOL world again for 2.7.7?
Henrik
11-Dec-2008
[8891]
r2-beta, I think
Maxim
11-Dec-2008
[8892]
quick question about R3.... does the GC *release* memory from the 
process properly, as opposed to R2 growing infinitely?
Kaj
11-Dec-2008
[8893]
R2 does that?
Maxim
11-Dec-2008
[8894]
yep.
Sunanda
11-Dec-2008
[8895]
R2 does not grow infinitely, but it does not hand back memory -- 
it prefers to keep what it's got and use that again when needed.

That is faster than continually handing back and reacquiring memory 
in many cases.

But if an application needs a large amount of memory at start-up 
(or some other peak time), it keeps that memory until the end. That 
is not very friendly!
Maxim
11-Dec-2008
[8896x6]
any memory use which grows the global pool is never de-allocated 
 :-(
but the actual effect is that if R2 grows, memory wise, its GC slows 
down.  so the argument of handing back the memory is ultimately flawed.
I've even witnessed this with altme, when doing the initial sync, 
it grew to almost 200 MB.  it then started to freeze sporadically.
so I just quit, started back... got me a nice 50MB process and all 
is well.
and sunanda... I've also discovered that it doesn't always recycle 
the memory its got !  image manipulation is an example of that.
does any one know if all of this is still an issue with R3 ?
Henrik
11-Dec-2008
[8902x2]
There is a bug in R2 that causes a memory leak related to a specific 
use of GUI events and network ports. I've encountered this a few 
times.
How R3 handles memory, I don't know. There are several new debugging 
functions to explicitly let you know what is used and what is released. 
I would guess that Carl has also tried to make sure it's easier to 
find leaks.
Maxim
11-Dec-2008
[8904x3]
I just hope that we can *force* a memory shrink.  I've got an application 
which needs a 900MB bitmap to be generated and drawn on... this works 
in rebol... but the moment I try to allocate a new one... it crashes. 
 the one is never released  :-(
(... the *old* one...)
or the memory reused for that matter  :-/
[unknown: 5]
11-Dec-2008
[8907]
Thanks Henrik
Kaj
11-Dec-2008
[8908]
Hm, sounds like one of the root causes why the AltME server can overflow 
the memory and swap space when a slightly larger file is downloaded
Maxim
11-Dec-2008
[8909]
very possible.
Micha
12-Dec-2008
[8910]
IPv6 connection works in rebol3 ?
Pekr
12-Dec-2008
[8911x2]
I am not sure it has anything in common with R3 itself? Isn't it 
task of underlying OS layers?
- but, for .e.g. with Cisco VPN client, we had to turn IPv6 off in 
order to get it work properly.
Henrik
12-Dec-2008
[8913]
if a user will ever need to enter an IPV6 address directly, there 
should probably be support for that, but other than that, the rest 
is up to the OS.
PeterWood
12-Dec-2008
[8914]
No new datatype for IPv6 addresses?
Micha
12-Dec-2008
[8915]
when he can download a new public or other R3 Releases ?
Henrik
12-Dec-2008
[8916]
if you mean he = we, then: unknown
PeterWood
12-Dec-2008
[8917]
Do the current R3 private releases have any sound capabilities?
Henrik
12-Dec-2008
[8918]
no
Pekr
12-Dec-2008
[8919]
REBOL never had any sound :-)
Ammon
12-Dec-2008
[8920]
That's why I hear a "Ding!" everytime a new message comes into this 
world...  Cause REBOL can't play sounds!
Henrik
12-Dec-2008
[8921]
REBOL 2 can play sounds, but I don't think you want to build a 32 
channel music tracker with it. :-)