From: <AO...@t-...> - 2002-03-14 11:19:50
|
Hi, I made some research on startup performance it is very very slow on my ppc 500MHz compare to my Athlon 500 MHz 1) reading the resources form a executable is >>>> very very slow <<<<< never use this. In POWER-Tcl is disable this in tclPkgUnknown and its fast :) >>>>>>>>>>>>>>>>>>>>>>>>>>>>> # # On the Macintosh we also look in the resource fork # # of shared libraries # # We can't use tclMacPkgSearch in safe interps because it uses glob # if {(![interp issafe]) && \ # [string equal $tcl_platform(platform) "macintosh"]} { # set dir [lindex $use_path end] # if {![info exists procdDirs($dir)]} { # tclMacPkgSearch $dir # set procdDirs($dir) 1 # } # foreach x [glob -directory $dir -nocomplain *] { # if {[file isdirectory $x] && ![info exists procdDirs($x)]} { # set dir $x # tclMacPkgSearch $dir # set procdDirs($dir) 1 # } # } # } <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 2) I use the traditional old well known TCL_LIBRARY to point to the tcl library it works 3) blow away the the resources from -> tclMacResource.r change into >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> /* * The mechanisim below loads Tcl source into the resource fork of the * application. The example below creates a TEXT resource named * "Init" from the file "init.tcl". This allows applications to use * Tcl to define the behavior of the application without having to * require some predetermined file structure - all needed Tcl "files" * are located within the application. To source a file for the * resource fork the source command has been modified to support * sourcing from resources. In the below case "source -rsrc {Init}" * will load the TEXT resource named "Init". */ /* NO PERFORMANCE #include "tclMacTclCode.r" */ <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< the final POWER-Tcl distribution on "mac91ppc" ,thats my new target, will have SysIndex. This is a feature to limit startup-time to close 0 yes to close 0 :) mfg aotto :) |