(linenum→info "unix/slp.c:2238")

emacs/22.1/src/alloc.c

    1: /* Storage allocation and gc for GNU Emacs Lisp interpreter.
    2:    Copyright (C) 1985, 1986, 1988, 1993, 1994, 1995, 1997, 1998, 1999,
    3:       2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007  Free Software Foundation, Inc.
    4: 
    5: This file is part of GNU Emacs.
    6: 
    7: GNU Emacs is free software; you can redistribute it and/or modify
    8: it under the terms of the GNU General Public License as published by
    9: the Free Software Foundation; either version 2, or (at your option)
   10: any later version.
   11: 
   12: GNU Emacs is distributed in the hope that it will be useful,
   13: but WITHOUT ANY WARRANTY; without even the implied warranty of
   14: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
   15: GNU General Public License for more details.
   16: 
   17: You should have received a copy of the GNU General Public License
   18: along with GNU Emacs; see the file COPYING.  If not, write to
   19: the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
   20: Boston, MA 02110-1301, USA.  */
   21: 
   22: #include <config.h>
   23: #include <stdio.h>
   24: #include <limits.h>             /* For CHAR_BIT.  */
   25: 
   26: #ifdef STDC_HEADERS
   27: #include <stddef.h>             /* For offsetof, used by PSEUDOVECSIZE. */
   28: #endif
   29: 
   30: #ifdef ALLOC_DEBUG
   31: #undef INLINE
   32: #endif
   33: 
   34: /* Note that this declares bzero on OSF/1.  How dumb.  */
   35: 
   36: #include <signal.h>
   37: 
   38: #ifdef HAVE_GTK_AND_PTHREAD
   39: #include <pthread.h>
   40: #endif
   41: 
   42: /* This file is part of the core Lisp implementation, and thus must
   43:    deal with the real data structures.  If the Lisp implementation is
   44:    replaced, this file likely will not be used.  */
   45: 
   46: #undef HIDE_LISP_IMPLEMENTATION
   47: #include "lisp.h"
   48: #include "process.h"
   49: #include "intervals.h"
   50: #include "puresize.h"
   51: #include "buffer.h"
   52: #include "window.h"
   53: #include "keyboard.h"
   54: #include "frame.h"
   55: #include "blockinput.h"
   56: #include "charset.h"
   57: #include "syssignal.h"
   58: #include <setjmp.h>
   59: 
   60: /* GC_MALLOC_CHECK defined means perform validity checks of malloc'd
   61:    memory.  Can do this only if using gmalloc.c.  */
   62: 
   63: #if defined SYSTEM_MALLOC || defined DOUG_LEA_MALLOC
   64: #undef GC_MALLOC_CHECK
   65: #endif
   66: 
   67: #ifdef HAVE_UNISTD_H
   68: #include <unistd.h>
   69: #else
   70: extern POINTER_TYPE *sbrk ();
   71: #endif
   72: 
   73: #ifdef HAVE_FCNTL_H
   74: #define INCLUDED_FCNTL
   75: #include <fcntl.h>
   76: #endif
   77: #ifndef O_WRONLY
   78: #define O_WRONLY 1
   79: #endif
   80: 
   81: #ifdef WINDOWSNT
   82: #include <fcntl.h>
   83: #include "w32.h"
   84: #endif
   85: 
   86: #ifdef DOUG_LEA_MALLOC
   87: 
   88: #include <malloc.h>
   89: /* malloc.h #defines this as size_t, at least in glibc2.  */
   90: #ifndef __malloc_size_t
   91: #define __malloc_size_t int
   92: #endif
   93: 
   94: /* Specify maximum number of areas to mmap.  It would be nice to use a
   95:    value that explicitly means "no limit".  */
   96: 
   97: #define MMAP_MAX_AREAS 100000000
   98: 
   99: #else /* not DOUG_LEA_MALLOC */
  100: 
  101: /* The following come from gmalloc.c.  */
  102: 
  103: #define __malloc_size_t         size_t
  104: extern __malloc_size_t _bytes_used;
  105: extern __malloc_size_t __malloc_extra_blocks;
  106: 
  107: #endif /* not DOUG_LEA_MALLOC */
  108: 
  109: #if ! defined (SYSTEM_MALLOC) && defined (HAVE_GTK_AND_PTHREAD)
  110: 
  111: /* When GTK uses the file chooser dialog, different backends can be loaded
  112:    dynamically.  One such a backend is the Gnome VFS backend that gets loaded
  113:    if you run Gnome.  That backend creates several threads and also allocates
  114:    memory with malloc.
  115: 
  116:    If Emacs sets malloc hooks (! SYSTEM_MALLOC) and the emacs_blocked_*
  117:    functions below are called from malloc, there is a chance that one
  118:    of these threads preempts the Emacs main thread and the hook variables
  119:    end up in an inconsistent state.  So we have a mutex to prevent that (note
  120:    that the backend handles concurrent access to malloc within its own threads
  121:    but Emacs code running in the main thread is not included in that control).
  122: 
  123:    When UNBLOCK_INPUT is called, reinvoke_input_signal may be called.  If this
  124:    happens in one of the backend threads we will have two threads that tries
  125:    to run Emacs code at once, and the code is not prepared for that.
  126:    To prevent that, we only call BLOCK/UNBLOCK from the main thread.  */
  127: 
  128: static pthread_mutex_t alloc_mutex;
  129: 
  130: #define BLOCK_INPUT_ALLOC                               \
  131:   do                                                    \
  132:     {                                                   \
  133:       if (pthread_equal (pthread_self (), main_thread)) \
  134:         BLOCK_INPUT;                                    \
  135:       pthread_mutex_lock (&alloc_mutex);                \
  136:     }                                                   \
  137:   while (0)
  138: #define UNBLOCK_INPUT_ALLOC                             \
  139:   do                                                    \
  140:     {                                                   \
  141:       pthread_mutex_unlock (&alloc_mutex);              \
  142:       if (pthread_equal (pthread_self (), main_thread)) \
  143:         UNBLOCK_INPUT;                                  \
  144:     }                                                   \
  145:   while (0)
  146: 
  147: #else /* SYSTEM_MALLOC || not HAVE_GTK_AND_PTHREAD */
  148: 
  149: #define BLOCK_INPUT_ALLOC BLOCK_INPUT
  150: #define UNBLOCK_INPUT_ALLOC UNBLOCK_INPUT
  151: 
  152: #endif /* SYSTEM_MALLOC || not HAVE_GTK_AND_PTHREAD */
  153: 
  154: /* Value of _bytes_used, when spare_memory was freed.  */
  155: 
  156: static __malloc_size_t bytes_used_when_full;
  157: 
  158: static __malloc_size_t bytes_used_when_reconsidered;
  159: 
  160: /* Mark, unmark, query mark bit of a Lisp string.  S must be a pointer
  161:    to a struct Lisp_String.  */
  162: 
  163: #define MARK_STRING(S)          ((S)->size |= ARRAY_MARK_FLAG)
  164: #define UNMARK_STRING(S)        ((S)->size &= ~ARRAY_MARK_FLAG)
  165: #define STRING_MARKED_P(S)      (((S)->size & ARRAY_MARK_FLAG) != 0)
  166: 
  167: #define VECTOR_MARK(V)          ((V)->size |= ARRAY_MARK_FLAG)
  168: #define VECTOR_UNMARK(V)        ((V)->size &= ~ARRAY_MARK_FLAG)
  169: #define VECTOR_MARKED_P(V)      (((V)->size & ARRAY_MARK_FLAG) != 0)
  170: 
  171: /* Value is the number of bytes/chars of S, a pointer to a struct
  172:    Lisp_String.  This must be used instead of STRING_BYTES (S) or
  173:    S->size during GC, because S->size contains the mark bit for
  174:    strings.  */
  175: 
  176: #define GC_STRING_BYTES(S)      (STRING_BYTES (S))
  177: #define GC_STRING_CHARS(S)      ((S)->size & ~ARRAY_MARK_FLAG)
  178: 
  179: /* Number of bytes of consing done since the last gc.  */
  180: 
  181: int consing_since_gc;
  182: 
  183: /* Count the amount of consing of various sorts of space.  */
  184: 
  185: EMACS_INT cons_cells_consed;
  186: EMACS_INT floats_consed;
  187: EMACS_INT vector_cells_consed;
  188: EMACS_INT symbols_consed;
  189: EMACS_INT string_chars_consed;
  190: EMACS_INT misc_objects_consed;
  191: EMACS_INT intervals_consed;
  192: EMACS_INT strings_consed;
  193: 
  194: /* Minimum number of bytes of consing since GC before next GC. */
  195: 
  196: EMACS_INT gc_cons_threshold;
  197: 
  198: /* Similar minimum, computed from Vgc_cons_percentage.  */
  199: 
  200: EMACS_INT gc_relative_threshold;
  201: 
  202: static Lisp_Object Vgc_cons_percentage;
  203: 
  204: /* Minimum number of bytes of consing since GC before next GC,
  205:    when memory is full.  */
  206: 
  207: EMACS_INT memory_full_cons_threshold;
  208: 
  209: /* Nonzero during GC.  */
  210: 
  211: int gc_in_progress;
  212: 
  213: /* Nonzero means abort if try to GC.
  214:    This is for code which is written on the assumption that
  215:    no GC will happen, so as to verify that assumption.  */
  216: 
  217: int abort_on_gc;
  218: 
  219: /* Nonzero means display messages at beginning and end of GC.  */
  220: 
  221: int garbage_collection_messages;
  222: 
  223: #ifndef VIRT_ADDR_VARIES
  224: extern
  225: #endif /* VIRT_ADDR_VARIES */
  226: int malloc_sbrk_used;
  227: 
  228: #ifndef VIRT_ADDR_VARIES
  229: extern
  230: #endif /* VIRT_ADDR_VARIES */
  231: int malloc_sbrk_unused;
  232: 
  233: /* Number of live and free conses etc.  */
  234: 
  235: static int total_conses, total_markers, total_symbols, total_vector_size;
  236: static int total_free_conses, total_free_markers, total_free_symbols;
  237: static int total_free_floats, total_floats;
  238: 
  239: /* Points to memory space allocated as "spare", to be freed if we run
  240:    out of memory.  We keep one large block, four cons-blocks, and
  241:    two string blocks.  */
  242: 
  243: char *spare_memory[7];
  244: 
  245: /* Amount of spare memory to keep in large reserve block.  */
  246: 
  247: #define SPARE_MEMORY (1 << 14)
  248: 
  249: /* Number of extra blocks malloc should get when it needs more core.  */
  250: 
  251: static int malloc_hysteresis;
  252: 
  253: /* Non-nil means defun should do purecopy on the function definition.  */
  254: 
  255: Lisp_Object Vpurify_flag;
  256: 
  257: /* Non-nil means we are handling a memory-full error.  */
  258: 
  259: Lisp_Object Vmemory_full;
  260: 
  261: #ifndef HAVE_SHM
  262: 
  263: /* Initialize it to a nonzero value to force it into data space
  264:    (rather than bss space).  That way unexec will remap it into text
  265:    space (pure), on some systems.  We have not implemented the
  266:    remapping on more recent systems because this is less important
  267:    nowadays than in the days of small memories and timesharing.  */
  268: 
  269: EMACS_INT pure[PURESIZE / sizeof (EMACS_INT)] = {1,};
  270: #define PUREBEG (char *) pure
  271: 
  272: #else /* HAVE_SHM */
  273: 
  274: #define pure PURE_SEG_BITS   /* Use shared memory segment */
  275: #define PUREBEG (char *)PURE_SEG_BITS
  276: 
  277: #endif /* HAVE_SHM */
  278: 
  279: /* Pointer to the pure area, and its size.  */
  280: 
  281: static char *purebeg;
  282: static size_t pure_size;
  283: 
  284: /* Number of bytes of pure storage used before pure storage overflowed.
  285:    If this is non-zero, this implies that an overflow occurred.  */
  286: 
  287: static size_t pure_bytes_used_before_overflow;
  288: 
  289: /* Value is non-zero if P points into pure space.  */
  290: 
  291: #define PURE_POINTER_P(P)                                       \
  292:      (((PNTR_COMPARISON_TYPE) (P)                               \
  293:        < (PNTR_COMPARISON_TYPE) ((char *) purebeg + pure_size)) \
  294:       && ((PNTR_COMPARISON_TYPE) (P)                            \
  295:           >= (PNTR_COMPARISON_TYPE) purebeg))
  296: 
  297: /* Total number of bytes allocated in pure storage. */
  298: 
  299: EMACS_INT pure_bytes_used;
  300: 
  301: /* Index in pure at which next pure Lisp object will be allocated.. */
  302: 
  303: static EMACS_INT pure_bytes_used_lisp;
  304: 
  305: /* Number of bytes allocated for non-Lisp objects in pure storage.  */
  306: 
  307: static EMACS_INT pure_bytes_used_non_lisp;
  308: 
  309: /* If nonzero, this is a warning delivered by malloc and not yet
  310:    displayed.  */
  311: 
  312: char *pending_malloc_warning;
  313: 
  314: /* Pre-computed signal argument for use when memory is exhausted.  */
  315: 
  316: Lisp_Object Vmemory_signal_data;
  317: 
  318: /* Maximum amount of C stack to save when a GC happens.  */
  319: 
  320: #ifndef MAX_SAVE_STACK
  321: #define MAX_SAVE_STACK 16000
  322: #endif
  323: 
  324: /* Buffer in which we save a copy of the C stack at each GC.  */
  325: 
  326: char *stack_copy;
  327: int stack_copy_size;
  328: 
  329: /* Non-zero means ignore malloc warnings.  Set during initialization.
  330:    Currently not used.  */
  331: 
  332: int ignore_warnings;
  333: 
  334: Lisp_Object Qgc_cons_threshold, Qchar_table_extra_slots;
  335: 
  336: /* Hook run after GC has finished.  */
  337: 
  338: Lisp_Object Vpost_gc_hook, Qpost_gc_hook;
  339: 
  340: Lisp_Object Vgc_elapsed;        /* accumulated elapsed time in GC  */
  341: EMACS_INT gcs_done;             /* accumulated GCs  */
  342: 
  343: static void mark_buffer P_ ((Lisp_Object));
  344: extern void mark_kboards P_ ((void));
  345: extern void mark_backtrace P_ ((void));
  346: static void gc_sweep P_ ((void));
  347: static void mark_glyph_matrix P_ ((struct glyph_matrix *));
  348: static void mark_face_cache P_ ((struct face_cache *));
  349: 
  350: #ifdef HAVE_WINDOW_SYSTEM
  351: extern void mark_fringe_data P_ ((void));
  352: static void mark_image P_ ((struct image *));
  353: static void mark_image_cache P_ ((struct frame *));
  354: #endif /* HAVE_WINDOW_SYSTEM */
  355: 
  356: static struct Lisp_String *allocate_string P_ ((void));
  357: static void compact_small_strings P_ ((void));
  358: static void free_large_strings P_ ((void));
  359: static void sweep_strings P_ ((void));
  360: 
  361: extern int message_enable_multibyte;
  362: 
  363: /* When scanning the C stack for live Lisp objects, Emacs keeps track
  364:    of what memory allocated via lisp_malloc is intended for what
  365:    purpose.  This enumeration specifies the type of memory.  */
  366: 
  367: enum mem_type
  368: {
  369:   MEM_TYPE_NON_LISP,
  370:   MEM_TYPE_BUFFER,
  371:   MEM_TYPE_CONS,
  372:   MEM_TYPE_STRING,
  373:   MEM_TYPE_MISC,
  374:   MEM_TYPE_SYMBOL,
  375:   MEM_TYPE_FLOAT,
  376:   /* Keep the following vector-like types together, with
  377:      MEM_TYPE_WINDOW being the last, and MEM_TYPE_VECTOR the
  378:      first.  Or change the code of live_vector_p, for instance.  */
  379:   MEM_TYPE_VECTOR,
  380:   MEM_TYPE_PROCESS,
  381:   MEM_TYPE_HASH_TABLE,
  382:   MEM_TYPE_FRAME,
  383:   MEM_TYPE_WINDOW
  384: };
  385: 
  386: static POINTER_TYPE *lisp_align_malloc P_ ((size_t, enum mem_type));
  387: static POINTER_TYPE *lisp_malloc P_ ((size_t, enum mem_type));
  388: void refill_memory_reserve ();
  389: 
  390: 
  391: #if GC_MARK_STACK || defined GC_MALLOC_CHECK
  392: 
  393: #if GC_MARK_STACK == GC_USE_GCPROS_CHECK_ZOMBIES
  394: #include <stdio.h>              /* For fprintf.  */
  395: #endif
  396: 
  397: /* A unique object in pure space used to make some Lisp objects
  398:    on free lists recognizable in O(1).  */
  399: 
  400: Lisp_Object Vdead;
  401: 
  402: #ifdef GC_MALLOC_CHECK
  403: 
  404: enum mem_type allocated_mem_type;
  405: int dont_register_blocks;
  406: 
  407: #endif /* GC_MALLOC_CHECK */
  408: 
  409: /* A node in the red-black tree describing allocated memory containing
  410:    Lisp data.  Each such block is recorded with its start and end
  411:    address when it is allocated, and removed from the tree when it
  412:    is freed.
  413: 
  414:    A red-black tree is a balanced binary tree with the following
  415:    properties:
  416: 
  417:    1. Every node is either red or black.
  418:    2. Every leaf is black.
  419:    3. If a node is red, then both of its children are black.
  420:    4. Every simple path from a node to a descendant leaf contains
  421:    the same number of black nodes.
  422:    5. The root is always black.
  423: 
  424:    When nodes are inserted into the tree, or deleted from the tree,
  425:    the tree is "fixed" so that these properties are always true.
  426: 
  427:    A red-black tree with N internal nodes has height at most 2
  428:    log(N+1).  Searches, insertions and deletions are done in O(log N).
  429:    Please see a text book about data structures for a detailed
  430:    description of red-black trees.  Any book worth its salt should
  431:    describe them.  */
  432: 
  433: struct mem_node
  434: {
  435:   /* Children of this node.  These pointers are never NULL.  When there
  436:      is no child, the value is MEM_NIL, which points to a dummy node.  */
  437:   struct mem_node *left, *right;
  438: 
  439:   /* The parent of this node.  In the root node, this is NULL.  */
  440:   struct mem_node *parent;
  441: 
  442:   /* Start and end of allocated region.  */
  443:   void *start, *end;
  444: 
  445:   /* Node color.  */
  446:   enum {MEM_BLACK, MEM_RED} color;
  447: 
  448:   /* Memory type.  */
  449:   enum mem_type type;
  450: };
  451: 
  452: /* Base address of stack.  Set in main.  */
  453: 
  454: Lisp_Object *stack_base;
  455: 
  456: /* Root of the tree describing allocated Lisp memory.  */
  457: 
  458: static struct mem_node *mem_root;
  459: 
  460: /* Lowest and highest known address in the heap.  */
  461: 
  462: static void *min_heap_address, *max_heap_address;
  463: 
  464: /* Sentinel node of the tree.  */
  465: 
  466: static struct mem_node mem_z;
  467: #define MEM_NIL &mem_z
  468: 
  469: static POINTER_TYPE *lisp_malloc P_ ((size_t, enum mem_type));
  470: static struct Lisp_Vector *allocate_vectorlike P_ ((EMACS_INT, enum mem_type));
  471: static void lisp_free P_ ((POINTER_TYPE *));
  472: static void mark_stack P_ ((void));
  473: static int live_vector_p P_ ((struct mem_node *, void *));
  474: static int live_buffer_p P_ ((struct mem_node *, void *));
  475: static int live_string_p P_ ((struct mem_node *, void *));
  476: static int live_cons_p P_ ((struct mem_node *, void *));
  477: static int live_symbol_p P_ ((struct mem_node *, void *));
  478: static int live_float_p P_ ((struct mem_node *, void *));
  479: static int live_misc_p P_ ((struct mem_node *, void *));
  480: static void mark_maybe_object P_ ((Lisp_Object));
  481: static void mark_memory P_ ((void *, void *, int));
  482: static void mem_init P_ ((void));
  483: static struct mem_node *mem_insert P_ ((void *, void *, enum mem_type));
  484: static void mem_insert_fixup P_ ((struct mem_node *));
  485: static void mem_rotate_left P_ ((struct mem_node *));
  486: static void mem_rotate_right P_ ((struct mem_node *));
  487: static void mem_delete P_ ((struct mem_node *));
  488: static void mem_delete_fixup P_ ((struct mem_node *));
  489: static INLINE struct mem_node *mem_find P_ ((void *));
  490: 
  491: 
  492: #if GC_MARK_STACK == GC_MARK_STACK_CHECK_GCPROS
  493: static void check_gcpros P_ ((void));
  494: #endif
  495: 
  496: #endif /* GC_MARK_STACK || GC_MALLOC_CHECK */
  497: 
  498: /* Recording what needs to be marked for gc.  */
  499: 
  500: struct gcpro *gcprolist;
  501: 
  502: /* Addresses of staticpro'd variables.  Initialize it to a nonzero
  503:    value; otherwise some compilers put it into BSS.  */
  504: 
  505: #define NSTATICS 1280
  506: Lisp_Object *staticvec[NSTATICS] = {&Vpurify_flag};
  507: 
  508: /* Index of next unused slot in staticvec.  */
  509: 
  510: int staticidx = 0;
  511: 
  512: static POINTER_TYPE *pure_alloc P_ ((size_t, int));
  513: 
  514: 
  515: /* Value is SZ rounded up to the next multiple of ALIGNMENT.
  516:    ALIGNMENT must be a power of 2.  */
  517: 
  518: #define ALIGN(ptr, ALIGNMENT) \
  519:   ((POINTER_TYPE *) ((((EMACS_UINT)(ptr)) + (ALIGNMENT) - 1) \
  520:                      & ~((ALIGNMENT) - 1)))
  521: 
  522: 
  523: ^L
  524: /************************************************************************
  525:                                 Malloc
  526:  ************************************************************************/
  527: 
  528: /* Function malloc calls this if it finds we are near exhausting storage.  */
  529: 
  530: void
  531: malloc_warning (str)
  532:      char *str;
  533: {
  534:   pending_malloc_warning = str;
  535: }
  536: 
  537: 
  538: /* Display an already-pending malloc warning.  */
  539: 
  540: void
  541: display_malloc_warning ()
  542: {
  543:   call3 (intern ("display-warning"),
  544:          intern ("alloc"),
  545:          build_string (pending_malloc_warning),
  546:          intern ("emergency"));
  547:   pending_malloc_warning = 0;
  548: }
  549: 
  550: 
  551: #ifdef DOUG_LEA_MALLOC
  552: #  define BYTES_USED (mallinfo ().uordblks)
  553: #else
  554: #  define BYTES_USED _bytes_used
  555: #endif
  556: ^L
  557: /* Called if we can't allocate relocatable space for a buffer.  */
  558: 
  559: void
  560: buffer_memory_full ()
  561: {
  562:   /* If buffers use the relocating allocator, no need to free
  563:      spare_memory, because we may have plenty of malloc space left
  564:      that we could get, and if we don't, the malloc that fails will
  565:      itself cause spare_memory to be freed.  If buffers don't use the
  566:      relocating allocator, treat this like any other failing
  567:      malloc.  */
  568: 
  569: #ifndef REL_ALLOC
  570:   memory_full ();
  571: #endif
  572: 
  573:   /* This used to call error, but if we've run out of memory, we could
  574:      get infinite recursion trying to build the string.  */
  575:   xsignal (Qnil, Vmemory_signal_data);
  576: }
  577: 
  578: 
  579: #ifdef XMALLOC_OVERRUN_CHECK
  580: 
  581: /* Check for overrun in malloc'ed buffers by wrapping a 16 byte header
  582:    and a 16 byte trailer around each block.
  583: 
  584:    The header consists of 12 fixed bytes + a 4 byte integer contaning the
  585:    original block size, while the trailer consists of 16 fixed bytes.
  586: 
  587:    The header is used to detect whether this block has been allocated
  588:    through these functions -- as it seems that some low-level libc
  589:    functions may bypass the malloc hooks.
  590: */
  591: 
  592: 
  593: #define XMALLOC_OVERRUN_CHECK_SIZE 16
  594: 
  595: static char xmalloc_overrun_check_header[XMALLOC_OVERRUN_CHECK_SIZE-4] =
  596:   { 0x9a, 0x9b, 0xae, 0xaf,
  597:     0xbf, 0xbe, 0xce, 0xcf,
  598:     0xea, 0xeb, 0xec, 0xed };
  599: 
  600: static char xmalloc_overrun_check_trailer[XMALLOC_OVERRUN_CHECK_SIZE] =
  601:   { 0xaa, 0xab, 0xac, 0xad,
  602:     0xba, 0xbb, 0xbc, 0xbd,
  603:     0xca, 0xcb, 0xcc, 0xcd,
  604:     0xda, 0xdb, 0xdc, 0xdd };
  605: 
  606: