| Index: test/mjsunit/parallel-initial-prototype-change.js
|
| diff --git a/test/mjsunit/parallel-initial-prototype-change.js b/test/mjsunit/parallel-initial-prototype-change.js
|
| index 9f698bae6301603ac9db208b037609b51ff64ec8..942d9abc3c14750b3207914c481f6a01a3ca466b 100644
|
| --- a/test/mjsunit/parallel-initial-prototype-change.js
|
| +++ b/test/mjsunit/parallel-initial-prototype-change.js
|
| @@ -26,17 +26,13 @@
|
| // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
|
| // Flags: --allow-natives-syntax
|
| -// Flags: --parallel-recompilation --parallel-recompilation-delay=50
|
| +// Flags: --parallel-recompilation --parallel-recompilation-delay=100
|
|
|
| if (!%IsParallelRecompilationSupported()) {
|
| print("Parallel recompilation is disabled. Skipping this test.");
|
| quit();
|
| }
|
|
|
| -function assertUnoptimized(fun) {
|
| - assertTrue(%GetOptimizationStatus(fun) != 1);
|
| -}
|
| -
|
| function f1(a, i) {
|
| return a[i] + 0.5;
|
| }
|
| @@ -47,9 +43,12 @@ assertEquals(0.5, f1(arr, 0));
|
|
|
| // Optimized code of f1 depends on initial object and array maps.
|
| %OptimizeFunctionOnNextCall(f1, "parallel");
|
| +// Trigger optimization in the background thread
|
| assertEquals(0.5, f1(arr, 0));
|
| -assertUnoptimized(f1); // Not yet optimized.
|
| Object.prototype[1] = 1.5; // Invalidate current initial object map.
|
| assertEquals(2, f1(arr, 1));
|
| -%CompleteOptimization(f1); // Conclude optimization with...
|
| -assertUnoptimized(f1); // ... bailing out due to map dependency.
|
| +// Not yet optimized while background thread is running.
|
| +assertUnoptimized(f1, "no sync");
|
| +// Sync with background thread to conclude optimization, which bails out
|
| +// due to map dependency.
|
| +assertUnoptimized(f1, "sync");
|
|
|