Softpedia
 


LINUX CATEGORIES:



GLOBAL PAGES >>
NEWS ARCHIVE >>
SOFTPEDIA REVIEWS >>
MEET THE EDITORS >>
WEEK'S BEST
  • Linux Kernel 3.9.3 / 3....
  • LibreOffice 3.6.6 / 4.0.3
  • MPlayer 1.1.1
  • systemd 204
  • Arch Linux 2013.05.01
  • Blender 2.67a
  • KDE Software Compilatio...
  • CrunchBang Linux Stable...
  • Elementary OS 0.1 / 0.2...
  • SystemRescueCd 3.6.0
  • Home > Linux > Programming > Libraries

    DynCall 0.7

    Download button

    No screenshots available
    Downloads: 459  Tell us about an update
    User Rating:
    Rated by:
    Fair (2.7/5)
    4 user(s)
    Developer:

    License / Price:

    Last Updated:

    Category:
    Daniel Adler and Tassilo Philipp | More programs
    Other/Proprietary Li... / FREE
    January 5th, 2012, 14:43 GMT [view history]
    ROOT / Programming / Libraries

     Read user reviews (0)  Refer to a friend  Subscribe

    DynCall description

    A library which encapsulates architecture-, OS- and compiler-specific function call semantics.

    DynCall is a library which encapsulates architecture-, OS- and compiler-specific function call semantics in a virtual "bind argument parameters from left to right and then call" interface allowing programmers to call C functions in a completely dynamic manner. In other words, instead of calling a function directly, the dyncall library provides a mechanism to push the function parameters manually and to issue the call afterwards.

    This means, that a program can determine at runtime what function to call, and what parameters to pass to it. The library is written in C and assembly and provides a very simple C interface to program against.

    DynCall comes in very handy to power flexible message systems, dynamic function call dispatch mechanisms, closure implementations or even to bridge different programming languages.

    When it comes to language bindings, the dyncall library provides a clean and portable C interface to dynamically issue calls to foreign code using small call kernels written in assembly. Instead of providing code for every bridged function call, which unnecessarily results in code bloat, only a couple of instructions are used to invoke every possible call.

    Example

    Let's say, we want to make a call to the function:

    double sqrt(double x);


    Using the dyncall library, this function would be called as follows:

    double r;
    DCCallVM* vm = dcNewCallVM(4096);
    dcMode(vm, DC_CALL_C_DEFAULT);
    dcArgDouble(vm, 4.2373);
    r = dcCallDouble(vm, (DCpointer)&sqrt);
    dcFree(vm);


    However, by exposing this functionality to a dynamic scripting environment, the latter can gain system programming status to a certain degree. It is easy to see the power one can get by calling a C function directly from within a scripting language. Demonstrative bindings and examples for several different scripting languages are provided with the library.


    Product's homepage

    What's New in This Release: [ read full changelog ]

    · This release includes new ports to iPhoneOS/ARM, Plan9/X86, and new calling conventions for MIPS (o32,n64).
    · It adds support for the build tools CMake, Plan9's mk, pcc compiler, and cross-compilation via iPhoneSDK.
    · It adds an error reporting facility to the library dyncall interface.
    · The library dynload's image symbol enumeration support has been expanded with support for Win64 PE and Darwin Mach-O images, as well as support for self-referencing application host images.
    · There is a major bugfix for ellipsis calls on PPC32/System V.
    · There are new additions to and improvements in test suites, and updates to the documentation.

      


    TAGS:

    encapsulates architecture | function call | call C functions | compiler | architecture | function

    Go to top

    WindowsGamesDriversMacLinuxScriptsMobileHandheldNews

    SUBMIT PROGRAM   |   ADVERTISE   |   GET HELP   |   SEND US FEEDBACK   |   RSS FEEDS   |   UPDATE YOUR SOFTWARE   |   ROMANIAN FORUM