Index: src/contexts.cc |
diff --git a/src/contexts.cc b/src/contexts.cc |
index 12eb871e15ddbe5eb9acb67acb4485fcec01c258..b7617f746761e7edbeadde1c938febda64f71ed4 100644 |
--- a/src/contexts.cc |
+++ b/src/contexts.cc |
@@ -395,7 +395,7 @@ void Context::AddOptimizedFunction(JSFunction* function) { |
DCHECK(function->next_function_link()->IsUndefined()); |
function->set_next_function_link(get(OPTIMIZED_FUNCTIONS_LIST)); |
ulan
2015/05/27 13:35:51
set_next_function_link should be weak too. Is this
Hannes Payer (out of office)
2015/05/27 13:48:59
Next CL together with the other weak next function
|
- set(OPTIMIZED_FUNCTIONS_LIST, function); |
+ set(OPTIMIZED_FUNCTIONS_LIST, function, UPDATE_WEAK_WRITE_BARRIER); |
} |
@@ -409,7 +409,8 @@ void Context::RemoveOptimizedFunction(JSFunction* function) { |
element_function->next_function_link()->IsJSFunction()); |
if (element_function == function) { |
if (prev == NULL) { |
- set(OPTIMIZED_FUNCTIONS_LIST, element_function->next_function_link()); |
+ set(OPTIMIZED_FUNCTIONS_LIST, element_function->next_function_link(), |
+ UPDATE_WEAK_WRITE_BARRIER); |
} else { |
prev->set_next_function_link(element_function->next_function_link()); |
} |
@@ -425,7 +426,7 @@ void Context::RemoveOptimizedFunction(JSFunction* function) { |
void Context::SetOptimizedFunctionsListHead(Object* head) { |
DCHECK(IsNativeContext()); |
- set(OPTIMIZED_FUNCTIONS_LIST, head); |
+ set(OPTIMIZED_FUNCTIONS_LIST, head, UPDATE_WEAK_WRITE_BARRIER); |
} |
@@ -440,13 +441,13 @@ void Context::AddOptimizedCode(Code* code) { |
DCHECK(code->kind() == Code::OPTIMIZED_FUNCTION); |
DCHECK(code->next_code_link()->IsUndefined()); |
code->set_next_code_link(get(OPTIMIZED_CODE_LIST)); |
- set(OPTIMIZED_CODE_LIST, code); |
+ set(OPTIMIZED_CODE_LIST, code, UPDATE_WEAK_WRITE_BARRIER); |
} |
void Context::SetOptimizedCodeListHead(Object* head) { |
DCHECK(IsNativeContext()); |
- set(OPTIMIZED_CODE_LIST, head); |
+ set(OPTIMIZED_CODE_LIST, head, UPDATE_WEAK_WRITE_BARRIER); |
} |
@@ -458,7 +459,7 @@ Object* Context::OptimizedCodeListHead() { |
void Context::SetDeoptimizedCodeListHead(Object* head) { |
DCHECK(IsNativeContext()); |
- set(DEOPTIMIZED_CODE_LIST, head); |
+ set(DEOPTIMIZED_CODE_LIST, head, UPDATE_WEAK_WRITE_BARRIER); |
} |