| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
reported by Cisco.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
error messages generated when cloning fails from the clone to
the master, for perusal by the code which activated the cloning
process. This is especially important to track syntax errors in
procedures to clone down. The code was provided by Greg Thompson
<gst@cisco.com>.
* generic/tclBasic.c (CloneNamespace): Fixed potential memory leak
due to a missing call of "Tcl_DStringFree". Reported by Greg
Thompson <gst@cisco.com>.
* generic/tclBasic.c (CloneCommand): Moved code adding the clone
to its command table to the end of the command. This makes
cleanup in case of a failure easier, there is less to roll
back. Added code to release the command strcuture if cloning the
procedure structures fails. changed from void to int, returning
a TCL_ result code.
(CloneNamespace): Changed from void to int, returning a TCL_
result code. Now reacting to the result of CloneCommand (and
itself), aborts operation in case of a failure.
(Tcl_CloneInterp): Now reacting to a failure reported by
'CloneNamespace'. Frees the fixup information accumulated so far
(via new CloneFixupFree), then deletes the partially created
interpreter via the standard 'Tcl_DeleteInterp'.
(CloneFixupFree): New function, freeing the fixup information.
|
|
|
|
|
| |
TCL_THREAD_LITERALS, do not worry about interp != NULL when
cleaning up bytecodes.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
shared bytecode structure we have to scan the literal table in
that structure for objects of type "cmdName". These objects hold
references to command structures, possibly in a different
interp, and interfere with the cleanup of the refered commands
(they keep their refcount up). Essentially at least one interp
in a set of clones has a circular reference comand -> proc ->
bytecode -> bytecode data -> cmdName obj -> command which
prevents the command int that interp from being freed, leaking
memory.
The solution employed here is to invalidate the internal
representation of 'cmdName's (but keeping the string rep),
driving the refcount of refered command structures down,
and breaking the cycle.
|
|
|
|
|
| |
literal table in thread exit handler. This causes a crash
sometimes that must be further explored.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
behind 'CloneNamespace'. This fixes the last leak found. The
function creates a variable 'tcl_traceExec', and links a C
variable to it. Running 'CloneNamespace' afterward overwrites
the pointer, leaking the structure created by
'TclCreateExecEnv'.
|
|
|
|
|
|
|
|
| |
for the cloned variable assumed that all variables are namespace
variables. This is not true. Globals are not marked as in a
namespace. This caused the system to skip freeing all global
variables in a cloned interpreter. Changed to explicitly check
the variable if it is namespace'd.
|
|
|
|
| |
handler to remove remaining literals on thread exit.
|
| |
|
|
|
|
|
| |
* unix/tclAppInit.c (main): Tcl_Finalize in -DPURIFY case to
help indentify memory leaks.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* generic/tclBasic.c: Line 3843ff: New Tcl_CloneInterp public API.
* generic/tclProc.c (TclCloneProc): See below. New function.
* generic/tclBasic.c: Tcl_Clone... functions. New. Tcl_CloneInterp
is main entry into this.
* Part of work on more sharing of bytecode information between
structurally equivalent interpreters.
* generic/tclCompile.c (EncodeCmdLocMap): Operate on ByteCodeData
instead of ByteCode.
(TclCleanupByteCode): Deref to ByteCodeData in numerous places.
(TclInitByteCodeObj): s.a.
(TclPrintByteCodeObj): s.a.
(TclPrintInstruction): s.a.
(RecordByteCodeStats): s.a.
* generic/tclLiteral.c (TclReleaseLiteral): s.a.
* generic/tclCompile.h: Split struct ByteCode into two
structures. The new structure carries the shareable bytrecode
information and is named 'ByteCodeData'.
* generic/tclExecute.c (GetExceptRangeForPc): s.a.
(TclExecuteByteCode): s.a.
(PrintByteCodeInfo): s.a.
(ValidatePcAndStackTop): s.a.
(GetSrcInfoForPc): s.a.
|
|
|
|
|
|
|
|
|
|
| |
* generic/tclCompile.c (TclCleanupByteCode, RecordByteCodeStats):
* generic/tclLiteral.c:
* generic/tclInt.h:
* generic/tclBasic.c (Tcl_CreateInterp, DeleteInterpProc): add
TCL_THREAD_LITERALS conditional support for making global literals
be thread-global instead of interp-global. This adjusts the
placement and management of the LiteralTable and ByteCodeStats.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
add the ability to take options "?all? ?bytecodes? ?instructions?
?literals?" which will filter the output.
Make EvalStats command use sprintf instead of fprintf for format
printing to support IOS.
(TclExecuteByteCode): TCL_THREAD_LITERALS support
(TclCompileByteCodesForEval): simplify code and remove final
else/if case that should never be true (repeat check of iPtr and
epoch).
(TclCompileByteCodesForExpr): better scope locals, remove last else.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* generic/tclLink.c: 'struct Link'.
* generic/tclEncoding.c: 'struct Encoding', and 'struct EscapeEncodingData'.
* generic/tclCmdIL.c: 'struct SortInfo'.
* generic/tclIO.h: 'struct ChannelState'.
* generic/tclRegexp.h: 'struct TclRegexp'.
* generic/tclCompile.h: 'struct CompileEnv', and 'struct ByteCode'.
* generic/tclInt.h: 'struct Var', 'struct ByteCodeStats', and
'struct Interp'.
Reordered fields in various structures for better usage of
memory (less padding).
|
|
|
|
| |
shared object reporting in EvalStatsCmd when used with TCL_MEM_DEBUG.
|
|
|
|
| |
initialization with one memset.
|
|
|
|
| |
the conversions, so that it works in IOS.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
a missing RELTEMP(compEnv) in line 6043 to release the structure
if the object is not of type 'bytecode'. Reported by Gregory
Thompson <gst@cisco.com>.
* generic/tclInt.h: Changed NEWTEMP, NEWSTR, and RELTEMP macros to
use 'ckalloc' and 'ckfree' instead of 'Tcl'_Alloc and
'Tcl_Free'. Suggested by Gregory Thompson <gst@cisco.com>.
|
|
|
|
|
|
|
|
| |
to use a heap variable for the message buffer instead of placing
it on the stack.
* Updated "mod-8-3-1-branch" to head of "core-8-3-1-branch" to get
the newest fixes for tcl 8.3.4 into this branch.
|
|
|
|
|
|
| |
* stack.full.html: Reports from the local version of the core
instrumented to record stack usage. 'base' - Baseline.
'full' - stack controlling macros engaged in full.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
upfront. The original contents remain and are declared to be the
scratchpad.
* tclCmdMZ.c:
* tclCompCmds.c:
* tclCompile.c:
* tclEvent.c:
* tclExecute.c:
* tclNamesp.c:
* tclParse.c:
* tclProc.c:
* tclUtil.c: More places using TCL_STRUCT_ON_HEAP.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* tcl.h:
* tclInt.h: Moved the macros to control feature exclusion and
stack manipulation into the private area of the tcl
headers. Renamed the macros for TCL_STRUCT_ON_HEAP to make their
names more sensible.
* tclCmdAH.c:
* tclCompCmds.c:
* tclCompExpr.c:
* tclCompile.c:
* tclExecute.c:
* tclIO.c:
* tclParse.c:
* tclParseExpr.c:
* tclScan.c:
* tclUnixChan.c: Adapted to changed macro names, added some more
places there structures go on the heap instead of the stack.
Fixed a problem with TCL_FMT_STATIC_FLOATBUFFER_SZ which
caused the interp to crash when actually used to reduce the
usage of the stack.
|
|
|
|
|
| |
macros for information on the stack. Parser information on the
stack can now be switched to allocation on the heap.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
interdependencies, implications, etc.
* static.sizes.html: New file. Report on the cuts achieved so
far. Regarding the object files only the files which did change
in size are reported. Usage of the MODULAR_TCL macro currently
cuts about 17 % of the code (measured using strip'ped object
files and libraries).
* Changed files so far .. [cut, see changelog for full list]
* Working on modularization of the tcl core.
***************************
**** mod-8-3-4-branch ****
***************************
|
|
|
|
|
|
| |
cast expression to remove ambiguity and conform with Tcl
Engineering Manual. [Suggestion by Donal Fellows in commentary on
patch #483500]
|
|
|
|
|
| |
when dealing with test sequences that run more than 2**31
microseconds. [Bug 478847]
|
|
|
|
|
| |
* generic/tclVar.c: Corrected bug in [global] when dealing
with variable names matching :*. [Bug 480176]
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
folders
* mac/tclMacLoad.c: : corrected utf8 handling, comparison of
package names to code fragment names changed to only match on the
length of package name, this allows for fragment names with version
numbers appended (backport from 8.4)
|
| |
|
|
|
|
| |
* unix/tcl.m4 (SC_ENABLE_GCC): enabled better recognition of gcc.
|
|
|
|
|
|
|
| |
* generic/tclDate.c (RelativeMonth):
* generic/tclGetDate.y (RelativeMonth): corrected off-by-one-day
error in clock scan with relative months and years during swing
hours. [Bug #413397, Patch #414024] (lavana)
|
| |
|
|
|
|
|
| |
retry when error is returned with errno == EINTR.
[Bug #415131] (leger)
|
| |
|
| |
|
| |
|
|
|
|
|
| |
* unix/configure.in: added preset CFLAGS check from HEAD to
prevent --enable-gcc from adding "-g -O2"
|
| |
|
| |
|
| |
|
|
|
|
|
| |
to $TCL_EXEC_PREFIX/lib. It contains platform-dependent
definitions, and must not be installed under $TCL_PREFIX.
|