< prev index next >

src/hotspot/share/ci/ciUtilities.cpp

Print this page
*** 25,10 ***
--- 25,11 ---
  #include "precompiled.hpp"
  #include "ci/ciUtilities.hpp"
  #include "gc/shared/cardTableBarrierSet.hpp"
  #include "gc/shared/cardTable.hpp"
  #include "gc/shared/collectedHeap.hpp"
+ #include "memory/universe.hpp"
  
  // ciUtilities
  //
  // Miscellaneous internal compiler interface routines.
  

*** 46,5 ***
--- 47,15 ---
    BarrierSet* bs = BarrierSet::barrier_set();
    CardTableBarrierSet* ctbs = barrier_set_cast<CardTableBarrierSet>(bs);
    CardTable* ct = ctbs->card_table();
    return ct->byte_map_base();
  }
+ 
+ bool is_card_table_address(address adr) {
+   if (Universe::is_fully_initialized()) {
+     BarrierSet* bs = BarrierSet::barrier_set(); 
+     if (bs->is_a(BarrierSet::CardTableBarrierSet)) {
+       return adr == ci_card_table_address_as<address>();
+     }
+   }
+   return false;
+ }
< prev index next >