World: r3wp
[Red] Red language group
older newer | first last |
PeterWood 24-May-2011 [1547x2] | Just include this - https://github.com/dockimbel/Red/blob/master/red-system/tests/quick-test/prin-int.reds |
May not be clever but it prints integers. | |
Kaj 24-May-2011 [1549x2] | I know, but this is a solid solution, and there are 26 more functions :-) |
I've bound all memory management functions, most of the string processing functions and a few system interfacing functions | |
PeterWood 24-May-2011 [1551] | Looks good and will also act as a good example. |
Kaj 24-May-2011 [1552] | Thanks |
Dockimbel 25-May-2011 [1553] | Kaj, thanks for the contribution. I have planned to wrap some of the memory manipulation functions too as soon as I finish the work on aliasing and type casting. |
PeterWood 26-May-2011 [1554] | Hats off to Kaj! - from Miejeru on the Red Google Group |
Kaj 26-May-2011 [1555] | Thanks :-) |
Kaj 27-May-2011 [1556] | Red can load library functions with different calling conventions, but which convention does the emitter generate for its own functions? Cdecl? |
Dockimbel 27-May-2011 [1557] | Internal functions: stdcall |
Kaj 27-May-2011 [1558] | Wouldn't it be better for compatibility to use cdecl? |
Dockimbel 27-May-2011 [1559] | I am not sure about the argument order, though...it might be opposite of stdcall |
Kaj 27-May-2011 [1560x2] | I doubt it, because so far I have been able to interchange them. The differences must be very small |
For porting the cURL binding, I will need callbacks. I'm sure cURL on most systems expects them to be cdecl | |
Dockimbel 27-May-2011 [1562] | cdecl for internal functions is only required for callbacks from external app, so I planned to add it for internal functions that are exported. |
Kaj 27-May-2011 [1563] | OK, when is that plannned? |
Dockimbel 27-May-2011 [1564] | In a not-too-distant future :-) I don't have precise ETA for that as it is not required for Red building. I will add that feature when working on the DLL building mode, so probably one of the next weekends (maybe on June, 4-5 if there's no other urgent tasks). |
Kaj 27-May-2011 [1565] | Great, thanks |
Dockimbel 27-May-2011 [1566] | I wanted also to add PIC code generation, so I am not sure which one I'll do first. What do you think? |
Kaj 27-May-2011 [1567] | By DLL building mode, do you mean having Red generate shared libraries? |
Dockimbel 27-May-2011 [1568] | Precisely. |
Kaj 27-May-2011 [1569] | Brilliant |
Dockimbel 27-May-2011 [1570x2] | PIC support will be required for that. |
I thought about implementing PIC support first and testing it using Syllable's executables. | |
Kaj 27-May-2011 [1572x2] | For DLL, you need PIC. I can use callbacks before that, so I'd say the order is cdecl, PIC, DLL |
That would be nice, too, but it's quite possible that executables can already run on Syllable if they can be generated at the right start address | |
Dockimbel 27-May-2011 [1574x3] | Ok, I have no personal priorities for these tasks, so I'll take yours. |
Ah, right, that was the last show-stopper. | |
BTW, I tried installing Syllable on VMWare 7 and it failed to recognize the disk controller (I tried every possible disk modes and Syllable boot mode). I might have not picked the right image to install...I'm retrying right now with this one: http://downloads.syllable.org/Linux/i686/systems/Server/0.1/SyllableServer-0.1.i686.VM.7z | |
Kaj 27-May-2011 [1577] | Oh, that's old. We only got a VMware image contributed for Server 0.1, so it's much better to run the installation for Server 0.4 |
Andreas 27-May-2011 [1578] | hm, kaj, could you try setting base-address: -2147483648 and see if that generates binaries which work? |
Kaj 27-May-2011 [1579x4] | But that's Syllable Server, my Linux, so it won't provide any testing abilities for Red beyond another Linux |
Also, View doesn't run on it. You'd need my unreleased graphical version with X11 to run the Red compiler | |
For testing PIC mode, you'd need Syllable Desktop, for example the live CD you got at ReBorCon :-) | |
Andreas, I'll give it a try | |
Dockimbel 27-May-2011 [1583x2] | Shouldn't I use one of the VMware v0.6.6 images rather than the install CD? |
Or should I wait for your graphical version with X11? | |
Kaj 27-May-2011 [1585x2] | You'r mixing up Desktop and Server. 0.6.6 is Desktop, X11 is Server, which is Linux |
If you want to run Desktop, 0.6.6 indeed has a ready VMware image. On the other hand, the live CD you have has some enhancements. Such as R3 and the cURL binding :-) | |
Dockimbel 27-May-2011 [1587] | Ah! :-) But can it run R2/View? |
Kaj 27-May-2011 [1588x2] | Desktop can only run ORCA, Boron and now R3. That's why I've never been able to use REBOL in the past decade |
Server has R2/Core, Boron and ORCA onboard | |
Dockimbel 27-May-2011 [1590] | Ok, so I need to compile Red/System scripts elsewhere and copy them in Syllable. |
Kaj 27-May-2011 [1591] | I'm using View on our inhouse Syllable Workstation, which I could give you a download for |
Dockimbel 27-May-2011 [1592] | copy them => copy the built binaries |
Kaj 27-May-2011 [1593] | Yes, I cross-compile everything on Syllable Workstation |
Dockimbel 27-May-2011 [1594] | Let me try Desktop first on VMware |
Kaj 27-May-2011 [1595] | Wow, base-address -2147483648 compiles |
Dockimbel 27-May-2011 [1596] | Well done Andreas! :-) |
older newer | first last |