All --

I just committed the first chunk of stuff to make dynamic oplib
loading work. This is an early step. The most interesting stuff
is yet to come. For now, the code is only exercised when the -P
(predereferencing) option to test_parrot is used. We still link
core_ops.c in statically, but we dynamically load the prederef
version if -P is used. This isn't the real intent of oplib
dynaloading, though. It will be use to load oplibs *in addition
to* rather than *instead of* core.ops. Also, please note that
the prederef stuff probably has limited remaining usefulness,
at least in its current form.

Here is the log from the commit:


  Initial code for dynamic loading of oplibs, applied for now to the
  loading of the core_prederef oplib when the -P flag is passed to
  test_parrot.
  
    * MANIFEST: Added entry for the new file include/parrot/oplib.h.
  
    * Makefile.in:
  
        * Added libcore_prederef_0_3.so to the shared target.
        * Added build rule for libcore_prederef_0_3.so.
        * Added dependencies on Parrot/OpsFile.pm and Parrot/Op.pm
          to Parrot/OpLib/core.pm, core_ops.c and
          core_ops_prederef.c.
  
    * config_h.in: Added defines for constants used to locate the
      core oplib's init function, and the core_prederef oplib for
      dynaloading.
  
    * core.ops: Added a VERSION = 0.3 line near the top. This is now
      required by Parrot/OpsFile.pm.
  
    * interpreter.c:
  
        * Added init_prederef() and stop_prederef() functions to load
          and unload the core_prederef oplib when we are in prederef
          mode.
  
          NOTE: In all likelihood, the prederef stuff has a rapidly
          dwindling time-to-live. The JIT should provide vastly superior
          performance, and loading an alternate set of core_ops isn't
          the real direction for the dynaloading stuff. Loading
          *additional* ops is. It does provide a handy test case for the
          general idea for now, though.
  
        * Gets the core copcode table, etc. via the core oplibs oplib
          info pointer, as returned by the core oplib's init function.
  
    * ops2c.pl
  
        * Make use of the version, major version and minor version
          stuff parsed by Parrot/OpsFile.pm
  
        * The only exported symbol in the generated files is the init
          function now, since that returns an oplib info struct
          pointer, and all the important stuff can be found there.
  
    * ops2pm.pl: Put the oplib version in the generated .pm file.
  
    * test_main.c: Small changes necessitated by changes in the names
      of some members of the interpreter struct.
  
    * trace.c: Small changes necessitated by changes in the names
      of some members of the interpreter struct.
  
    * Parrot/OpsFile.pm: Require a "VERSION = x.y" line before any
      ops are found.
  
    * include/parrot/interp_guts.h: Small changes necessitated by
      changes in the names of some members of the interpreter struct.
  
    * include/parrot/interpreter.h: Include the new
      include/parrot/oplib.h header. Small changes to the oplib-
      related members.
  
    * include/parrot/oplib.h: Define the type of the oplib init
      function, and the struct type for the oplib info.
  
    * platforms/*.[hc]: Remove the second argument to Parrot_dlopen()
      since not all platforms have it. For those that do, a default
      second argument is provided.


Regards,

-- Gregor
 ____________________________________________________________________ 
/            Inspiration >> Innovation >> Excellence (TM)            \

   Gregor N. Purdy                         [EMAIL PROTECTED]
   Focus Research, Inc.               http://www.focusresearch.com/
   8080 Beckett Center Drive #203                  513-860-3570 vox
   West Chester, OH 45069                          513-860-3579 fax
\____________________________________________________________________/

[[EMAIL PROTECTED]]$ ping osama.taliban.af
PING osama.taliban.af (68.69.65.68) from 20.1.9.11 : 56 bytes of data.
>From 85.83.77.67: Time to live exceeded

Reply via email to