mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-23 04:24:49 +02:00
7121140: Allocation paths require explicit memory synchronization operations for RMO systems
Adds store store barrier after initialization of header and body of objects. Reviewed-by: never, kvn
This commit is contained in:
parent
e057d60ca1
commit
97439fb4ff
13 changed files with 196 additions and 7 deletions
|
@ -918,6 +918,15 @@ public:
|
|||
virtual int Opcode() const;
|
||||
};
|
||||
|
||||
class MemBarStoreStoreNode: public MemBarNode {
|
||||
public:
|
||||
MemBarStoreStoreNode(Compile* C, int alias_idx, Node* precedent)
|
||||
: MemBarNode(C, alias_idx, precedent) {
|
||||
init_class_id(Class_MemBarStoreStore);
|
||||
}
|
||||
virtual int Opcode() const;
|
||||
};
|
||||
|
||||
// Ordering between a volatile store and a following volatile load.
|
||||
// Requires multi-CPU visibility?
|
||||
class MemBarVolatileNode: public MemBarNode {
|
||||
|
@ -950,6 +959,8 @@ class InitializeNode: public MemBarNode {
|
|||
};
|
||||
int _is_complete;
|
||||
|
||||
bool _does_not_escape;
|
||||
|
||||
public:
|
||||
enum {
|
||||
Control = TypeFunc::Control,
|
||||
|
@ -989,6 +1000,9 @@ public:
|
|||
void set_complete(PhaseGVN* phase);
|
||||
void set_complete_with_arraycopy() { _is_complete = Complete | WithArraycopy; }
|
||||
|
||||
bool does_not_escape() { return _does_not_escape; }
|
||||
void set_does_not_escape() { _does_not_escape = true; }
|
||||
|
||||
#ifdef ASSERT
|
||||
// ensure all non-degenerate stores are ordered and non-overlapping
|
||||
bool stores_are_sane(PhaseTransform* phase);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue