< prev index next >

src/hotspot/share/gc/shared/c1/modRefBarrierSetC1.hpp

BarrierSetC1_v3

BarrierSetC1_v2

9  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or                                                             
10  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License                                                             
11  * version 2 for more details (a copy is included in the LICENSE file that                                                           
12  * accompanied this code).                                                                                                           
13  *                                                                                                                                   
14  * You should have received a copy of the GNU General Public License version                                                         
15  * 2 along with this work; if not, write to the Free Software Foundation,                                                            
16  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.                                                                     
17  *                                                                                                                                   
18  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA                                                           
19  * or visit www.oracle.com if you need additional information or have any                                                            
20  * questions.                                                                                                                        
21  *                                                                                                                                   
22  */                                                                                                                                  
23 
24 #ifndef SHARE_GC_SHARED_C1_MODREFBARRIERSETC1_HPP                                                                                    
25 #define SHARE_GC_SHARED_C1_MODREFBARRIERSETC1_HPP                                                                                    
26 
27 #include "gc/shared/c1/barrierSetC1.hpp"                                                                                             
28 
29 class ModRefBarrierSetC1 : public BarrierSetC1 {                                                                                     
30 public:                                                                                                                              
31   virtual void pre_barrier(LIRGenerator* lir_generator, DecoratorSet decorators,                                                     
32                            LIR_Opr addr_opr, LIR_Opr pre_val, CodeEmitInfo* info) {}                                                 
33   virtual void post_barrier(LIRGenerator* lir_generator, DecoratorSet decorators,                                                    
34                             LIR_OprDesc* addr, LIR_OprDesc* new_val) {}                                                              
35 
                                                                                                                                     
36 protected:                                                                                                                           
37   virtual void store_at_resolved(LIRGenerator* lir_generator, DecoratorSet decorators, BasicType type,                               
38                                  LIR_Opr addr, LIRItem& base, LIR_Opr offset, LIR_Opr value,                                         
39                                  CodeEmitInfo* patch_info, CodeEmitInfo* store_emit_info);                                           
                                                                                                                                     
                                                                                                                                     
                                                                                                                                     
40 
41   virtual LIR_Opr atomic_cmpxchg_resolved(LIRGenerator* lir_generator, DecoratorSet decorators, BasicType type,                      
42                                   LIR_Opr addr, LIRItem& base, LIRItem& offset, LIRItem& cmp_value, LIRItem& new_value);             
43 
44   virtual LIR_Opr atomic_xchg_resolved(LIRGenerator* lir_generator, DecoratorSet decorators, BasicType type,                         
45                                    LIR_Opr addr, LIRItem& base, LIRItem& offset, LIRItem& value);                                    
46 
47 public:                                                                                                                              
48   void store_at(LIRGenerator *lir_generator, DecoratorSet decorators, BasicType type,                                                
49                 LIRItem& base, LIR_Opr offset, LIR_Opr value,                                                                        
50                 CodeEmitInfo* patch_info, CodeEmitInfo* store_emit_info);                                                            
51 };                                                                                                                                   
52 
53 #endif // SHARE_GC_SHARED_C1_MODREFBARRIERSETC1_HPP                                                                                  

9  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
10  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
11  * version 2 for more details (a copy is included in the LICENSE file that
12  * accompanied this code).
13  *
14  * You should have received a copy of the GNU General Public License version
15  * 2 along with this work; if not, write to the Free Software Foundation,
16  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
17  *
18  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
19  * or visit www.oracle.com if you need additional information or have any
20  * questions.
21  *
22  */
23 
24 #ifndef SHARE_GC_SHARED_C1_MODREFBARRIERSETC1_HPP
25 #define SHARE_GC_SHARED_C1_MODREFBARRIERSETC1_HPP
26 
27 #include "gc/shared/c1/barrierSetC1.hpp"
28 
29 // The ModRefBarrierSetC1 filters away accesses on BasicTypes other
30 // than T_OBJECT/T_ARRAY (oops). The oop accesses call one of the protected
31 // accesses, which are overridden in the concrete BarrierSetAssembler.



32 
33 class ModRefBarrierSetC1 : public BarrierSetC1 {
34 protected:
35   virtual void pre_barrier(LIRAccess& access, LIR_Opr addr_opr,
36                            LIR_Opr pre_val, CodeEmitInfo* info) {}
37   virtual void post_barrier(LIRAccess& access, LIR_OprDesc* addr,
38                             LIR_OprDesc* new_val) {}
39 
40   virtual LIR_Opr resolve_address(LIRAccess& access, bool resolve_in_register);
41 
42   virtual void store_at_resolved(LIRAccess& access, LIR_Opr value);

43 
44   virtual LIR_Opr atomic_cmpxchg_resolved(LIRAccess& access, LIRItem& cmp_value, LIRItem& new_value);

45 
46   virtual LIR_Opr atomic_xchg_resolved(LIRAccess& access, LIRItem& value);



47 };
48 
49 #endif // SHARE_GC_SHARED_C1_MODREFBARRIERSETC1_HPP
< prev index next >