Lowcode 
Redoing NativeBoost Portably 
Ronie Salgado
The Current FFI Problem 
● SqueakFFI/ThreadedFFI, Alien, NativeBoost. 
● The callbacks 
● Performance 
● Raw memory manipu...
Ways of interfacing with C 
● Extend the Interpreter. Done in Java(JNI), Lua, 
Python 
● Just call. Done in .Net, D
Extending the Interpreter 
Python Example. Source: https://docs.python.org/2/extending/extending.html
Just Calling
Why I do not like NativeBoost
More Portable
What I would like to do 
ffiFloat32AtOffsetPut: zeroBasedOffset put: value 
(float*)self atOffset: zeroBasedOffset put: va...
What I also want to do 
ffiFloat32AtOffsetPut: zeroBasedOffset put: value { 
((float*)self)[0] = value; 
}
How it is done 
● Extend the Sista Extended Bytecode set. 
● Expose basic CPU primitive type. 
● Implemented in the VM. 
●...
Many Backends 
● C Interpreter plugin. (Done) 
● C++ LLVM plugin. (Done) 
● VirtualCPU. (Incomplete) 
● StackInterpreter. ...
Upcoming SlideShare
Loading in …5
×

Lowcode: Redoing NativeBoost Portably

558 views
496 views

Published on

Show Us Your Project, ESUG 2014, Cambridge
Speaker: Ronie Salgado

Published in: Software
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
558
On SlideShare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
4
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Lowcode: Redoing NativeBoost Portably

  1. 1. Lowcode Redoing NativeBoost Portably Ronie Salgado
  2. 2. The Current FFI Problem ● SqueakFFI/ThreadedFFI, Alien, NativeBoost. ● The callbacks ● Performance ● Raw memory manipulation?
  3. 3. Ways of interfacing with C ● Extend the Interpreter. Done in Java(JNI), Lua, Python ● Just call. Done in .Net, D
  4. 4. Extending the Interpreter Python Example. Source: https://docs.python.org/2/extending/extending.html
  5. 5. Just Calling
  6. 6. Why I do not like NativeBoost
  7. 7. More Portable
  8. 8. What I would like to do ffiFloat32AtOffsetPut: zeroBasedOffset put: value (float*)self atOffset: zeroBasedOffset put: value The actual syntax has to be discussed.
  9. 9. What I also want to do ffiFloat32AtOffsetPut: zeroBasedOffset put: value { ((float*)self)[0] = value; }
  10. 10. How it is done ● Extend the Sista Extended Bytecode set. ● Expose basic CPU primitive type. ● Implemented in the VM. ● Implemented in plugins.
  11. 11. Many Backends ● C Interpreter plugin. (Done) ● C++ LLVM plugin. (Done) ● VirtualCPU. (Incomplete) ● StackInterpreter. (ToDo) ● Cogit. (ToDo)

×