363 oop* base = (oop*)cp->base();
364 for (int i = 0; i< cp->length(); i++) {
365 if (cp->tag_at(i).is_klass()) {
366 guarantee((*base)->is_perm(), "should be in permspace");
367 guarantee((*base)->is_klass(), "should be klass");
368 }
369 if (cp->tag_at(i).is_unresolved_klass()) {
370 guarantee((*base)->is_perm(), "should be in permspace");
371 guarantee((*base)->is_symbol() || (*base)->is_klass(),
372 "should be symbol or klass");
373 }
374 if (cp->tag_at(i).is_symbol()) {
375 guarantee((*base)->is_perm(), "should be in permspace");
376 guarantee((*base)->is_symbol(), "should be symbol");
377 }
378 if (cp->tag_at(i).is_unresolved_string()) {
379 guarantee((*base)->is_perm(), "should be in permspace");
380 guarantee((*base)->is_symbol() || (*base)->is_instance(),
381 "should be symbol or instance");
382 }
383 if (cp->tag_at(i).is_string()) {
384 guarantee((*base)->is_perm(), "should be in permspace");
385 guarantee((*base)->is_instance(), "should be instance");
386 }
387 base++;
388 }
389 guarantee(cp->tags()->is_perm(), "should be in permspace");
390 guarantee(cp->tags()->is_typeArray(), "should be type array");
391 if (cp->cache() != NULL) {
392 // Note: cache() can be NULL before a class is completely setup or
393 // in temporary constant pools used during constant pool merging
394 guarantee(cp->cache()->is_perm(), "should be in permspace");
395 guarantee(cp->cache()->is_constantPoolCache(), "should be constant pool cache");
396 }
397 if (cp->pool_holder() != NULL) {
398 // Note: pool_holder() can be NULL in temporary constant pools
399 // used during constant pool merging
400 guarantee(cp->pool_holder()->is_perm(), "should be in permspace");
401 guarantee(cp->pool_holder()->is_klass(), "should be klass");
402 }
|
363 oop* base = (oop*)cp->base();
364 for (int i = 0; i< cp->length(); i++) {
365 if (cp->tag_at(i).is_klass()) {
366 guarantee((*base)->is_perm(), "should be in permspace");
367 guarantee((*base)->is_klass(), "should be klass");
368 }
369 if (cp->tag_at(i).is_unresolved_klass()) {
370 guarantee((*base)->is_perm(), "should be in permspace");
371 guarantee((*base)->is_symbol() || (*base)->is_klass(),
372 "should be symbol or klass");
373 }
374 if (cp->tag_at(i).is_symbol()) {
375 guarantee((*base)->is_perm(), "should be in permspace");
376 guarantee((*base)->is_symbol(), "should be symbol");
377 }
378 if (cp->tag_at(i).is_unresolved_string()) {
379 guarantee((*base)->is_perm(), "should be in permspace");
380 guarantee((*base)->is_symbol() || (*base)->is_instance(),
381 "should be symbol or instance");
382 }
383 if (false) // @@@@ pseudo strings can be in non-perm
384 if (cp->tag_at(i).is_string()) {
385 guarantee((*base)->is_perm(), "should be in permspace");
386 guarantee((*base)->is_instance(), "should be instance");
387 }
388 base++;
389 }
390 guarantee(cp->tags()->is_perm(), "should be in permspace");
391 guarantee(cp->tags()->is_typeArray(), "should be type array");
392 if (cp->cache() != NULL) {
393 // Note: cache() can be NULL before a class is completely setup or
394 // in temporary constant pools used during constant pool merging
395 guarantee(cp->cache()->is_perm(), "should be in permspace");
396 guarantee(cp->cache()->is_constantPoolCache(), "should be constant pool cache");
397 }
398 if (cp->pool_holder() != NULL) {
399 // Note: pool_holder() can be NULL in temporary constant pools
400 // used during constant pool merging
401 guarantee(cp->pool_holder()->is_perm(), "should be in permspace");
402 guarantee(cp->pool_holder()->is_klass(), "should be klass");
403 }
|