Branch: Tag:

1996-09-22

1996-09-22 19:40:33 by Fredrik Hübinette (Hubbe) <hubbe@hubbe.net>

Pike

Rev: .cvsignore:1.1.1.1
Rev: README:1.1.1.1
Rev: bin/export.pike:1.1.1.1
Rev: bin/fixdepends.sh:1.1.1.1
Rev: bin/hilfe:1.1.1.1
Rev: bin/htmlify_docs.pike:1.1.1.1
Rev: bin/httpd.pike:1.1.1.1
Rev: bin/metatest:1.1.1.1
Rev: bin/mkpeep.pike:1.1.1.1
Rev: bin/rsif:1.1.1.1
Rev: doc/README:1.1.1.1
Rev: doc/builtin/_verify_internals:1.1.1.1
Rev: doc/builtin/add_constant:1.1.1.1
Rev: doc/builtin/aggregage_multiset:1.1.1.1
Rev: doc/builtin/aggregate:1.1.1.1
Rev: doc/builtin/aggregate_mapping:1.1.1.1
Rev: doc/builtin/alarm:1.1.1.1
Rev: doc/builtin/all_constants:1.1.1.1
Rev: doc/builtin/allocate:1.1.1.1
Rev: doc/builtin/arrayp:1.1.1.1
Rev: doc/builtin/backtrace:1.1.1.1
Rev: doc/builtin/call_function:1.1.1.1
Rev: doc/builtin/clone:1.1.1.1
Rev: doc/builtin/column:1.1.1.1
Rev: doc/builtin/combine_path:1.1.1.1
Rev: doc/builtin/compile_file:1.1.1.1
Rev: doc/builtin/compile_string:1.1.1.1
Rev: doc/builtin/copy_value:1.1.1.1
Rev: doc/builtin/crypt:1.1.1.1
Rev: doc/builtin/ctime:1.1.1.1
Rev: doc/builtin/destruct:1.1.1.1
Rev: doc/builtin/equal:1.1.1.1
Rev: doc/builtin/exit:1.1.1.1
Rev: doc/builtin/floatp:1.1.1.1
Rev: doc/builtin/function_name:1.1.1.1
Rev: doc/builtin/function_object:1.1.1.1
Rev: doc/builtin/functionp:1.1.1.1
Rev: doc/builtin/gc:1.1.1.1
Rev: doc/builtin/getpid:1.1.1.1
Rev: doc/builtin/glob:1.1.1.1
Rev: doc/builtin/hash:1.1.1.1
Rev: doc/builtin/indices:1.1.1.1
Rev: doc/builtin/intp:1.1.1.1
Rev: doc/builtin/kill:1.1.1.1
Rev: doc/builtin/localtime:1.1.1.1
Rev: doc/builtin/lower_case:1.1.1.1
Rev: doc/builtin/m_delete:1.1.1.1
Rev: doc/builtin/mappingp:1.1.1.1
Rev: doc/builtin/mkmapping:1.1.1.1
Rev: doc/builtin/multisetp:1.1.1.1
Rev: doc/builtin/next_object:1.1.1.1
Rev: doc/builtin/object_program:1.1.1.1
Rev: doc/builtin/objectp:1.1.1.1
Rev: doc/builtin/programp:1.1.1.1
Rev: doc/builtin/query_host_name:1.1.1.1
Rev: doc/builtin/query_num_arg:1.1.1.1
Rev: doc/builtin/random:1.1.1.1
Rev: doc/builtin/random_seed:1.1.1.1
Rev: doc/builtin/replace:1.1.1.1
Rev: doc/builtin/reverse:1.1.1.1
Rev: doc/builtin/rows:1.1.1.1
Rev: doc/builtin/rusage:1.1.1.1
Rev: doc/builtin/search:1.1.1.1
Rev: doc/builtin/signal:1.1.1.1
Rev: doc/builtin/signame:1.1.1.1
Rev: doc/builtin/signum:1.1.1.1
Rev: doc/builtin/sizeof:1.1.1.1
Rev: doc/builtin/sleep:1.1.1.1
Rev: doc/builtin/sort:1.1.1.1
Rev: doc/builtin/stringp:1.1.1.1
Rev: doc/builtin/this_object:1.1.1.1
Rev: doc/builtin/throw:1.1.1.1
Rev: doc/builtin/time:1.1.1.1
Rev: doc/builtin/trace:1.1.1.1
Rev: doc/builtin/ualarm:1.1.1.1
Rev: doc/builtin/upper_case:1.1.1.1
Rev: doc/builtin/values:1.1.1.1
Rev: doc/builtin/zero_type:1.1.1.1
Rev: doc/index.bmml:1.1.1.1
Rev: doc/manual/example1:1.1.1.1
Rev: doc/manual/example2:1.1.1.1
Rev: doc/manual/example3:1.1.1.1
Rev: doc/manual/tutorial:1.1.1.1
Rev: doc/operators/and:1.1.1.1
Rev: doc/operators/complement:1.1.1.1
Rev: doc/operators/divide:1.1.1.1
Rev: doc/operators/index:1.1.1.1
Rev: doc/operators/is_equal:1.1.1.1
Rev: doc/operators/is_greater_or_equal:1.1.1.1
Rev: doc/operators/is_greater_than:1.1.1.1
Rev: doc/operators/is_lesser_or_equal:1.1.1.1
Rev: doc/operators/is_lesser_than:1.1.1.1
Rev: doc/operators/logical_and:1.1.1.1
Rev: doc/operators/logical_or:1.1.1.1
Rev: doc/operators/minus:1.1.1.1
Rev: doc/operators/modulo:1.1.1.1
Rev: doc/operators/mult:1.1.1.1
Rev: doc/operators/not:1.1.1.1
Rev: doc/operators/not_equal:1.1.1.1
Rev: doc/operators/operators:1.1.1.1
Rev: doc/operators/or:1.1.1.1
Rev: doc/operators/plus:1.1.1.1
Rev: doc/operators/range:1.1.1.1
Rev: doc/operators/shift_left:1.1.1.1
Rev: doc/operators/shift_right:1.1.1.1
Rev: doc/operators/xor:1.1.1.1
Rev: doc/pike/all.bmml:1.1.1.1
Rev: doc/pike/cast:1.1.1.1
Rev: doc/pike/catch:1.1.1.1
Rev: doc/pike/class:1.1.1.1
Rev: doc/pike/command_line_options:1.1.1.1
Rev: doc/pike/control_structures/break:1.1.1.1
Rev: doc/pike/control_structures/catch:1.1.1.1
Rev: doc/pike/control_structures/continue:1.1.1.1
Rev: doc/pike/control_structures/do-while:1.1.1.1
Rev: doc/pike/control_structures/for:1.1.1.1
Rev: doc/pike/control_structures/foreach:1.1.1.1
Rev: doc/pike/control_structures/if-else:1.1.1.1
Rev: doc/pike/control_structures/return:1.1.1.1
Rev: doc/pike/control_structures/switch:1.1.1.1
Rev: doc/pike/control_structures/while:1.1.1.1
Rev: doc/pike/efuns.bmml:1.1.1.1
Rev: doc/pike/functions:1.1.1.1
Rev: doc/pike/gauge:1.1.1.1
Rev: doc/pike/hilfe:1.1.1.1
Rev: doc/pike/how_to_make_modules:1.1.1.1
Rev: doc/pike/inherit:1.1.1.1
Rev: doc/pike/lambda:1.1.1.1
Rev: doc/pike/modifier:1.1.1.1
Rev: doc/pike/preprocessor:1.1.1.1
Rev: doc/pike/reserved.bmml:1.1.1.1
Rev: doc/pike/sscanf:1.1.1.1
Rev: doc/pike/typeof:1.1.1.1
Rev: doc/pike/variables:1.1.1.1
Rev: doc/simulated/PI:1.1.1.1
Rev: doc/simulated/add_efun:1.1.1.1
Rev: doc/simulated/aggregage_list:1.1.1.1
Rev: doc/simulated/all_efuns:1.1.1.1
Rev: doc/simulated/capitalize:1.1.1.1
Rev: doc/simulated/describe_backtrace:1.1.1.1
Rev: doc/simulated/exec:1.1.1.1
Rev: doc/simulated/explode:1.1.1.1
Rev: doc/simulated/file_size:1.1.1.1
Rev: doc/simulated/filter:1.1.1.1
Rev: doc/simulated/filter_array:1.1.1.1
Rev: doc/simulated/get_function:1.1.1.1
Rev: doc/simulated/getenv:1.1.1.1
Rev: doc/simulated/implode:1.1.1.1
Rev: doc/simulated/l_sizeof:1.1.1.1
Rev: doc/simulated/listp:1.1.1.1
Rev: doc/simulated/m_indices:1.1.1.1
Rev: doc/simulated/m_sizeof:1.1.1.1
Rev: doc/simulated/m_values:1.1.1.1
Rev: doc/simulated/map:1.1.1.1
Rev: doc/simulated/map_array:1.1.1.1
Rev: doc/simulated/master:1.1.1.1
Rev: doc/simulated/member_array:1.1.1.1
Rev: doc/simulated/mklist:1.1.1.1
Rev: doc/simulated/mkmultiset:1.1.1.1
Rev: doc/simulated/perror:1.1.1.1
Rev: doc/simulated/popen:1.1.1.1
Rev: doc/simulated/previous_object:1.1.1.1
Rev: doc/simulated/putenv:1.1.1.1
Rev: doc/simulated/read_bytes:1.1.1.1
Rev: doc/simulated/regexp:1.1.1.1
Rev: doc/simulated/search_array:1.1.1.1
Rev: doc/simulated/sort_array:1.1.1.1
Rev: doc/simulated/spawn:1.1.1.1
Rev: doc/simulated/strlen:1.1.1.1
Rev: doc/simulated/strstr:1.1.1.1
Rev: doc/simulated/sum:1.1.1.1
Rev: doc/simulated/sum_arrays:1.1.1.1
Rev: doc/simulated/system:1.1.1.1
Rev: doc/simulated/this_function:1.1.1.1
Rev: doc/simulated/version:1.1.1.1
Rev: doc/simulated/write:1.1.1.1
Rev: doc/simulated/write_file:1.1.1.1
Rev: doc/types/array:1.1.1.1
Rev: doc/types/float:1.1.1.1
Rev: doc/types/function:1.1.1.1
Rev: doc/types/int:1.1.1.1
Rev: doc/types/mapping:1.1.1.1
Rev: doc/types/mixed:1.1.1.1
Rev: doc/types/multiset:1.1.1.1
Rev: doc/types/object:1.1.1.1
Rev: doc/types/program:1.1.1.1
Rev: doc/types/string:1.1.1.1
Rev: lib/include/array.h:1.1.1.1
Rev: lib/include/array.pre.pike:1.1.1.1
Rev: lib/include/process.h:1.1.1.1
Rev: lib/include/process.pre.pike:1.1.1.1
Rev: lib/include/simulate.h:1.1.1.1
Rev: lib/include/simulate.pre.pike:1.1.1.1
Rev: lib/include/stdio.h:1.1.1.1
Rev: lib/include/stdio.pre.pike:1.1.1.1
Rev: lib/master.pike:1.1.1.1
Rev: src/.cvsignore:1.1.1.1
Rev: src/BUGS:1.1.1.1
Rev: src/COPYING:1.1.1.1
Rev: src/COPYRIGHT:1.1.1.1
Rev: src/ChangeLog:1.1.1.1
Rev: src/DISCLAIMER:1.1.1.1
Rev: src/Makefile.src:1.1.1.1
Rev: src/README:1.1.1.1
Rev: src/alloca.c:1.1.1.1
Rev: src/array.c:1.1.1.1
Rev: src/array.h:1.1.1.1
Rev: src/backend.c:1.1.1.1
Rev: src/backend.h:1.1.1.1
Rev: src/build_modlist_h:1.1.1.1
Rev: src/builtin_functions.c:1.1.1.1
Rev: src/builtin_functions.h:1.1.1.1
Rev: src/callback.c:1.1.1.1
Rev: src/callback.h:1.1.1.1
Rev: src/compilation.h:1.1.1.1
Rev: src/config.cache:1.1.1.1
Rev: src/config.h:1.1.1.1
Rev: src/config.log:1.1.1.1
Rev: src/configure.in:1.1.1.1
Rev: src/constants.c:1.1.1.1
Rev: src/constants.h:1.1.1.1
Rev: src/docode.c:1.1.1.1
Rev: src/docode.h:1.1.1.1
Rev: src/dynamic_buffer.c:1.1.1.1
Rev: src/dynamic_buffer.h:1.1.1.1
Rev: src/efun.h:1.1.1.1
Rev: src/error.c:1.1.1.1
Rev: src/error.h:1.1.1.1
Rev: src/fd_control.c:1.1.1.1
Rev: src/fd_control.h:1.1.1.1
Rev: src/fsort.c:1.1.1.1
Rev: src/fsort.h:1.1.1.1
Rev: src/gc.c:1.1.1.1
Rev: src/gc.h:1.1.1.1
Rev: src/global.h:1.1.1.1
Rev: src/hashtable.c:1.1.1.1
Rev: src/hashtable.h:1.1.1.1
Rev: src/install-sh:1.1.1.1
Rev: src/interpret.c:1.1.1.1
Rev: src/interpret.h:1.1.1.1
Rev: src/language.y:1.1.1.1
Rev: src/las.c:1.1.1.1
Rev: src/las.h:1.1.1.1
Rev: src/lex.c:1.1.1.1
Rev: src/lex.h:1.1.1.1
Rev: src/machine.h.in:1.1.1.1
Rev: src/macros.h:1.1.1.1
Rev: src/main.c:1.1.1.1
Rev: src/main.h:1.1.1.1
Rev: src/mapping.c:1.1.1.1
Rev: src/mapping.h:1.1.1.1
Rev: src/memory.c:1.1.1.1
Rev: src/memory.h:1.1.1.1
Rev: src/module.c:1.1.1.1
Rev: src/module.h:1.1.1.1
Rev: src/modules/.cvsignore:1.1.1.1
Rev: src/modules/Makefile.src:1.1.1.1
Rev: src/modules/call_out/.cvsignore:1.1.1.1
Rev: src/modules/call_out/Makefile.src:1.1.1.1
Rev: src/modules/call_out/call_out.c:1.1.1.1
Rev: src/modules/call_out/configure.in:1.1.1.1
Rev: src/modules/call_out/doc/call_out:1.1.1.1
Rev: src/modules/call_out/doc/call_out_info:1.1.1.1
Rev: src/modules/call_out/doc/find_call_out:1.1.1.1
Rev: src/modules/call_out/doc/remove_call_out:1.1.1.1
Rev: src/modules/configure.in:1.1.1.1
Rev: src/modules/files/.cvsignore:1.1.1.1
Rev: src/modules/files/Makefile.src:1.1.1.1
Rev: src/modules/files/configure.in:1.1.1.1
Rev: src/modules/files/datagram.c:1.1.1.1
Rev: src/modules/files/doc/cd:1.1.1.1
Rev: src/modules/files/doc/errno:1.1.1.1
Rev: src/modules/files/doc/exece:1.1.1.1
Rev: src/modules/files/doc/file:1.1.1.1
Rev: src/modules/files/doc/file_stat:1.1.1.1
Rev: src/modules/files/doc/fork:1.1.1.1
Rev: src/modules/files/doc/get_dir:1.1.1.1
Rev: src/modules/files/doc/getcwd:1.1.1.1
Rev: src/modules/files/doc/mkdir:1.1.1.1
Rev: src/modules/files/doc/mv:1.1.1.1
Rev: src/modules/files/doc/port:1.1.1.1
Rev: src/modules/files/doc/rm:1.1.1.1
Rev: src/modules/files/doc/strerror:1.1.1.1
Rev: src/modules/files/doc/werror:1.1.1.1
Rev: src/modules/files/efuns.c:1.1.1.1
Rev: src/modules/files/file.c:1.1.1.1
Rev: src/modules/files/file.h:1.1.1.1
Rev: src/modules/files/file_machine.h.in:1.1.1.1
Rev: src/modules/files/socket.c:1.1.1.1
Rev: src/modules/gdbmmod/.cvsignore:1.1.1.1
Rev: src/modules/gdbmmod/Makefile.src:1.1.1.1
Rev: src/modules/gdbmmod/configure.in:1.1.1.1
Rev: src/modules/gdbmmod/doc/gdbm:1.1.1.1
Rev: src/modules/gdbmmod/gdbm_machine.h.in:1.1.1.1
Rev: src/modules/gdbmmod/gdbmmod.c:1.1.1.1
Rev: src/modules/gmpmod/.cvsignore:1.1.1.1
Rev: src/modules/gmpmod/Makefile.src:1.1.1.1
Rev: src/modules/gmpmod/configure.in:1.1.1.1
Rev: src/modules/gmpmod/doc/mpz:1.1.1.1
Rev: src/modules/gmpmod/gmp_machine.h.in:1.1.1.1
Rev: src/modules/gmpmod/mpz_glue.c:1.1.1.1
Rev: src/modules/image/Makefile.in:1.1.1.1
Rev: src/modules/image/Makefile.src:1.1.1.1
Rev: src/modules/image/configure:1.1.1.1
Rev: src/modules/image/configure.in:1.1.1.1
Rev: src/modules/image/dependencies:1.1.1.1
Rev: src/modules/image/doc.txt:1.1.1.1
Rev: src/modules/image/doc/image.html:1.1.1.1
Rev: src/modules/image/font.c:1.1.1.1
Rev: src/modules/image/image.c:1.1.1.1
Rev: src/modules/image/image.h:1.1.1.1
Rev: src/modules/image/lzw.c:1.1.1.1
Rev: src/modules/image/lzw.h:1.1.1.1
Rev: src/modules/image/quant.c:1.1.1.1
Rev: src/modules/image/togif.c:1.1.1.1
Rev: src/modules/math/.cvsignore:1.1.1.1
Rev: src/modules/math/Makefile.src:1.1.1.1
Rev: src/modules/math/configure.in:1.1.1.1
Rev: src/modules/math/doc/acos:1.1.1.1
Rev: src/modules/math/doc/asin:1.1.1.1
Rev: src/modules/math/doc/atan:1.1.1.1
Rev: src/modules/math/doc/ceil:1.1.1.1
Rev: src/modules/math/doc/cos:1.1.1.1
Rev: src/modules/math/doc/exp:1.1.1.1
Rev: src/modules/math/doc/floor:1.1.1.1
Rev: src/modules/math/doc/log:1.1.1.1
Rev: src/modules/math/doc/pow:1.1.1.1
Rev: src/modules/math/doc/sin:1.1.1.1
Rev: src/modules/math/doc/sqrt:1.1.1.1
Rev: src/modules/math/doc/tan:1.1.1.1
Rev: src/modules/math/math.c:1.1.1.1
Rev: src/modules/module_dir_marker:1.1.1.1
Rev: src/modules/pipe/Makefile.in:1.1.1.1
Rev: src/modules/pipe/Makefile.src:1.1.1.1
Rev: src/modules/pipe/config.h:1.1.1.1
Rev: src/modules/pipe/configure:1.1.1.1
Rev: src/modules/pipe/configure.in:1.1.1.1
Rev: src/modules/pipe/dependencies:1.1.1.1
Rev: src/modules/pipe/pipe.c:1.1.1.1
Rev: src/modules/readlinemod/.cvsignore:1.1.1.1
Rev: src/modules/readlinemod/Makefile.src:1.1.1.1
Rev: src/modules/readlinemod/configure.in:1.1.1.1
Rev: src/modules/readlinemod/doc/readline:1.1.1.1
Rev: src/modules/readlinemod/readline_machine.h.in:1.1.1.1
Rev: src/modules/readlinemod/readlinemod.c:1.1.1.1
Rev: src/modules/regexp/.cvsignore:1.1.1.1
Rev: src/modules/regexp/Makefile.src:1.1.1.1
Rev: src/modules/regexp/configure.in:1.1.1.1
Rev: src/modules/regexp/doc/regexp:1.1.1.1
Rev: src/modules/regexp/glue.c:1.1.1.1
Rev: src/modules/regexp/regexp.c:1.1.1.1
Rev: src/modules/regexp/regexp.h:1.1.1.1
Rev: src/modules/spider/Makefile.in:1.1.1.1
Rev: src/modules/spider/Makefile.src:1.1.1.1
Rev: src/modules/spider/configure:1.1.1.1
Rev: src/modules/spider/configure.in:1.1.1.1
Rev: src/modules/spider/defs.h:1.1.1.1
Rev: src/modules/spider/dependencies:1.1.1.1
Rev: src/modules/spider/discdate.c:1.1.1.1
Rev: src/modules/spider/encode_decode.c:1.1.1.1
Rev: src/modules/spider/http_parse.c:1.1.1.1
Rev: src/modules/spider/lock.c:1.1.1.1
Rev: src/modules/spider/lock.h:1.1.1.1
Rev: src/modules/spider/sdebug.c:1.1.1.1
Rev: src/modules/spider/shared_mem_mapping.c:1.1.1.1
Rev: src/modules/spider/sharedmem.c:1.1.1.1
Rev: src/modules/spider/sharedmem.h:1.1.1.1
Rev: src/modules/spider/spider.c:1.1.1.1
Rev: src/modules/spider/spider.h.in:1.1.1.1
Rev: src/modules/spider/stardate.c:1.1.1.1
Rev: src/modules/spider/streamed_parser.c:1.1.1.1
Rev: src/modules/spider/streamed_parser.h:1.1.1.1
Rev: src/modules/spider/tree.c:1.1.1.1
Rev: src/modules/sprintf/.cvsignore:1.1.1.1
Rev: src/modules/sprintf/Makefile.src:1.1.1.1
Rev: src/modules/sprintf/configure.in:1.1.1.1
Rev: src/modules/sprintf/doc/sprintf:1.1.1.1
Rev: src/modules/sprintf/sprintf.c:1.1.1.1
Rev: src/multiset.c:1.1.1.1
Rev: src/multiset.h:1.1.1.1
Rev: src/object.c:1.1.1.1
Rev: src/object.h:1.1.1.1
Rev: src/opcodes.c:1.1.1.1
Rev: src/opcodes.h:1.1.1.1
Rev: src/operators.c:1.1.1.1
Rev: src/operators.h:1.1.1.1
Rev: src/otable.h:1.1.1.1
Rev: src/peep.c:1.1.1.1
Rev: src/peep.h:1.1.1.1
Rev: src/peep.in:1.1.1.1
Rev: src/pike_types.c:1.1.1.1
Rev: src/pike_types.h:1.1.1.1
Rev: src/port.c:1.1.1.1
Rev: src/port.h:1.1.1.1
Rev: src/program.c:1.1.1.1
Rev: src/program.h:1.1.1.1
Rev: src/run_autoconfig:1.1.1.1
Rev: src/rusage.c:1.1.1.1
Rev: src/rusage.h:1.1.1.1
Rev: src/signal_handler.c:1.1.1.1
Rev: src/signal_handler.h:1.1.1.1
Rev: src/stamp-h:1.1.1.1
Rev: src/stralloc.c:1.1.1.1
Rev: src/stralloc.h:1.1.1.1
Rev: src/stuff.c:1.1.1.1
Rev: src/stuff.h:1.1.1.1
Rev: src/svalue.c:1.1.1.1
Rev: src/svalue.h:1.1.1.1
Rev: src/test/.cvsignore:1.1.1.1
Rev: src/test/create_testsuite:1.1.1.1
Rev: src/test/test_pike.pike:1.1.1.1
Rev: src/time_stuff.h:1.1.1.1
Rev: src/todo:1.1.1.1
Rev: src/types.h:1.1.1.1
Rev: src/ualarm.c:1.1.1.1

