244 virtual void clone(GraphKit* kit, Node* src, Node* dst, Node* size, bool is_array) const;
245
246 virtual Node* resolve(GraphKit* kit, Node* n, DecoratorSet decorators) const { return n; }
247
248 virtual Node* obj_allocate(PhaseMacroExpand* macro, Node* ctrl, Node* mem, Node* toobig_false, Node* size_in_bytes,
249 Node*& i_o, Node*& needgc_ctrl,
250 Node*& fast_oop_ctrl, Node*& fast_oop_rawmem,
251 intx prefetch_lines) const;
252
253 virtual Node* ideal_node(PhaseGVN* phase, Node* n, bool can_reshape) const { return NULL; }
254 virtual Node* identity_node(PhaseGVN* phase, Node* n) const { return n; }
255
256 // These are general helper methods used by C2
257 enum ArrayCopyPhase {
258 Parsing,
259 Optimization,
260 Expansion
261 };
262
263 virtual bool array_copy_requires_gc_barriers(bool tightly_coupled_alloc, BasicType type, bool is_clone, ArrayCopyPhase phase) const { return false; }
264 virtual void clone_barrier_at_expansion(ArrayCopyNode* ac, Node* call, PhaseIterGVN& igvn) const;
265
266 // Support for GC barriers emitted during parsing
267 virtual bool has_load_barriers() const { return false; }
268 virtual bool is_gc_barrier_node(Node* node) const { return false; }
269 virtual Node* step_over_gc_barrier(Node* c) const { return c; }
270 virtual Node* step_over_gc_barrier_ctrl(Node* c) const { return c; }
271
272 // Support for macro expanded GC barriers
273 virtual void register_potential_barrier_node(Node* node) const { }
274 virtual void unregister_potential_barrier_node(Node* node) const { }
275 virtual void eliminate_gc_barrier(PhaseMacroExpand* macro, Node* node) const { }
276 virtual void enqueue_useful_gc_barrier(PhaseIterGVN* igvn, Node* node) const {}
277 virtual void eliminate_useless_gc_barriers(Unique_Node_List &useful, Compile* C) const {}
278
279 // Allow barrier sets to have shared state that is preserved across a compilation unit.
280 // This could for example comprise macro nodes to be expanded during macro expansion.
281 virtual void* create_barrier_state(Arena* comp_arena) const { return NULL; }
282 // If the BarrierSetC2 state has barrier nodes in its compilation
283 // unit state to be expanded later, then now is the time to do so.
284 virtual bool expand_barriers(Compile* C, PhaseIterGVN& igvn) const { return false; }
|
244 virtual void clone(GraphKit* kit, Node* src, Node* dst, Node* size, bool is_array) const;
245
246 virtual Node* resolve(GraphKit* kit, Node* n, DecoratorSet decorators) const { return n; }
247
248 virtual Node* obj_allocate(PhaseMacroExpand* macro, Node* ctrl, Node* mem, Node* toobig_false, Node* size_in_bytes,
249 Node*& i_o, Node*& needgc_ctrl,
250 Node*& fast_oop_ctrl, Node*& fast_oop_rawmem,
251 intx prefetch_lines) const;
252
253 virtual Node* ideal_node(PhaseGVN* phase, Node* n, bool can_reshape) const { return NULL; }
254 virtual Node* identity_node(PhaseGVN* phase, Node* n) const { return n; }
255
256 // These are general helper methods used by C2
257 enum ArrayCopyPhase {
258 Parsing,
259 Optimization,
260 Expansion
261 };
262
263 virtual bool array_copy_requires_gc_barriers(bool tightly_coupled_alloc, BasicType type, bool is_clone, ArrayCopyPhase phase) const { return false; }
264 virtual void clone_at_expansion(PhaseMacroExpand* phase, ArrayCopyNode* ac) const;
265
266 // Support for GC barriers emitted during parsing
267 virtual bool has_load_barriers() const { return false; }
268 virtual bool is_gc_barrier_node(Node* node) const { return false; }
269 virtual Node* step_over_gc_barrier(Node* c) const { return c; }
270 virtual Node* step_over_gc_barrier_ctrl(Node* c) const { return c; }
271
272 // Support for macro expanded GC barriers
273 virtual void register_potential_barrier_node(Node* node) const { }
274 virtual void unregister_potential_barrier_node(Node* node) const { }
275 virtual void eliminate_gc_barrier(PhaseMacroExpand* macro, Node* node) const { }
276 virtual void enqueue_useful_gc_barrier(PhaseIterGVN* igvn, Node* node) const {}
277 virtual void eliminate_useless_gc_barriers(Unique_Node_List &useful, Compile* C) const {}
278
279 // Allow barrier sets to have shared state that is preserved across a compilation unit.
280 // This could for example comprise macro nodes to be expanded during macro expansion.
281 virtual void* create_barrier_state(Arena* comp_arena) const { return NULL; }
282 // If the BarrierSetC2 state has barrier nodes in its compilation
283 // unit state to be expanded later, then now is the time to do so.
284 virtual bool expand_barriers(Compile* C, PhaseIterGVN& igvn) const { return false; }
|