Commit 65f0e958 authored by ishell@chromium.org's avatar ishell@chromium.org Committed by Commit Bot

[runtime][tests] More *TypeFeedbackVector* -> *FeedbackVector* renamings.

BUG=

Change-Id: I859fef6b18e51cca80343a89e2b6f38eee95d408
Reviewed-on: https://chromium-review.googlesource.com/442428
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: 's avatarMichael Stanton <mvstanton@chromium.org>
Cr-Commit-Position: refs/heads/master@{#43206}
parent 5f5ec6fd
......@@ -354,7 +354,7 @@ RUNTIME_FUNCTION(Runtime_GetCallable) {
return *Utils::OpenHandle(*instance);
}
RUNTIME_FUNCTION(Runtime_ClearFunctionTypeFeedback) {
RUNTIME_FUNCTION(Runtime_ClearFunctionFeedback) {
HandleScope scope(isolate);
DCHECK_EQ(1, args.length());
CONVERT_ARG_HANDLE_CHECKED(JSFunction, function, 0);
......
......@@ -563,7 +563,7 @@ namespace internal {
F(GetOptimizationCount, 1, 1) \
F(GetUndetectable, 0, 1) \
F(GetCallable, 0, 1) \
F(ClearFunctionTypeFeedback, 1, 1) \
F(ClearFunctionFeedback, 1, 1) \
F(CheckWasmWrapperElision, 2, 1) \
F(NotifyContextDisposed, 0, 1) \
F(SetAllocationTimeout, -1 /* 2 || 3 */, 1) \
......
......@@ -22122,10 +22122,11 @@ static void CheckInstanceCheckedAccessors(bool expects_callbacks) {
CheckInstanceCheckedResult(5, 5, expects_callbacks, &try_catch);
// Cleanup so that closures start out fresh in next check.
CompileRun("%DeoptimizeFunction(test_get);"
"%ClearFunctionTypeFeedback(test_get);"
"%DeoptimizeFunction(test_set);"
"%ClearFunctionTypeFeedback(test_set);");
CompileRun(
"%DeoptimizeFunction(test_get);"
"%ClearFunctionFeedback(test_get);"
"%DeoptimizeFunction(test_set);"
"%ClearFunctionFeedback(test_set);");
}
......
......@@ -350,7 +350,7 @@ assertOptimized(instanceof_check);
// to be monomorphic on first call. Only after crankshafting do we introduce
// realmBArray. This should deopt the method.
%DeoptimizeFunction(instanceof_check);
%ClearFunctionTypeFeedback(instanceof_check);
%ClearFunctionFeedback(instanceof_check);
instanceof_check(Array);
instanceof_check(Array);
%OptimizeFunctionOnNextCall(instanceof_check);
......
......@@ -108,7 +108,7 @@ test_base(dictionary_map_array, -2, true);
assertUnoptimized(test_base);
// Forget about the dictionary_map_array's map.
%ClearFunctionTypeFeedback(test_base);
%ClearFunctionFeedback(test_base);
test_base(a, 5, true);
test_base(a, 6, true);
......
......@@ -91,9 +91,9 @@ function testRemove(a, mode) {
%OptimizeFunctionOnNextCall(splice);
check(splice);
%ClearFunctionTypeFeedback(pop);
%ClearFunctionTypeFeedback(shift);
%ClearFunctionTypeFeedback(splice);
%ClearFunctionFeedback(pop);
%ClearFunctionFeedback(shift);
%ClearFunctionFeedback(splice);
}
for (var i = 0; i < 3; i++) {
......
......@@ -205,7 +205,7 @@ assertEquals(0.5, array_store_1([], 0, 0.5));
assertOptimized(grow_store);
grow_store(a,2048,1);
assertUnoptimized(grow_store);
%ClearFunctionTypeFeedback(grow_store);
%ClearFunctionFeedback(grow_store);
})();
......@@ -228,7 +228,7 @@ assertEquals(0.5, array_store_1([], 0, 0.5));
// Should be a polymorphic grow stub. If not a grow stub it will deopt.
f(new Array("hi"), 1, 3);
assertOptimized(f);
%ClearFunctionTypeFeedback(f);
%ClearFunctionFeedback(f);
})();
......@@ -252,5 +252,5 @@ assertEquals(0.5, array_store_1([], 0, 0.5));
// An attempt to grow should cause deopt
f(new Array("hi"), 1, 3);
assertUnoptimized(f);
%ClearFunctionTypeFeedback(f);
%ClearFunctionFeedback(f);
})();
......@@ -53,7 +53,7 @@ function test(construct) {
assertEquals(5, o.y);
assertEquals(6, o.z);
%DeoptimizeFunction(test_helper);
%ClearFunctionTypeFeedback(test_helper);
%ClearFunctionFeedback(test_helper);
}
function finalize_slack_tracking(construct) {
......
......@@ -65,4 +65,4 @@ assertUnoptimized(add_field, "no sync");
// Sync with background thread to conclude optimization that bailed out.
assertUnoptimized(add_field, "sync");
// Clear type info for stress runs.
%ClearFunctionTypeFeedback(add_field);
%ClearFunctionFeedback(add_field);
......@@ -56,4 +56,4 @@ assertUnoptimized(f, "no sync");
assertUnoptimized(f, "sync");
assertEquals(2, f(o));
//Clear type info for stress runs.
%ClearFunctionTypeFeedback(f);
%ClearFunctionFeedback(f);
......@@ -60,7 +60,7 @@ function test(value_track, value_break) {
access(value_track, value_break(), deopt);
// Clear type feedback of the access function for next run.
%ClearFunctionTypeFeedback(access);
%ClearFunctionFeedback(access);
// Also make sure the initial map of the constructor is reset.
constructor.prototype = {};
......
......@@ -78,8 +78,8 @@ function TryGetter(context, getter, obj, expected, expectException) {
assertEquals(7, exception.stack.split('\n').length);
}
%DeoptimizeFunction(context);
%ClearFunctionTypeFeedback(context);
%ClearFunctionTypeFeedback(getter);
%ClearFunctionFeedback(context);
%ClearFunctionFeedback(getter);
}
function TestGetterInAllContexts(getter, obj, expected, expectException) {
......@@ -239,8 +239,8 @@ function TrySetter(context, setter, obj, expectException, value, expected) {
assertEquals(7, exception.stack.split('\n').length);
}
%DeoptimizeFunction(context);
%ClearFunctionTypeFeedback(context);
%ClearFunctionTypeFeedback(setter);
%ClearFunctionFeedback(context);
%ClearFunctionFeedback(setter);
}
function TestSetterInAllContexts(setter, obj, expectException) {
......
......@@ -253,9 +253,9 @@ test_toarr(toarr2);
%DeoptimizeFunction(outer);
%DeoptimizeFunction(middle);
%DeoptimizeFunction(inner);
%ClearFunctionTypeFeedback(outer);
%ClearFunctionTypeFeedback(middle);
%ClearFunctionTypeFeedback(inner);
%ClearFunctionFeedback(outer);
%ClearFunctionFeedback(middle);
%ClearFunctionFeedback(inner);
}
for (var a = 1; a <= 3; a++) {
......
......@@ -53,8 +53,8 @@ function TestInlinedConstructor(constructor, closure) {
assertEquals(4, counter.value);
%DeoptimizeFunction(closure);
%ClearFunctionTypeFeedback(closure);
%ClearFunctionTypeFeedback(constructor);
%ClearFunctionFeedback(closure);
%ClearFunctionFeedback(constructor);
}
function value_context(constructor, val, deopt, counter) {
......
......@@ -76,11 +76,11 @@
assertEquals("ABC", A(1,2));
%DeoptimizeFunction(A);
%ClearFunctionTypeFeedback(A);
%ClearFunctionFeedback(A);
%DeoptimizeFunction(B);
%ClearFunctionTypeFeedback(B);
%ClearFunctionFeedback(B);
%DeoptimizeFunction(C);
%ClearFunctionTypeFeedback(C);
%ClearFunctionFeedback(C);
}
for (var a = 1; a <= 3; a++) {
......
......@@ -64,4 +64,4 @@ assertUnoptimized(f1, "no sync");
// due to map dependency.
assertUnoptimized(f1, "sync");
//Clear type info for stress runs.
%ClearFunctionTypeFeedback(f1);
%ClearFunctionFeedback(f1);
......@@ -159,7 +159,7 @@ function test_wrapper() {
// The test is called in a wrapper function to eliminate the transition learning
// feedback of AllocationSites.
test_wrapper();
%ClearFunctionTypeFeedback(test_wrapper);
%ClearFunctionFeedback(test_wrapper);
%NeverOptimizeFunction(construct_smis);
......
......@@ -53,7 +53,7 @@ function test_wrapper() {
testDoubleConversion4(new Array(5));
testDoubleConversion4(new Array(5));
assertOptimized(testDoubleConversion4);
%ClearFunctionTypeFeedback(testDoubleConversion4);
%ClearFunctionFeedback(testDoubleConversion4);
// Make sure that non-element related map checks that are not preceded by
// transitions in a loop still get hoisted in a way that doesn't generate a
......@@ -79,7 +79,7 @@ function test_wrapper() {
testExactMapHoisting(new Array(5));
testExactMapHoisting(new Array(5));
assertOptimized(testExactMapHoisting);
%ClearFunctionTypeFeedback(testExactMapHoisting);
%ClearFunctionFeedback(testExactMapHoisting);
// Make sure that non-element related map checks do NOT get hoisted if they
// depend on an elements transition before them and it's not possible to hoist
......@@ -111,7 +111,7 @@ function test_wrapper() {
testExactMapHoisting2(new Array(5));
// Temporarily disabled - see bug 2176.
// assertOptimized(testExactMapHoisting2);
%ClearFunctionTypeFeedback(testExactMapHoisting2);
%ClearFunctionFeedback(testExactMapHoisting2);
// Make sure that non-element related map checks do get hoisted if they use
// the transitioned map for the check and all transitions that they depend
......@@ -140,7 +140,7 @@ function test_wrapper() {
testExactMapHoisting3(new Array(5));
testExactMapHoisting3(new Array(5));
assertOptimized(testExactMapHoisting3);
%ClearFunctionTypeFeedback(testExactMapHoisting3);
%ClearFunctionFeedback(testExactMapHoisting3);
function testDominatingTransitionHoisting1(a) {
var object = new Object();
......@@ -167,7 +167,7 @@ function test_wrapper() {
// above the access, causing a deopt. We should update the type of access
// rather than forbid hoisting the transition.
assertOptimized(testDominatingTransitionHoisting1);
%ClearFunctionTypeFeedback(testDominatingTransitionHoisting1);
%ClearFunctionFeedback(testDominatingTransitionHoisting1);
*/
function testHoistingWithSideEffect(a) {
......@@ -188,7 +188,7 @@ function test_wrapper() {
testHoistingWithSideEffect(new Array(5));
testHoistingWithSideEffect(new Array(5));
assertOptimized(testHoistingWithSideEffect);
%ClearFunctionTypeFeedback(testHoistingWithSideEffect);
%ClearFunctionFeedback(testHoistingWithSideEffect);
function testStraightLineDupeElinination(a,b,c,d,e,f) {
var count = 3;
......@@ -227,10 +227,10 @@ function test_wrapper() {
testStraightLineDupeElinination(new Array(5),0,0,0,0,0);
testStraightLineDupeElinination(new Array(5),0,0,0,0,0);
assertOptimized(testStraightLineDupeElinination);
%ClearFunctionTypeFeedback(testStraightLineDupeElinination);
%ClearFunctionFeedback(testStraightLineDupeElinination);
}
// The test is called in a test wrapper that has type feedback cleared to
// prevent the influence of allocation-sites, which learn from transitions.
test_wrapper();
%ClearFunctionTypeFeedback(test_wrapper);
%ClearFunctionFeedback(test_wrapper);
......@@ -92,7 +92,7 @@ function test(test_double, test_object, set, length) {
function run_test(test_double, test_object, set, length) {
test(test_double, test_object, set, length);
%ClearFunctionTypeFeedback(test);
%ClearFunctionFeedback(test);
}
run_test(false, false, function(a,i,v){ a[i] = v; }, 20);
......
......@@ -43,7 +43,7 @@
// Clearing feedback for the StoreIC in foo is important for runs with
// flag --stress-opt.
%ClearFunctionTypeFeedback(foo);
%ClearFunctionFeedback(foo);
})();
......@@ -80,5 +80,5 @@
assertTrue(a.length * 4 > (1024 * 1024));
assertOptimized(foo2);
%ClearFunctionTypeFeedback(foo2);
%ClearFunctionFeedback(foo2);
})();
......@@ -301,7 +301,7 @@ function run_test(test_func, array, expected_result) {
}
assertEquals(expected_result, sum);
%DeoptimizeFunction(test_func);
%ClearFunctionTypeFeedback(test_func);
%ClearFunctionFeedback(test_func);
}
function run_bounds_test(test_func, array, expected_result) {
......@@ -350,7 +350,7 @@ for (var t = 0; t < types.length; t++) {
%OptimizeFunctionOnNextCall(run_bounds_test);
run_bounds_test(a);
%DeoptimizeFunction(run_bounds_test);
%ClearFunctionTypeFeedback(run_bounds_test);
%ClearFunctionFeedback(run_bounds_test);
}
function array_load_set_smi_check(a) {
......@@ -369,7 +369,7 @@ for (var t = 0; t < types.length; t++) {
array_load_set_smi_check2(a);
array_load_set_smi_check2(0);
%DeoptimizeFunction(array_load_set_smi_check2);
%ClearFunctionTypeFeedback(array_load_set_smi_check2);
%ClearFunctionFeedback(array_load_set_smi_check2);
}
// Check handling of undefined in 32- and 64-bit external float arrays.
......@@ -647,8 +647,8 @@ function do_tagged_index_external_array_test(constructor) {
%OptimizeFunctionOnNextCall(boo);
boo(t_array, 0, 15);
assertEquals(15, goo(t_array, 0));
%ClearFunctionTypeFeedback(goo);
%ClearFunctionTypeFeedback(boo);
%ClearFunctionFeedback(goo);
%ClearFunctionFeedback(boo);
}
do_tagged_index_external_array_test(Int8Array);
......@@ -667,8 +667,8 @@ assertEquals(1, goo(built_in_array, 0));
%OptimizeFunctionOnNextCall(boo);
boo(built_in_array, 0, 11);
assertEquals(11, goo(built_in_array, 0));
%ClearFunctionTypeFeedback(goo);
%ClearFunctionTypeFeedback(boo);
%ClearFunctionFeedback(goo);
%ClearFunctionFeedback(boo);
built_in_array = new Array(1.5, 2, 3, 4, 5, 6);
assertEquals(1.5, goo(built_in_array, 0));
......@@ -677,8 +677,8 @@ assertEquals(1.5, goo(built_in_array, 0));
%OptimizeFunctionOnNextCall(boo);
boo(built_in_array, 0, 2.5);
assertEquals(2.5, goo(built_in_array, 0));
%ClearFunctionTypeFeedback(goo);
%ClearFunctionTypeFeedback(boo);
%ClearFunctionFeedback(goo);
%ClearFunctionFeedback(boo);
// Check all int range edge cases
function checkRange() {
......
......@@ -46,7 +46,7 @@ test_load_set_smi_2(a);
test_load_set_smi_2(a);
test_load_set_smi_2(0);
%DeoptimizeFunction(test_load_set_smi_2);
%ClearFunctionTypeFeedback(test_load_set_smi_2);
%ClearFunctionFeedback(test_load_set_smi_2);
var b = new Object();
......@@ -67,4 +67,4 @@ test_load_set_smi_4(b);
test_load_set_smi_4(b);
test_load_set_smi_4(0);
%DeoptimizeFunction(test_load_set_smi_4);
%ClearFunctionTypeFeedback(test_load_set_smi_4);
%ClearFunctionFeedback(test_load_set_smi_4);
......@@ -70,7 +70,7 @@ if (standalone) {
%OptimizeFunctionOnNextCall(name);
}
clearFunctionTypeFeedback = function(name) {
%ClearFunctionTypeFeedback(name);
%ClearFunctionFeedback(name);
}
deoptimizeFunction = function(name) {
%DeoptimizeFunction(name);
......
......@@ -64,8 +64,8 @@ function TestMathImul(expected, a, b) {
// Deoptimize closures and forget type feedback.
%DeoptimizeFunction(imul_meth_closure);
%DeoptimizeFunction(imul_func_closure);
%ClearFunctionTypeFeedback(imul_meth_closure);
%ClearFunctionTypeFeedback(imul_func_closure);
%ClearFunctionFeedback(imul_meth_closure);
%ClearFunctionFeedback(imul_func_closure);
}
TestMathImul(8, 2, 4);
......
......@@ -142,9 +142,9 @@ function test1() {
}
function clear_ic_state() {
%ClearFunctionTypeFeedback(construct_smis);
%ClearFunctionTypeFeedback(construct_doubles);
%ClearFunctionTypeFeedback(convert_mixed);
%ClearFunctionFeedback(construct_smis);
%ClearFunctionFeedback(construct_doubles);
%ClearFunctionFeedback(convert_mixed);
}
test1();
......
......@@ -173,8 +173,8 @@ function TestAllScenarios(f) {
// Make sure that the assignments are monomorphic.
%DeoptimizeFunction(Assign);
%DeoptimizeFunction(AssignStrict);
%ClearFunctionTypeFeedback(Assign);
%ClearFunctionTypeFeedback(AssignStrict);
%ClearFunctionFeedback(Assign);
%ClearFunctionFeedback(AssignStrict);
for (var i = 0; i < t; ++i) {
var o = create();
assertFalse("a" in o && !("a" in o.__proto__));
......
......@@ -49,7 +49,7 @@ Object.defineProperty(o2, "foo1", {get:getter});
foo(o1);
foo(o1);
foo(o2);
%ClearFunctionTypeFeedback(foo2);
%ClearFunctionFeedback(foo2);
foo2(o2);
foo2(o2);
foo2(o3);
......
......@@ -25,4 +25,4 @@ foo();
assertOptimized(foo);
foo(10);
assertUnoptimized(foo);
%ClearFunctionTypeFeedback(foo);
%ClearFunctionFeedback(foo);
......@@ -54,5 +54,5 @@ assertFalse(%HasFastSmiElements(second_object_array));
assertTrue(%HaveSameMap(first_object_array, second_object_array));
assertFalse(%HaveSameMap(first_smi_array, second_object_array));
%ClearFunctionTypeFeedback(Loader);
%ClearFunctionTypeFeedback(Migrator);
%ClearFunctionFeedback(Loader);
%ClearFunctionFeedback(Migrator);
......@@ -40,7 +40,7 @@ function g() {
else return c;
}
// Clear type feedback from previous stress runs.
%ClearFunctionTypeFeedback(f);
%ClearFunctionFeedback(f);
return f;
}
......
......@@ -64,7 +64,7 @@ if (standalone) {
%OptimizeFunctionOnNextCall(name);
}
clearFunctionTypeFeedback = function(name) {
%ClearFunctionTypeFeedback(name);
%ClearFunctionFeedback(name);
}
deoptimizeFunction = function(name) {
%DeoptimizeFunction(name);
......
......@@ -53,7 +53,7 @@ for (var t = 0; t < types.length; t++) {
delete a[5];
var sliced = do_slice(a);
%ClearFunctionTypeFeedback(do_slice);
%ClearFunctionFeedback(do_slice);
assertEquals(results1[t], sliced[0]);
assertEquals(results2[t], sliced[1]);
assertEquals(results3[t], sliced[2]);
......
......@@ -279,8 +279,8 @@ function testOneArrayType(allocator) {
expected_array_value(7));
%DeoptimizeFunction(test_various_loads6);
%ClearFunctionTypeFeedback(test_various_stores);
%ClearFunctionTypeFeedback(test_various_loads7);
%ClearFunctionFeedback(test_various_stores);
%ClearFunctionFeedback(test_various_loads7);
// Test stores for non-NaN.
var large_array = new allocator(large_array_size);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment