[Pharo-project] FFI wish list: double arrays and friends
Sig, Stef is hinting that you are going to have some good news about OpenGL and FFI in general. One area in which I have been fumbling along is arrays of doubles, float, signed and unsigned single and double words. Some of it is redundant and arguably more about making code written for Dolphin happy in Pharo, but the doubles really are missing. Alignment is a concern; I have been lucky. It would be nice to get it right. I (ab)use byte arrays to hold the data, have some accessors that I seldom use (most of the access is, thankfully for speed, through functions in external libraries). Ideally, Pharo would provide a full range of double, float, signed and unsigned single and double and probably quad words with FFI awareness of all of them. Where is all of this going? My GSL interface is scarred by the past lack of support for underscores, and really needs to be rebuilt now that this is no longer a problem. It's even worse with PLplot because their function names are mystifyingly cryptic; Camel Case them and they are *completely* unrecognizable :( Another wrinkle with GSL is that I was unable to load it (as-is) on Linux. At least at the time, there were two libraries (GSL itself and BLAS) that were inter-dependent. A library that uses both would load, but the individual libraries would not open via FFI. I put a bunch of my own code, and some proprietary code, into the library that allows the offenders to load. With license constraints and the joys of GPL, I need to separate these things before a public release. It would be nice to clean all of this stuff at one shot and get first releases of PLplot and GSL bindings for Pharo. Callbacks would provide clean use of the minimizers and solvers in GSL, allowing me to remove a lot of confusing junk that I added to work around the missing features. It should be worth the wait. Bill
On 12 November 2011 18:43, Schwab,Wilhelm K <bschwab@anest.ufl.edu> wrote:
Sig,
Stef is hinting that you are going to have some good news about OpenGL and FFI in general. One area in which I have been fumbling along is arrays of doubles, float, signed and unsigned single and double words. Some of it is redundant and arguably more about making code written for Dolphin happy in Pharo, but the doubles really are missing. Alignment is a concern; I have been lucky. It would be nice to get it right.
I (ab)use byte arrays to hold the data, have some accessors that I seldom use (most of the access is, thankfully for speed, through functions in external libraries). Ideally, Pharo would provide a full range of double, float, signed and unsigned single and double and probably quad words with FFI awareness of all of them.
It is easy to add more types and other stuff, except that i need some real stuff to work with, like one you working on.
Where is all of this going?
My GSL interface is scarred by the past lack of support for underscores, and really needs to be rebuilt now that this is no longer a problem. It's even worse with PLplot because their function names are mystifyingly cryptic; Camel Case them and they are *completely* unrecognizable :(
Another wrinkle with GSL is that I was unable to load it (as-is) on Linux. At least at the time, there were two libraries (GSL itself and BLAS) that were inter-dependent.  A library that uses both would load, but the individual libraries would not open via FFI. I put a bunch of my own code, and some proprietary code, into the library that allows the offenders to load. With license constraints and the joys of GPL, I need to separate these things before a public release.
It would be nice to clean all of this stuff at one shot and get first releases of PLplot and GSL bindings for Pharo. Callbacks would provide clean use of the minimizers and solvers in GSL, allowing me to remove a lot of confusing junk that I added to work around the missing features. It should be worth the wait.
Starting from Jan. i will focus on adding missing stuff to NativeBoost, like callbacks and code inlining. We can solve these things one by one.
Bill
-- Best regards, Igor Stasenko.
Sig, The problem is that I can't release the current form for various reasons. My plan is to make (roughly) 2000 methods and 135 structure definitions available, plus any other wrappers that can be separated from the grip of GPL. The tangled BLAS and GSL libraries will necessitate a wrapper library of some type, but the current form needs to go on a proprietary code diet. It's a lot of work for one-at-a-time fixes. Callbacks will be a big step in the right direction. It would be nice to get the array types at the same time. Bill ________________________________________ From: pharo-project-bounces@lists.gforge.inria.fr [pharo-project-bounces@lists.gforge.inria.fr] on behalf of Igor Stasenko [siguctua@gmail.com] Sent: Sunday, November 13, 2011 12:07 PM To: Pharo-project@lists.gforge.inria.fr Subject: Re: [Pharo-project] FFI wish list: double arrays and friends On 12 November 2011 18:43, Schwab,Wilhelm K <bschwab@anest.ufl.edu> wrote:
Sig,
Stef is hinting that you are going to have some good news about OpenGL and FFI in general. One area in which I have been fumbling along is arrays of doubles, float, signed and unsigned single and double words. Some of it is redundant and arguably more about making code written for Dolphin happy in Pharo, but the doubles really are missing. Alignment is a concern; I have been lucky. It would be nice to get it right.
I (ab)use byte arrays to hold the data, have some accessors that I seldom use (most of the access is, thankfully for speed, through functions in external libraries). Ideally, Pharo would provide a full range of double, float, signed and unsigned single and double and probably quad words with FFI awareness of all of them.
It is easy to add more types and other stuff, except that i need some real stuff to work with, like one you working on.
Where is all of this going?
My GSL interface is scarred by the past lack of support for underscores, and really needs to be rebuilt now that this is no longer a problem. It's even worse with PLplot because their function names are mystifyingly cryptic; Camel Case them and they are *completely* unrecognizable :(
Another wrinkle with GSL is that I was unable to load it (as-is) on Linux. At least at the time, there were two libraries (GSL itself and BLAS) that were inter-dependent. A library that uses both would load, but the individual libraries would not open via FFI. I put a bunch of my own code, and some proprietary code, into the library that allows the offenders to load. With license constraints and the joys of GPL, I need to separate these things before a public release.
It would be nice to clean all of this stuff at one shot and get first releases of PLplot and GSL bindings for Pharo. Callbacks would provide clean use of the minimizers and solvers in GSL, allowing me to remove a lot of confusing junk that I added to work around the missing features. It should be worth the wait.
Starting from Jan. i will focus on adding missing stuff to NativeBoost, like callbacks and code inlining. We can solve these things one by one.
Bill
-- Best regards, Igor Stasenko.
we will have some cases don't worry. JNIPort Mars? DBXTalk cairo Stef On Nov 13, 2011, at 7:07 PM, Schwab,Wilhelm K wrote:
Sig,
The problem is that I can't release the current form for various reasons. My plan is to make (roughly) 2000 methods and 135 structure definitions available, plus any other wrappers that can be separated from the grip of GPL. The tangled BLAS and GSL libraries will necessitate a wrapper library of some type, but the current form needs to go on a proprietary code diet.
It's a lot of work for one-at-a-time fixes. Callbacks will be a big step in the right direction. It would be nice to get the array types at the same time.
Bill
________________________________________ From: pharo-project-bounces@lists.gforge.inria.fr [pharo-project-bounces@lists.gforge.inria.fr] on behalf of Igor Stasenko [siguctua@gmail.com] Sent: Sunday, November 13, 2011 12:07 PM To: Pharo-project@lists.gforge.inria.fr Subject: Re: [Pharo-project] FFI wish list: double arrays and friends
On 12 November 2011 18:43, Schwab,Wilhelm K <bschwab@anest.ufl.edu> wrote:
Sig,
Stef is hinting that you are going to have some good news about OpenGL and FFI in general. One area in which I have been fumbling along is arrays of doubles, float, signed and unsigned single and double words. Some of it is redundant and arguably more about making code written for Dolphin happy in Pharo, but the doubles really are missing. Alignment is a concern; I have been lucky. It would be nice to get it right.
I (ab)use byte arrays to hold the data, have some accessors that I seldom use (most of the access is, thankfully for speed, through functions in external libraries). Ideally, Pharo would provide a full range of double, float, signed and unsigned single and double and probably quad words with FFI awareness of all of them.
It is easy to add more types and other stuff, except that i need some real stuff to work with, like one you working on.
Where is all of this going?
My GSL interface is scarred by the past lack of support for underscores, and really needs to be rebuilt now that this is no longer a problem. It's even worse with PLplot because their function names are mystifyingly cryptic; Camel Case them and they are *completely* unrecognizable :(
Another wrinkle with GSL is that I was unable to load it (as-is) on Linux. At least at the time, there were two libraries (GSL itself and BLAS) that were inter-dependent. A library that uses both would load, but the individual libraries would not open via FFI. I put a bunch of my own code, and some proprietary code, into the library that allows the offenders to load. With license constraints and the joys of GPL, I need to separate these things before a public release.
It would be nice to clean all of this stuff at one shot and get first releases of PLplot and GSL bindings for Pharo. Callbacks would provide clean use of the minimizers and solvers in GSL, allowing me to remove a lot of confusing junk that I added to work around the missing features. It should be worth the wait.
Starting from Jan. i will focus on adding missing stuff to NativeBoost, like callbacks and code inlining. We can solve these things one by one.
Bill
-- Best regards, Igor Stasenko.
participants (3)
-
Igor Stasenko -
Schwab,Wilhelm K -
Stéphane Ducasse