Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 7582218a59c8d469e1310e38ca1c3c760c2a713b
Ticket: 519535ffffffffffffffffffffffffffffffffff
Call C-functions from bytecodes (rough)
User & Date: msofer on 2002-02-18 20:40:18
Changes

  1. assignee changed to: "msofer"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    *** EXPERIMENTAL PATCH ***
    
    This patch explores the possibility of calling
    C-functions from the bytecode; see the README. What it
    does is:
    
       * Incorporation of new functions with signature
          Tcl_Obj * TclCoreFun (Tcl_Interp *interp, int
    objc, 
               Tcl_Obj *CONST objv[], int argc, ClientData
    *argv);
    
         These will implement the core functionality of
    Tcl; the standard
         calls act as front ends for them.
    
         The usage is to allow receiving pointers to C
    structures that are
         determined at proc-compile time - for example, to
    variables.
    
       * Modification of the main variable access functions
    in tclVar.c to
         follow this structure. Factoring out TclLookupVar.
    
       * Definition of new instructions to
           - lookup variable pointers given their index
    (locals) or name
           - push non-Tcl_Obj items on the Tcl stack
           - call a TclCoreFun
    
       * test trial: [gets] is compiled using these
    interfaces, with a 20% 
         speed gain in the benchmarks:
    
         000 VERSIONS:                           patched   
    HEAD
         001 READ 595K, gets                      136482 
    175674
         006 READ 3050b, gets                       
    742     953
         011 READ bin 595K, gets                  145248 
    183942
         016 READ bin 3050b, gets                    803   
    1007
    
    
  4. foundin changed to: "None"
  5. priority changed to: "5 Medium"
  6. resolution changed to: "None"
  7. status changed to: "Open"
  8. submitter changed to: "msofer"
  9. subsystem changed to: "47. Bytecode Compiler"
  10. title changed to: "Call C-functions from bytecodes (rough)"
  11. type changed to: "Patch"