1:   /*\ - ||| This file a part of uLPC, and is copyright by Fredrik Hubinette - ||| uLPC is distributed as GPL (General Public License) + ||| This file a part of Pike, and is copyright by Fredrik Hubinette + ||| Pike is distributed as GPL (General Public License)   ||| See the files COPYING and DISCLAIMER for more information.   \*/   #include "global.h"
13:   #include "error.h"   #include "language.h"   #include "stralloc.h" - #include "add_efun.h" + #include "constants.h"   #include "macros.h" - #include "list.h" + #include "multiset.h"   #include "backend.h"   #include "operators.h"   #include "opcodes.h"   #include "main.h"   #include "lex.h" - #include "builtin_efuns.h" - #include "lpc_signal.h" + #include "builtin_functions.h" + #include "signal_handler.h" + #include "gc.h"    - #define TRACE_LEN 256 - struct svalue evaluator_stack[EVALUATOR_STACK_SIZE]; - struct svalue *mark_stack[EVALUATOR_STACK_SIZE]; - struct frame *fp; /* frame pointer */ + #ifdef HAVE_MMAP + #ifdef HAVE_SYS_TYPES_H + #include <sys/types.h> + #endif    -  + #ifdef HAVE_SYS_MMAN_H + #include <sys/mman.h> + #endif +  + #ifdef MAP_NORESERVE + #define USE_MMAP_FOR_STACK + #endif + #endif +  + #define TRACE_LEN (100 + t_flag * 10) +  +    /* sp points to first unused value on stack    * (much simpler than letting it point at the last used value.)    */ - struct svalue *sp=evaluator_stack; + struct svalue *sp; /* Current position */ + struct svalue *evaluator_stack; /* Start of stack */ + int stack_size = EVALUATOR_STACK_SIZE;      /* mark stack, used to store markers into the normal stack */ - struct svalue **mark_sp=mark_stack; + struct svalue **mark_sp; /* Current position */ + struct svalue **mark_stack; /* Start of stack */    -  + struct frame *fp; /* frame pointer */ +  + void init_interpreter() + { + #ifdef USE_MMAP_FOR_STACK +  int fd; +  + #ifndef MAP_VARIABLE + #define MAP_VARIABLE 0 + #endif +  + #ifndef MAP_PRIVATE + #define MAP_PRIVATE 0 + #endif +  + #ifdef MAP_ANONYMOUS +  fd=-1; + #else + #define MAP_ANONYMOUS 0 +  fd=open("/dev/zero"); +  if(fd < 0) fatal("Failed to open /dev/zero.\n"); + #endif +  + #define MMALLOC(X,Y) (Y *)mmap(0,X*sizeof(Y),PROT_READ|PROT_WRITE, MAP_NORESERVE | MAP_PRIVATE | MAP_ANONYMOUS, fd, 0) +  +  evaluator_stack=MMALLOC(stack_size,struct svalue); +  mark_stack=MMALLOC(stack_size, struct svalue *); +  +  if(fd != -1) close(fd); +  +  if(!evaluator_stack || !mark_stack) fatal("Failed to mmap() stack space.\n"); + #else +  evaluator_stack=(struct svalue *)malloc(stack_size*sizeof(struct svalue)); +  mark_stack=(struct svalue **)malloc(stack_size*sizeof(struct svalue *)); + #endif +  sp=evaluator_stack; +  mark_sp=mark_stack; + } +  + void check_stack(INT32 size) + { +  if(sp - evaluator_stack + size >= stack_size) +  error("Stack overflow.\n"); + } +  + void check_mark_stack(INT32 size) + { +  if(mark_sp - mark_stack + size >= stack_size) +  error("Stack overflow.\n"); + } +  +    static void eval_instruction(unsigned char *pc);      
44:    * lvalues are stored in two svalues in one of these formats:    * array[index] : { array, index }    * mapping[index] : { mapping, index } -  * list[index] : { list, index } +  * multiset[index] : { multiset, index } +  * object[index] : { object, index }    * local variable : { svalue_pointer, nothing }    * global variable : { svalue_pointer/short_svalue_pointer, nothing }    */
73:    mapping_index_no_free(to, lval->u.mapping, lval+1);    break;    -  case T_LIST: +  case T_MULTISET:    to->type=T_INT; -  if(list_member(lval->u.list,lval+1)) +  if(multiset_member(lval->u.multiset,lval+1))    {    to->u.integer=0;    to->subtype=NUMBER_UNDEFINED;
114:    mapping_insert(lval->u.mapping, lval+1, from);    break;    -  case T_LIST: +  case T_MULTISET:    if(IS_ZERO(from)) -  list_delete(lval->u.list, lval+1); +  multiset_delete(lval->u.multiset, lval+1);    else -  list_insert(lval->u.list, lval+1); +  multiset_insert(lval->u.multiset, lval+1);    break;       default:
147:    case T_MAPPING:    return mapping_get_item_ptr(lval->u.mapping,lval+1,t);    -  case T_LIST: return 0; +  case T_MULTISET: return 0;       default:    error("Indexing a basic type.\n");
184: Inside #if defined(DEBUG)
   }   }   #else - #define print_return_type() + #define print_return_value()   #endif         void pop_n_elems(INT32 x)   {   #ifdef DEBUG -  if(sp - &(evaluator_stack[0]) < x) +  if(sp - evaluator_stack < x)    fatal("Popping out of stack.\n");       if(x < 0) fatal("Popping negative number of args....\n");   #endif -  free_svalues(sp-x,x); +     sp-=x; -  +  free_svalues(sp,x,BIT_MIXED);   }    -  + /* This function is called 'every now and then'. (1-10000 / sec or so) +  * It should do anything that needs to be done fairly often. +  */ + void check_threads_etc() + { +  check_signals(); +  if(objects_to_destruct) destruct_objects_to_destruct(); +  CHECK_FOR_GC(); + } +    #ifdef DEBUG   static char trace_buffer[100];   #define GET_ARG() (backlog[backlogp].arg=(\
