/[cmucl]/src/lisp/gencgc.c
ViewVC logotype

Diff of /src/lisp/gencgc.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.70.2.1 by rtoy, Fri Jun 9 16:05:19 2006 UTC revision 1.70.2.1.4.5 by rtoy, Thu Jun 22 20:41:17 2006 UTC
# Line 4234  trans_vector_long_float(lispobj object) Line 4234  trans_vector_long_float(lispobj object)
4234  }  }
4235  #endif  #endif
4236    
4237    #ifdef type_SimpleArrayDoubleDoubleFloat
4238    static int
4239    size_vector_double_double_float(lispobj * where)
4240    {
4241        struct vector *vector;
4242        int length, nwords;
4243    
4244        vector = (struct vector *) where;
4245        length = fixnum_value(vector->length);
4246        nwords = CEILING(length * 4 + 2, 2);
4247    
4248        return nwords;
4249    }
4250    
4251    static int
4252    scav_vector_double_double_float(lispobj * where, lispobj object)
4253    {
4254        return size_vector_double_double_float(where);
4255    }
4256    
4257    static lispobj
4258    trans_vector_double_double_float(lispobj object)
4259    {
4260        gc_assert(Pointerp(object));
4261        return copy_large_unboxed_object(object,
4262                                         size_vector_double_double_float((lispobj *)
4263                                                                PTR(object)));
4264    }
4265    #endif
4266    
4267  #ifdef type_SimpleArrayComplexSingleFloat  #ifdef type_SimpleArrayComplexSingleFloat
4268  static int  static int
# Line 4341  trans_vector_complex_long_float(lispobj Line 4370  trans_vector_complex_long_float(lispobj
4370                                                                      (object)));                                                                      (object)));
4371  }  }
4372  #endif  #endif
4373    
4374    #ifdef type_SimpleArrayComplexDoubleDoubleFloat
4375    static int
4376    size_vector_complex_double_double_float(lispobj * where)
4377    {
4378        struct vector *vector;
4379        int length, nwords;
4380    
4381        vector = (struct vector *) where;
4382        length = fixnum_value(vector->length);
4383        nwords = length * 8 + 2;
4384    
4385        return nwords;
4386    }
4387    
4388    static int
4389    scav_vector_complex_double_double_float(lispobj * where, lispobj object)
4390    {
4391        return size_vector_complex_double_double_float(where);
4392    }
4393    
4394    static lispobj
4395    trans_vector_complex_double_double_float(lispobj object)
4396    {
4397        gc_assert(Pointerp(object));
4398        return copy_large_unboxed_object(object,
4399                                         size_vector_complex_double_double_float((lispobj *)
4400                                                                                 PTR
4401                                                                                 (object)));
4402    }
4403    #endif
4404    
4405    
4406    
4407  /* Weak Pointers */  /* Weak Pointers */
# Line 4536  gc_init_tables(void) Line 4597  gc_init_tables(void)
4597  #ifdef type_ComplexLongFloat  #ifdef type_ComplexLongFloat
4598      scavtab[type_ComplexLongFloat] = scav_unboxed;      scavtab[type_ComplexLongFloat] = scav_unboxed;
4599  #endif  #endif
4600    #ifdef type_ComplexDoubleDoubleFloat
4601        scavtab[type_ComplexDoubleDoubleFloat] = scav_unboxed;
4602    #endif
4603      scavtab[type_SimpleArray] = scav_boxed;      scavtab[type_SimpleArray] = scav_boxed;
4604      scavtab[type_SimpleString] = scav_string;      scavtab[type_SimpleString] = scav_string;
4605      scavtab[type_SimpleBitVector] = scav_vector_bit;      scavtab[type_SimpleBitVector] = scav_vector_bit;
# Line 4562  gc_init_tables(void) Line 4626  gc_init_tables(void)
4626  #ifdef type_SimpleArrayLongFloat  #ifdef type_SimpleArrayLongFloat
4627      scavtab[type_SimpleArrayLongFloat] = scav_vector_long_float;      scavtab[type_SimpleArrayLongFloat] = scav_vector_long_float;
4628  #endif  #endif
4629    #ifdef type_SimpleArrayDoubleDoubleFloat
4630        scavtab[type_SimpleArrayDoubleDoubleFloat] = scav_vector_double_double_float;
4631    #endif
4632  #ifdef type_SimpleArrayComplexSingleFloat  #ifdef type_SimpleArrayComplexSingleFloat
4633      scavtab[type_SimpleArrayComplexSingleFloat] =      scavtab[type_SimpleArrayComplexSingleFloat] =
4634          scav_vector_complex_single_float;          scav_vector_complex_single_float;
# Line 4573  gc_init_tables(void) Line 4640  gc_init_tables(void)
4640  #ifdef type_SimpleArrayComplexLongFloat  #ifdef type_SimpleArrayComplexLongFloat
4641      scavtab[type_SimpleArrayComplexLongFloat] = scav_vector_complex_long_float;      scavtab[type_SimpleArrayComplexLongFloat] = scav_vector_complex_long_float;
4642  #endif  #endif
4643    #ifdef type_SimpleArrayComplexDoubleDoubleFloat
4644        scavtab[type_SimpleArrayComplexDoubleDoubleFloat] =
4645            scav_vector_complex_double_double_float;
4646    #endif
4647      scavtab[type_ComplexString] = scav_boxed;      scavtab[type_ComplexString] = scav_boxed;
4648      scavtab[type_ComplexBitVector] = scav_boxed;      scavtab[type_ComplexBitVector] = scav_boxed;
4649      scavtab[type_ComplexVector] = scav_boxed;      scavtab[type_ComplexVector] = scav_boxed;
# Line 4588  gc_init_tables(void) Line 4659  gc_init_tables(void)
4659      scavtab[type_FuncallableInstanceHeader] = scav_closure_header;      scavtab[type_FuncallableInstanceHeader] = scav_closure_header;
4660      scavtab[type_ByteCodeFunction] = scav_closure_header;      scavtab[type_ByteCodeFunction] = scav_closure_header;
4661      scavtab[type_ByteCodeClosure] = scav_closure_header;      scavtab[type_ByteCodeClosure] = scav_closure_header;
4662    #ifdef type_DylanFunctionHeader
4663      scavtab[type_DylanFunctionHeader] = scav_closure_header;      scavtab[type_DylanFunctionHeader] = scav_closure_header;
4664    #endif
4665  #else  #else
4666      scavtab[type_ClosureHeader] = scav_boxed;      scavtab[type_ClosureHeader] = scav_boxed;
4667      scavtab[type_FuncallableInstanceHeader] = scav_boxed;      scavtab[type_FuncallableInstanceHeader] = scav_boxed;
4668      scavtab[type_ByteCodeFunction] = scav_boxed;      scavtab[type_ByteCodeFunction] = scav_boxed;
4669      scavtab[type_ByteCodeClosure] = scav_boxed;      scavtab[type_ByteCodeClosure] = scav_boxed;
4670    #ifdef type_DylanFunctionHeader
4671      scavtab[type_DylanFunctionHeader] = scav_boxed;      scavtab[type_DylanFunctionHeader] = scav_boxed;
4672  #endif  #endif
4673    #endif
4674      scavtab[type_ValueCellHeader] = scav_boxed;      scavtab[type_ValueCellHeader] = scav_boxed;
4675      scavtab[type_SymbolHeader] = scav_boxed;      scavtab[type_SymbolHeader] = scav_boxed;
4676      scavtab[type_BaseChar] = scav_immediate;      scavtab[type_BaseChar] = scav_immediate;
# Line 4639  gc_init_tables(void) Line 4714  gc_init_tables(void)
4714  #ifdef type_ComplexLongFloat  #ifdef type_ComplexLongFloat
4715      transother[type_ComplexLongFloat] = trans_unboxed;      transother[type_ComplexLongFloat] = trans_unboxed;
4716  #endif  #endif
4717    #ifdef type_ComplexDoubleDoubleFloat
4718        transother[type_ComplexDoubleDoubleFloat] = trans_unboxed;
4719    #endif
4720      transother[type_SimpleArray] = trans_boxed_large;      transother[type_SimpleArray] = trans_boxed_large;
4721      transother[type_SimpleString] = trans_string;      transother[type_SimpleString] = trans_string;
4722      transother[type_SimpleBitVector] = trans_vector_bit;      transother[type_SimpleBitVector] = trans_vector_bit;
# Line 4665  gc_init_tables(void) Line 4743  gc_init_tables(void)
4743  #ifdef type_SimpleArrayLongFloat  #ifdef type_SimpleArrayLongFloat
4744      transother[type_SimpleArrayLongFloat] = trans_vector_long_float;      transother[type_SimpleArrayLongFloat] = trans_vector_long_float;
4745  #endif  #endif
4746    #ifdef type_SimpleArrayDoubleDoubleFloat
4747        transother[type_SimpleArrayDoubleDoubleFloat] = trans_vector_double_double_float;
4748    #endif
4749  #ifdef type_SimpleArrayComplexSingleFloat  #ifdef type_SimpleArrayComplexSingleFloat
4750      transother[type_SimpleArrayComplexSingleFloat] =      transother[type_SimpleArrayComplexSingleFloat] =
4751          trans_vector_complex_single_float;          trans_vector_complex_single_float;
# Line 4677  gc_init_tables(void) Line 4758  gc_init_tables(void)
4758      transother[type_SimpleArrayComplexLongFloat] =      transother[type_SimpleArrayComplexLongFloat] =
4759          trans_vector_complex_long_float;          trans_vector_complex_long_float;
4760  #endif  #endif
4761    #ifdef type_SimpleArrayComplexDoubleDoubleFloat
4762        transother[type_SimpleArrayComplexDoubleDoubleFloat] =
4763            trans_vector_complex_double_double_float;
4764    #endif
4765      transother[type_ComplexString] = trans_boxed;      transother[type_ComplexString] = trans_boxed;
4766      transother[type_ComplexBitVector] = trans_boxed;      transother[type_ComplexBitVector] = trans_boxed;
4767      transother[type_ComplexVector] = trans_boxed;      transother[type_ComplexVector] = trans_boxed;
# Line 4735  gc_init_tables(void) Line 4820  gc_init_tables(void)
4820  #ifdef type_ComplexLongFloat  #ifdef type_ComplexLongFloat
4821      sizetab[type_ComplexLongFloat] = size_unboxed;      sizetab[type_ComplexLongFloat] = size_unboxed;
4822  #endif  #endif
4823    #ifdef type_ComplexDoubleDoubleFloat
4824        sizetab[type_ComplexDoubleDoubleFloat] = size_unboxed;
4825    #endif
4826      sizetab[type_SimpleArray] = size_boxed;      sizetab[type_SimpleArray] = size_boxed;
4827      sizetab[type_SimpleString] = size_string;      sizetab[type_SimpleString] = size_string;
4828      sizetab[type_SimpleBitVector] = size_vector_bit;      sizetab[type_SimpleBitVector] = size_vector_bit;
# Line 4761  gc_init_tables(void) Line 4849  gc_init_tables(void)
4849  #ifdef type_SimpleArrayLongFloat  #ifdef type_SimpleArrayLongFloat
4850      sizetab[type_SimpleArrayLongFloat] = size_vector_long_float;      sizetab[type_SimpleArrayLongFloat] = size_vector_long_float;
4851  #endif  #endif
4852    #ifdef type_SimpleArrayDoubleDoubleFloat
4853        sizetab[type_SimpleArrayDoubleDoubleFloat] = size_vector_double_double_float;
4854    #endif
4855  #ifdef type_SimpleArrayComplexSingleFloat  #ifdef type_SimpleArrayComplexSingleFloat
4856      sizetab[type_SimpleArrayComplexSingleFloat] =      sizetab[type_SimpleArrayComplexSingleFloat] =
4857          size_vector_complex_single_float;          size_vector_complex_single_float;
# Line 4772  gc_init_tables(void) Line 4863  gc_init_tables(void)
4863  #ifdef type_SimpleArrayComplexLongFloat  #ifdef type_SimpleArrayComplexLongFloat
4864      sizetab[type_SimpleArrayComplexLongFloat] = size_vector_complex_long_float;      sizetab[type_SimpleArrayComplexLongFloat] = size_vector_complex_long_float;
4865  #endif  #endif
4866    #ifdef type_SimpleArrayComplexDoubleDoubleFloat
4867        sizetab[type_SimpleArrayComplexDoubleDoubleFloat] =
4868            size_vector_complex_double_double_float;
4869    #endif
4870      sizetab[type_ComplexString] = size_boxed;      sizetab[type_ComplexString] = size_boxed;
4871      sizetab[type_ComplexBitVector] = size_boxed;      sizetab[type_ComplexBitVector] = size_boxed;
4872      sizetab[type_ComplexVector] = size_boxed;      sizetab[type_ComplexVector] = size_boxed;
# Line 4918  valid_dynamic_space_pointer(lispobj * po Line 5013  valid_dynamic_space_pointer(lispobj * po
5013              case type_FuncallableInstanceHeader:              case type_FuncallableInstanceHeader:
5014              case type_ByteCodeFunction:              case type_ByteCodeFunction:
5015              case type_ByteCodeClosure:              case type_ByteCodeClosure:
5016    #ifdef type_DylanFunctionHeader
5017              case type_DylanFunctionHeader:              case type_DylanFunctionHeader:
5018    #endif
5019                  if ((size_t) pointer !=                  if ((size_t) pointer !=
5020                      (size_t) start_addr + type_FunctionPointer) {                      (size_t) start_addr + type_FunctionPointer) {
5021                      return FALSE;                      return FALSE;
# Line 4971  valid_dynamic_space_pointer(lispobj * po Line 5068  valid_dynamic_space_pointer(lispobj * po
5068              case type_FuncallableInstanceHeader:              case type_FuncallableInstanceHeader:
5069              case type_ByteCodeFunction:              case type_ByteCodeFunction:
5070              case type_ByteCodeClosure:              case type_ByteCodeClosure:
5071    #ifdef type_DylanFunctionHeader
5072              case type_DylanFunctionHeader:              case type_DylanFunctionHeader:
5073    #endif
5074                  return FALSE;                  return FALSE;
5075    
5076              case type_InstanceHeader:              case type_InstanceHeader:
# Line 4990  valid_dynamic_space_pointer(lispobj * po Line 5089  valid_dynamic_space_pointer(lispobj * po
5089  #ifdef type_ComplexLongFloat  #ifdef type_ComplexLongFloat
5090              case type_ComplexLongFloat:              case type_ComplexLongFloat:
5091  #endif  #endif
5092    #ifdef type_ComplexDoubleDoubleFloat
5093                case type_ComplexDoubleDoubleFloat:
5094    #endif
5095              case type_SimpleArray:              case type_SimpleArray:
5096              case type_ComplexString:              case type_ComplexString:
5097              case type_ComplexBitVector:              case type_ComplexBitVector:
# Line 5032  valid_dynamic_space_pointer(lispobj * po Line 5134  valid_dynamic_space_pointer(lispobj * po
5134  #ifdef type_SimpleArrayLongFloat  #ifdef type_SimpleArrayLongFloat
5135              case type_SimpleArrayLongFloat:              case type_SimpleArrayLongFloat:
5136  #endif  #endif
5137    #ifdef type_SimpleArrayDoubleDoubleFloat
5138                case type_SimpleArrayDoubleFloat:
5139    #endif
5140  #ifdef type_SimpleArrayComplexSingleFloat  #ifdef type_SimpleArrayComplexSingleFloat
5141              case type_SimpleArrayComplexSingleFloat:              case type_SimpleArrayComplexSingleFloat:
5142  #endif  #endif
# Line 5041  valid_dynamic_space_pointer(lispobj * po Line 5146  valid_dynamic_space_pointer(lispobj * po
5146  #ifdef type_SimpleArrayComplexLongFloat  #ifdef type_SimpleArrayComplexLongFloat
5147              case type_SimpleArrayComplexLongFloat:              case type_SimpleArrayComplexLongFloat:
5148  #endif  #endif
5149    #ifdef type_SimpleArrayComplexDoubleDoubleFloat
5150                case type_SimpleArrayComplexDoubleDoubleFloat:
5151    #endif
5152              case type_Sap:              case type_Sap:
5153              case type_WeakPointer:              case type_WeakPointer:
5154              case type_ScavengerHook:              case type_ScavengerHook:
# Line 5111  maybe_adjust_large_object(lispobj * wher Line 5219  maybe_adjust_large_object(lispobj * wher
5219  #ifdef type_SimpleArrayLongFloat  #ifdef type_SimpleArrayLongFloat
5220        case type_SimpleArrayLongFloat:        case type_SimpleArrayLongFloat:
5221  #endif  #endif
5222    #ifdef type_SimpleArrayDoubleDoubleFloat
5223          case type_SimpleArrayDoubleDoubleFloat:
5224    #endif
5225  #ifdef type_SimpleArrayComplexSingleFloat  #ifdef type_SimpleArrayComplexSingleFloat
5226        case type_SimpleArrayComplexSingleFloat:        case type_SimpleArrayComplexSingleFloat:
5227  #endif  #endif
# Line 5120  maybe_adjust_large_object(lispobj * wher Line 5231  maybe_adjust_large_object(lispobj * wher
5231  #ifdef type_SimpleArrayComplexLongFloat  #ifdef type_SimpleArrayComplexLongFloat
5232        case type_SimpleArrayComplexLongFloat:        case type_SimpleArrayComplexLongFloat:
5233  #endif  #endif
5234    #ifdef type_SimpleArrayComplexDoubleDoubleFloat
5235          case type_SimpleArrayComplexDoubleDoubleFloat:
5236    #endif
5237            unboxed = TRUE;            unboxed = TRUE;
5238            break;            break;
5239        default:        default:
# Line 6175  verify_space(lispobj * start, size_t wor Line 6289  verify_space(lispobj * start, size_t wor
6289                case type_FuncallableInstanceHeader:                case type_FuncallableInstanceHeader:
6290                case type_ByteCodeFunction:                case type_ByteCodeFunction:
6291                case type_ByteCodeClosure:                case type_ByteCodeClosure:
6292    #ifdef type_DylanFunctionHeader
6293                case type_DylanFunctionHeader:                case type_DylanFunctionHeader:
6294    #endif
6295                case type_ValueCellHeader:                case type_ValueCellHeader:
6296                case type_SymbolHeader:                case type_SymbolHeader:
6297                case type_BaseChar:                case type_BaseChar:
# Line 6250  verify_space(lispobj * start, size_t wor Line 6366  verify_space(lispobj * start, size_t wor
6366  #ifdef type_ComplexLongFloat  #ifdef type_ComplexLongFloat
6367                case type_ComplexLongFloat:                case type_ComplexLongFloat:
6368  #endif  #endif
6369    #ifdef type_ComplexDoubleDoubleFloat
6370                  case type_ComplexDoubleDoubleFloat:
6371    #endif
6372                case type_SimpleString:                case type_SimpleString:
6373                case type_SimpleBitVector:                case type_SimpleBitVector:
6374                case type_SimpleArrayUnsignedByte2:                case type_SimpleArrayUnsignedByte2:
# Line 6271  verify_space(lispobj * start, size_t wor Line 6390  verify_space(lispobj * start, size_t wor
6390  #endif  #endif
6391                case type_SimpleArraySingleFloat:                case type_SimpleArraySingleFloat:
6392                case type_SimpleArrayDoubleFloat:                case type_SimpleArrayDoubleFloat:
6393    #ifdef type_SimpleArrayDoubleDoubleFloat
6394                  case type_SimpleArrayDoubleDoubleFloat:
6395    #endif
6396  #ifdef type_SimpleArrayComplexLongFloat  #ifdef type_SimpleArrayComplexLongFloat
6397                case type_SimpleArrayLongFloat:                case type_SimpleArrayLongFloat:
6398  #endif  #endif
# Line 6283  verify_space(lispobj * start, size_t wor Line 6405  verify_space(lispobj * start, size_t wor
6405  #ifdef type_SimpleArrayComplexLongFloat  #ifdef type_SimpleArrayComplexLongFloat
6406                case type_SimpleArrayComplexLongFloat:                case type_SimpleArrayComplexLongFloat:
6407  #endif  #endif
6408    #ifdef type_SimpleArrayComplexDoubleDoubleFloat
6409                  case type_SimpleArrayComplexDoubleDoubleFloat:
6410    #endif
6411                case type_Sap:                case type_Sap:
6412                case type_WeakPointer:                case type_WeakPointer:
6413                    count = (sizetab[TypeOf(*start)]) (start);                    count = (sizetab[TypeOf(*start)]) (start);

Legend:
Removed from v.1.70.2.1  
changed lines
  Added in v.1.70.2.1.4.5

  ViewVC Help
Powered by ViewVC 1.1.5