hotspot/src/share/vm/memory/barrierSet.hpp
changeset 8498 6398004126b9
parent 7397 5b173b4ca846
child 12268 f7897aacb9ce
equal deleted inserted replaced
8497:aa7fd2c3caa9 8498:6398004126b9
     1 /*
     1 /*
     2  * Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.
     7  * published by the Free Software Foundation.
    42     G1SATBCTLogging,
    42     G1SATBCTLogging,
    43     Other,
    43     Other,
    44     Uninit
    44     Uninit
    45   };
    45   };
    46 
    46 
       
    47   enum Flags {
       
    48     None                = 0,
       
    49     TargetUninitialized = 1
       
    50   };
    47 protected:
    51 protected:
    48   int _max_covered_regions;
    52   int _max_covered_regions;
    49   Name _kind;
    53   Name _kind;
    50 
    54 
    51 public:
    55 public:
   126   // barrier for an array whose elements are all in the given memory region.
   130   // barrier for an array whose elements are all in the given memory region.
   127   virtual void read_ref_array(MemRegion mr) = 0;
   131   virtual void read_ref_array(MemRegion mr) = 0;
   128   virtual void read_prim_array(MemRegion mr) = 0;
   132   virtual void read_prim_array(MemRegion mr) = 0;
   129 
   133 
   130   // Below length is the # array elements being written
   134   // Below length is the # array elements being written
   131   virtual void write_ref_array_pre(      oop* dst, int length) {}
   135   virtual void write_ref_array_pre(oop* dst, int length,
   132   virtual void write_ref_array_pre(narrowOop* dst, int length) {}
   136                                    bool dest_uninitialized = false) {}
       
   137   virtual void write_ref_array_pre(narrowOop* dst, int length,
       
   138                                    bool dest_uninitialized = false) {}
   133   // Below count is the # array elements being written, starting
   139   // Below count is the # array elements being written, starting
   134   // at the address "start", which may not necessarily be HeapWord-aligned
   140   // at the address "start", which may not necessarily be HeapWord-aligned
   135   inline void write_ref_array(HeapWord* start, size_t count);
   141   inline void write_ref_array(HeapWord* start, size_t count);
   136 
   142 
   137   // Static versions, suitable for calling from generated code;
   143   // Static versions, suitable for calling from generated code;