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

World: r3wp

[Red] Red language group

Kaj
24-Jun-2011
[2560x2]
Updated the C and 0MQ bindings for the unset EITHER return value 
fix
However, their functioning is still hampered by the not as-logic 
function! bug, which affects half my functions
Dockimbel
24-Jun-2011
[2562]
I won't be able to get back to Red before tomorrow.
Kaj
24-Jun-2011
[2563]
No problem, it's just a note about the state, and it's ready for 
the solution
Kaj
25-Jun-2011
[2564]
Thanks for the fix! The bindings are fully functional now
Dockimbel
25-Jun-2011
[2565]
Cool!
Kaj
26-Jun-2011
[2566x2]
I've overhauled the design of the 0MQ binding. The high level interface 
is now better tuned. Memory management is moved out of it, so it's 
more efficient. No more thrashing of the allocator for message containers
Message holders don't leak memory anymore, but now the payload of 
sent messages leaks, due to what seems to be a bug in callbacks. 
More in the tracker
Andreas
26-Jun-2011
[2568x2]
The callback is called just fine, but seems to corrupt something 
while running.
Thanks for the report, in any case.
Dockimbel
27-Jun-2011
[2570]
Kaj: good to know that you working on improving the 0MQ binding. 
I will have a look on the callback issue.
Kaj
27-Jun-2011
[2571]
Thanks for the first fix, but it doesn't work yet
Dockimbel
27-Jun-2011
[2572x3]
Right, Andreas fix shouldn't change anything, see my comment: https://github.com/dockimbel/Red/commit/89f2533a5712a389ae15220be3ca75e75f4728c2
I will run his test case step by step to see what's wrong.
Works fine on Windows, so it looks like a Linux-specific issue...
Oldes
27-Jun-2011
[2575]
When we can expect support for decimal numbers?
Kaj
27-Jun-2011
[2576]
You mean floating point?
Oldes
27-Jun-2011
[2577]
yes
PeterWood
27-Jun-2011
[2578]
I'm pretty certain that Nenad has said that he won't be adding binary 
floating point numbers to Red/System as they will not be needed to 
build the Red runtime. So at the moment, I would only expect them 
once Red is available.
Kaj
27-Jun-2011
[2579x2]
Not anymore, because he has now decided to compile Red to Red/System, 
so Red/System will need full support
I think that's a good thing, but it may still be wise to postpone 
the implementation. Having Red will enable more people to contribute, 
but on the other hand, the lack of floating point is blocking a few 
contributors now
Dockimbel
27-Jun-2011
[2581]
Floating point support should be added to Red/System if my tests 
shows that I can safely do the Red->Red/System compilation, else 
it will be supported at Red level. Anyway, it is not a priority for 
me, so it probably won't be added before Q4 2010 (unless someone 
wants to contribute by adding it to Red/System).
Oldes
27-Jun-2011
[2582]
Q4 2010 is in the past... :) but thanks for the info. I can wait.
Dockimbel
27-Jun-2011
[2583x2]
Sorry, Q4 2011.
Those years are passing too fast. :-)
Mchean
27-Jun-2011
[2585]
but at least Red seems to be keeping up
Kaj
28-Jun-2011
[2586]
Andreas' fixes to callbacks on Linux work now. I've enabled them 
in the 0MQ binding and with that, the binding is now pretty much 
production ready
Dockimbel
28-Jun-2011
[2587]
Andreas did a great debugging work on that.
Kaj
28-Jun-2011
[2588]
Yep
Andreas
28-Jun-2011
[2589]
Thanks. Good to hear that it's now working for you as well, Kaj.
Gregg
28-Jun-2011
[2590]
Very cool. Thanks to all of you for coordinating on this.
Robert
29-Jun-2011
[2591]
Is it possible to compile R3 extensions right out-of-the-box? That 
would be pretty cool.
Dockimbel
29-Jun-2011
[2592]
Robert: yes, as soon as we add DLL generation support in Red/System.
Oldes
29-Jun-2011
[2593]
it will not be much useful without floats ;-)
Dockimbel
29-Jun-2011
[2594]
Nice try :-)
Kaj
29-Jun-2011
[2595]
You'll still have to implement the R3 extensions interface
Dockimbel
29-Jun-2011
[2596]
The 64-bit integer support might also be required in Red/System for 
that.
Kaj
29-Jun-2011
[2597x2]
Indeed, it doesn't seem to be possible to get away without that
Once there are 64 bits values, it may be possible to shuffle them 
as floating point values between libraries, without Red being aware 
what they're used for
Dockimbel
29-Jun-2011
[2599]
Good point.
Kaj
29-Jun-2011
[2600]
When floats are passed to C functions, can they be in normal registers 
or must they be in FPU registers?
Dockimbel
29-Jun-2011
[2601]
If the calling convention is cdecl, they are just pushed on stack.
Kaj
29-Jun-2011
[2602]
That seems like a nice shortcut, then
Dockimbel
29-Jun-2011
[2603x2]
That would only work for literal float values.
If you use a variable, you need to pass thru the registers.
Kaj
29-Jun-2011
[2605]
The FPU registers?
Dockimbel
29-Jun-2011
[2606x2]
In the float case, yes FPU registers.
IA32 32-bit registers can't hold C double floats (64-bit).
Kaj
29-Jun-2011
[2608x2]
I've started working on a cURL binding. It can print the cURL version 
now :-)
I could call it a port from the R3 binding, but it will be more like 
a rewrite