215:      #define CASE(X) case (X)-F_OFFSET:    + #define DOJUMP() \ +  do { int tmp; tmp=EXTRACT_INT(pc); pc+=tmp; if(tmp < 0) check_threads_etc(); }while(0) +    #define COMPARISMENT(ID,EXPR) \   CASE(ID); \   instr=EXPR; \
256:    if( i->integer OP2 sp[-3].u.integer) \    { \    pc+=EXTRACT_INT(pc); \ -  check_signals(); \ +  check_threads_etc(); \    }else{ \    pc+=sizeof(INT32); \    pop_n_elems(3); \
264:    break; \   }    + #define CJUMP(X,Y) \ + CASE(X); \ + if(Y(sp-2,sp-1)) { \ +  DOJUMP(); \ + }else{ \ +  pc+=sizeof(INT32); \ + } \ + pop_n_elems(2); \ + break +  +    /*    * reset the stack machine.    */
273:    pop_n_elems(sp - evaluator_stack);   }    - /* Put catch outside of eval_instruction, so -  * the setjmp won't affect the optimization of -  * eval_instruction -  */ - void f_catch(unsigned char *pc) - { -  JMP_BUF tmp; -  if(SETJMP(tmp)) -  { -  *sp=throw_value; -  throw_value.type=T_INT; -  sp++; -  }else{ -  eval_instruction(pc); -  push_int(0); -  } -  UNSETJMP(tmp); - } -  +    #ifdef DEBUG   #define BACKLOG 512   struct backlog
334:      #endif    + static int o_catch(unsigned char *pc); +    static void eval_instruction(unsigned char *pc)   {    unsigned INT32 instr, prefix=0;
350: Inside #if defined(DEBUG)
   sp[3].type=99;       if(sp<evaluator_stack || mark_sp < mark_stack || fp->locals>sp) -  fatal("Stack error.\n"); +  fatal("Stack error (generic).\n");    -  +  if(sp > evaluator_stack+stack_size) +  fatal("Stack error (overflow).\n"); +     if(fp->fun>=0 && fp->current_object->prog &&    fp->locals+fp->num_locals > sp) -  fatal("Stack error.\n"); +  fatal("Stack error (stupid!).\n");       if(d_flag)    { -  if(d_flag > 9) check_signals(); +  if(d_flag > 9) check_threads_etc();       backlogp++;    if(backlogp >= BACKLOG) backlogp=0;
381: Inside #if defined(DEBUG)
   set_nonblocking(2,0);       file=get_line(pc-1,fp->context.prog,&linep); -  while((f=strchr(file,'/'))) file=f+1; +  while((f=STRCHR(file,'/'))) file=f+1;    fprintf(stderr,"- %s:%4ld:(%lx): %-25s %4ld %4ld\n",    file,(long)linep,    (long)(pc-fp->context.prog->program-1),
392: Inside #if defined(DEBUG)
   set_nonblocking(2,1);    }    +  if(instr + F_OFFSET < F_MAX_OPCODE) +  ADD_RUNNED(instr + F_OFFSET);   #endif -  +     switch(instr)    {    /* Support for large instructions */
418:    CASE(F_CONST0); sp->type=T_INT; sp->u.integer=0; sp++; break;    CASE(F_CONST1); sp->type=T_INT; sp->u.integer=1; sp++; break;    CASE(F_CONST_1);sp->type=T_INT; sp->u.integer=-1; sp++; break; +  CASE(F_BIGNUM); sp->type=T_INT; sp->u.integer=0x7fffffff; sp++; break;    CASE(F_NUMBER); sp->type=T_INT; sp->u.integer=GET_ARG(); sp++; break;    CASE(F_NEG_NUMBER);    sp->type=T_INT;
493:    sp+=2;    break;    +  CASE(F_CLEAR_LOCAL); +  instr=GET_ARG(); +  free_svalue(fp->locals + instr); +  fp->locals[instr].type=T_INT; +  fp->locals[instr].subtype=0; +  fp->locals[instr].u.integer=0; +  break; +  +  +  CASE(F_INC_LOCAL); +  instr=GET_ARG(); +  if(fp->locals[instr].type != T_INT) error("Bad argument to ++\n"); +  fp->locals[instr].u.integer++; +  assign_svalue_no_free(sp++,fp->locals+instr); +  break; +  +  CASE(F_POST_INC_LOCAL); +  instr=GET_ARG(); +  if(fp->locals[instr].type != T_INT) error("Bad argument to ++\n"); +  assign_svalue_no_free(sp++,fp->locals+instr); +  fp->locals[instr].u.integer++; +  break; +  +  CASE(F_INC_LOCAL_AND_POP); +  instr=GET_ARG(); +  if(fp->locals[instr].type != T_INT) error("Bad argument to ++\n"); +  fp->locals[instr].u.integer++; +  break; +  +  CASE(F_DEC_LOCAL); +  instr=GET_ARG(); +  if(fp->locals[instr].type != T_INT) error("Bad argument to --\n"); +  fp->locals[instr].u.integer--; +  assign_svalue_no_free(sp++,fp->locals+instr); +  break; +  +  CASE(F_POST_DEC_LOCAL); +  instr=GET_ARG(); +  if(fp->locals[instr].type != T_INT) error("Bad argument to --\n"); +  assign_svalue_no_free(sp++,fp->locals+instr); +  fp->locals[instr].u.integer--; +  break; +  +  CASE(F_DEC_LOCAL_AND_POP); +  instr=GET_ARG(); +  if(fp->locals[instr].type != T_INT) error("Bad argument to --\n"); +  fp->locals[instr].u.integer--; +  break; +  +     CASE(F_LTOSVAL);    lvalue_to_svalue_no_free(sp,sp-2);    sp++;
505:    /* this is so that foo+=bar (and similar things) will be faster, this    * is done by freeing the old reference to foo after it has been pushed    * on the stack. That way foo can have only 1 reference if we are lucky, -  * and then the low array/list/mapping manipulation routines can be +  * and then the low array/multiset/mapping manipulation routines can be    * destructive if they like    */ -  if( (1 << sp[-1].type) & ( BIT_ARRAY | BIT_LIST | BIT_MAPPING )) +  if( (1 << sp[-1].type) & ( BIT_ARRAY | BIT_MULTISET | BIT_MAPPING ))    {    struct svalue s;    s.type=T_INT;
618:    /* Stack machine stuff */    CASE(F_POP_VALUE); pop_stack(); break;    CASE(F_POP_N_ELEMS); pop_n_elems(GET_ARG()); break; +  CASE(F_MARK2); *(mark_sp++)=sp;    CASE(F_MARK); *(mark_sp++)=sp; break;       /* Jumps */    CASE(F_BRANCH); -  check_signals(); -  pc+=EXTRACT_INT(pc); +  DOJUMP();    break;       CASE(F_BRANCH_WHEN_ZERO); -  check_destructed(sp-1); +     if(!IS_ZERO(sp-1))    {    pc+=sizeof(INT32);    }else{ -  check_signals(); -  pc+=EXTRACT_INT(pc); +  DOJUMP();    }    pop_stack();    break;       CASE(F_BRANCH_WHEN_NON_ZERO); -  check_destructed(sp-1); +     if(IS_ZERO(sp-1))    {    pc+=sizeof(INT32);    }else{ -  check_signals(); -  pc+=EXTRACT_INT(pc); +  DOJUMP();    }    pop_stack();    break;    -  +  CJUMP(F_BRANCH_WHEN_EQ, is_eq); +  CJUMP(F_BRANCH_WHEN_NE,!is_eq); +  CJUMP(F_BRANCH_WHEN_LT, is_lt); +  CJUMP(F_BRANCH_WHEN_LE,!is_gt); +  CJUMP(F_BRANCH_WHEN_GT, is_gt); +  CJUMP(F_BRANCH_WHEN_GE,!is_lt); +     CASE(F_LAND); -  check_destructed(sp-1); +     if(!IS_ZERO(sp-1))    {    pc+=sizeof(INT32);    pop_stack();    }else{ -  check_signals(); -  pc+=EXTRACT_INT(pc); +  DOJUMP();    }    break;       CASE(F_LOR); -  check_destructed(sp-1); +     if(IS_ZERO(sp-1))    {    pc+=sizeof(INT32);    pop_stack();    }else{ -  check_signals(); -  pc+=EXTRACT_INT(pc); +  DOJUMP();    }    break;       CASE(F_CATCH); -  f_catch(pc+sizeof(INT32)); +  if(o_catch(pc+sizeof(INT32))) +  return; /* There was a return inside the evaluated code */ +  else    pc+=EXTRACT_INT(pc);    break;    -  +  CASE(F_THROW_ZERO); +  push_int(0); +  f_throw(1); +  break; +     CASE(F_SWITCH)    {    INT32 tmp;    tmp=switch_lookup(fp->context.prog-> -  constants[EXTRACT_UWORD(pc)].u.array,sp-1); -  pc+=sizeof(INT16); -  pc=(unsigned char *)MY_ALIGN(pc); -  if(tmp >= 0) -  pc+=((INT32 *)pc)[1+tmp*2]; -  else -  pc+=((INT32 *)pc)[2*~tmp]; +  constants[GET_ARG()].u.array,sp-1); +  pc=(unsigned char *)DO_ALIGN(pc,sizeof(INT32)); +  pc+=(tmp>=0 ? 1+tmp*2 : 2*~tmp) * sizeof(INT32); +  if(*(INT32*)pc < 0) check_threads_etc(); +  pc+=*(INT32*)pc;    pop_stack();    break;    }       LOOP(F_INC_LOOP, ++, <); -  LOOP(F_DEC_LOOP, --, <); +  LOOP(F_DEC_LOOP, --, >);    LOOP(F_INC_NEQ_LOOP, ++, !=);    LOOP(F_DEC_NEQ_LOOP, --, !=);   
704:    if(sp[-4].type != T_ARRAY) error("Bad argument 1 to foreach()\n");    if(sp[-1].u.integer < sp[-4].u.array->size)    { -  check_signals(); +  check_threads_etc();    index_no_free(sp,sp-4,sp-1);    sp++;    assign_lvalue(sp-4, sp-1);
721:       CASE(F_RETURN_0);    pop_n_elems(sp-fp->locals); -  check_signals(); +  check_threads_etc();    return;       CASE(F_RETURN);
733:    /* fall through */       CASE(F_DUMB_RETURN); -  check_signals(); +  check_threads_etc();    return;       CASE(F_NEGATE);
744:    {    sp[-1].u.float_number =- sp[-1].u.float_number;    }else{ -  error("Bad argument to unary minus.\n"); +  o_negate();    }    break;    -  CASE(F_COMPL); -  if(sp[-1].type != T_INT) error("Bad argument to ~.\n"); -  sp[-1].u.integer = ~ sp[-1].u.integer; -  break; +  CASE(F_COMPL); o_compl(); break;       CASE(F_NOT);    switch(sp[-1].type)
762:       case T_FUNCTION:    case T_OBJECT: -  check_destructed(sp-1); -  if(sp[-1].type == T_INT) +  if(IS_ZERO(sp-1))    { -  sp[-1].u.integer=1; -  break; +  pop_stack(); +  push_int(1); +  }else{ +  pop_stack(); +  push_int(0);    } -  +  break;       default:    free_svalue(sp-1);
777:    break;       CASE(F_LSH); -  if(sp[-2].type != T_INT) error("Bad argument 1 to <<\n"); +  if(sp[-2].type != T_INT) +  { +  o_lsh(); +  }else{    if(sp[-1].type != T_INT) error("Bad argument 2 to <<\n");    sp--;    sp[-1].u.integer = sp[-1].u.integer << sp->u.integer; -  +  }    break;       CASE(F_RSH); -  if(sp[-2].type != T_INT) error("Bad argument 1 to >>\n"); +  if(sp[-2].type != T_INT) +  { +  o_rsh(); +  }else{    if(sp[-1].type != T_INT) error("Bad argument 2 to >>\n");    sp--;    sp[-1].u.integer = sp[-1].u.integer >> sp->u.integer; -  +  }    break;       COMPARISMENT(F_EQ, is_eq(sp-2,sp-1));
797:    COMPARISMENT(F_LT, is_lt(sp-2,sp-1));    COMPARISMENT(F_LE,!is_gt(sp-2,sp-1));    -  CASE(F_ADD); f_sum(2); break; -  CASE(F_SUBTRACT); f_subtract(); break; -  CASE(F_AND); f_and(); break; -  CASE(F_OR); f_or(); break; -  CASE(F_XOR); f_xor(); break; -  CASE(F_MULTIPLY); f_multiply(); break; -  CASE(F_DIVIDE); f_divide(); break; -  CASE(F_MOD); f_mod(); break; +  CASE(F_ADD); f_add(2); break; +  CASE(F_SUBTRACT); o_subtract(); break; +  CASE(F_AND); o_and(); break; +  CASE(F_OR); o_or(); break; +  CASE(F_XOR); o_xor(); break; +  CASE(F_MULTIPLY); o_multiply(); break; +  CASE(F_DIVIDE); o_divide(); break; +  CASE(F_MOD); o_mod(); break;       CASE(F_PUSH_ARRAY);    if(sp[-1].type!=T_ARRAY) error("Bad argument to @\n");
812:    push_array_items(sp->u.array);    break;    +  CASE(F_LOCAL_INDEX); +  assign_svalue_no_free(sp++,fp->locals+GET_ARG()); +  print_return_value(); +  goto do_index; +  +  CASE(F_POS_INT_INDEX); +  push_int(GET_ARG()); +  print_return_value(); +  goto do_index; +  +  CASE(F_NEG_INT_INDEX); +  push_int(-GET_ARG()); +  print_return_value(); +  goto do_index; +  +  CASE(F_STRING_INDEX); +  copy_shared_string(sp->u.string,fp->context.prog->strings[GET_ARG()]); +  sp->type=T_STRING; +  sp++; +  print_return_value(); +  /* Fall through */ +     CASE(F_INDEX); -  +  do_index:    f_index();    print_return_value();    break;       CASE(F_CAST); f_cast(); break;    -  CASE(F_RANGE); f_range(); break; +  CASE(F_RANGE); o_range(); break;    CASE(F_COPY_VALUE); -  copy_svalues_recursively_no_free(sp,sp-1,1,0); -  sp++; -  free_svalue(sp-2); -  sp[-2]=sp[-1]; -  sp--; +  { +  struct svalue tmp; +  copy_svalues_recursively_no_free(&tmp,sp-1,1,0); +  free_svalue(sp-1); +  sp[-1]=tmp; +  }    break;    -  +  CASE(F_SIZEOF); +  instr=pike_sizeof(sp-1); +  pop_stack(); +  push_int(instr); +  break; +  +  CASE(F_SIZEOF_LOCAL); +  push_int(pike_sizeof(fp->locals+GET_ARG())); +  break; +     CASE(F_SSCANF); f_sscanf(GET_ARG()); break;       CASE(F_CALL_LFUN);
836:    sp - *--mark_sp);    break;    +  CASE(F_CALL_LFUN_AND_POP); +  apply_low(fp->current_object, +  GET_ARG()+fp->context.identifier_level, +  sp - *--mark_sp); +  pop_stack(); +  break; +     default:    instr -= F_MAX_OPCODE - F_OFFSET;   #ifdef DEBUG    if(instr >= fp->context.prog->num_constants)    { -  instr += F_MAX_OPCODE; +  instr += F_MAX_OPCODE - F_OFFSET;    fatal("Strange instruction %ld\n",(long)instr);    }   #endif
850:    }   }    + /* Put catch outside of eval_instruction, so +  * the setjmp won't affect the optimization of +  * eval_instruction +  */ + static int o_catch(unsigned char *pc) + { +  JMP_BUF tmp; +  if(SETJMP(tmp)) +  { +  *sp=throw_value; +  throw_value.type=T_INT; +  sp++; +  UNSETJMP(tmp); +  return 0; +  }else{ +  eval_instruction(pc); +  UNSETJMP(tmp); +  return 1; +  } + } +  +    int apply_low_safe_and_stupid(struct object *o, INT32 offset)   {    JMP_BUF tmp;
876: Inside #if defined(DEBUG)
   eval_instruction(o->prog->program + offset);   #ifdef DEBUG    if(sp<evaluator_stack) -  fatal("Stack error.\n"); +  fatal("Stack error (simple).\n");   #endif    ret=0;    }
896:    struct frame new_frame;    struct identifier *function;    -  check_signals(); +     if(fun<0)    {    pop_n_elems(args);
904:    return;    }    -  if(evaluator_stack+EVALUATOR_STACK_SIZE-sp < 256) -  error("Stack overflow.\n"); +  check_threads_etc(); +  check_stack(256); +  check_mark_stack(256);       p=o->prog;    if(!p)
949: Inside #if defined(DEBUG)
   if(fp && fp->pc)    {    file=get_line(fp->pc,fp->context.prog,&linep); -  while((f=strchr(file,'/'))) file=f+1; +  while((f=STRCHR(file,'/'))) file=f+1;    }else{    linep=0;    file="-";
989:       if(function->flags & IDENTIFIER_C_FUNCTION)    { - #if 0 -  function->func.c_fun(args); - #else -  (*function->func.c_fun)(args); + #ifdef DEBUG +  if(d_flag) check_threads_etc();   #endif -  +  (*function->func.c_fun)(args);    }else{    int num_args;    int num_locals;
1035: Inside #if defined(DEBUG)
   eval_instruction(pc);   #ifdef DEBUG    if(sp<evaluator_stack) -  fatal("Stack error.\n"); +  fatal("Stack error (also simple).\n");   #endif    }   
1104:    sp->type = T_INT;    sp++;    }else{ -  struct svalue *expected_sp; -  expected_sp=sp+1; +  INT32 expected_stack = sp - evaluator_stack + 1;    sp+=args;    apply_low(o,fun,args); -  if(sp > expected_sp) -  pop_n_elems(sp-expected_sp); -  if(sp < expected_sp) +  if(sp - evaluator_stack > expected_stack) +  pop_n_elems(sp - evaluator_stack - expected_stack); +  if(sp - evaluator_stack < expected_stack)    {    sp->u.integer = 0;    sp->subtype=NUMBER_NUMBER;
1130:    safe_apply_low(o, find_identifier(fun, o->prog), args);   }    + void apply_lfun(struct object *o, int fun, int args) + { + #ifdef DEBUG +  if(fun < 0 || fun >= NUM_LFUNS) +  fatal("Apply lfun on illegal value!\n"); + #endif +  if(!o->prog) +  error("Apply on destructed object.\n"); +  +  apply_low(o, o->prog->lfuns[fun], args); + } +    void apply_shared(struct object *o, -  struct lpc_string *fun, +  struct pike_string *fun,    int args)   { -  int fun_number; -  fun_number = find_shared_string_identifier(fun, o->prog); -  if(fun_number < 0) -  { -  pop_n_elems(args); -  sp++; -  sp->u.integer=0; -  sp->type=T_INT; -  }else{ -  apply_low(o, fun_number, args); +  apply_low(o, find_shared_string_identifier(fun, o->prog), args);   } - } +       void apply(struct object *o, char *fun, int args)   { -  int fun_number; -  -  fun_number = find_identifier(fun, o->prog); -  if(fun_number < 0) -  { -  pop_n_elems(args); -  sp->u.integer=0; -  sp->type=T_INT; -  sp++; -  }else{ -  apply_low(o, fun_number, args); +  apply_low(o, find_identifier(fun, o->prog), args);   } - } +       void strict_apply_svalue(struct svalue *s, INT32 args)   {
1180: Inside #if defined(DEBUG)
   if(fp && fp->pc)    {    file=get_line(fp->pc,fp->context.prog,&linep); -  while((f=strchr(file,'/'))) file=f+1; +  while((f=STRCHR(file,'/'))) file=f+1;    }else{    linep=0;    file="-";
1265:    pop_n_elems(args);    push_int(0);    }else{ -  struct svalue *expected_sp=sp-args+1; +  INT32 expected_stack=sp-args+1 - evaluator_stack; +     strict_apply_svalue(s,args); -  if(sp > expected_sp) +  if(sp > (expected_stack + evaluator_stack))    { -  pop_n_elems(sp-expected_sp); +  pop_n_elems(sp-(expected_stack + evaluator_stack));    } -  else if(sp < expected_sp) +  else if(sp < (expected_stack + evaluator_stack))    {    push_int(0);    }   #ifdef DEBUG -  if(sp < expected_sp) fatal("Stack underflow!\n"); +  if(sp < (expected_stack + evaluator_stack)) +  fatal("Stack underflow!\n");   #endif    }   }
1287: Inside #if defined(DEBUG)
   struct svalue *s,**m;    struct frame *f;    -  check_stack(); +  debug_check_stack();    -  if(sp > &(evaluator_stack[EVALUATOR_STACK_SIZE])) +  if(sp > &(evaluator_stack[stack_size]))    fatal("Stack overflow\n");    -  +  if(mark_sp > &(mark_stack[stack_size])) +  fatal("Mark stack overflow.\n"); +     if(mark_sp < mark_stack)    fatal("Mark stack underflow.\n");    -  if(mark_sp > &(mark_stack[EVALUATOR_STACK_SIZE])) -  fatal("Mark stack underflow.\n"); -  +     for(s=evaluator_stack;s<sp;s++) check_svalue(s);       s=evaluator_stack;
1309: Inside #if defined(DEBUG)
   s=*m;    }    -  if(s > &(evaluator_stack[EVALUATOR_STACK_SIZE])) +  if(s > &(evaluator_stack[stack_size]))    fatal("Mark stack exceeds svalue stack\n");       for(f=fp;f;f=f->parent_frame)    { -  +  if(f->locals) +  {    if(f->locals < evaluator_stack || -  f->locals > &(evaluator_stack[EVALUATOR_STACK_SIZE])) +  f->locals > &(evaluator_stack[stack_size]))    fatal("Local variable pointer points to Finspång.\n");    -  if(f->args < 0 || f->args > EVALUATOR_STACK_SIZE) +  if(f->args < 0 || f->args > stack_size)    fatal("FEL FEL FEL! HELP!! (corrupted frame)\n");    }    } -  + }   #endif      void cleanup_interpret()
1349:    }   #endif    reset_evaluator(); +  + #ifdef USE_MMAP_FOR_STACK +  munmap((char *)evaluator_stack, stack_size*sizeof(struct svalue)); +  munmap((char *)mark_stack, stack_size*sizeof(struct svalue *)); + #else +  free((char *)evaluator_stack); +  free((char *)mark_stack); + #endif +    }