Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(14)

Side by Side Diff: test/cctest/test-heap-profiler.cc

Issue 1424703005: Remove JSBuiltinsObject. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 1680 matching lines...) Expand 10 before | Expand all | Expand 10 after
1691 1691
1692 1692
1693 TEST(GlobalObjectFields) { 1693 TEST(GlobalObjectFields) {
1694 LocalContext env; 1694 LocalContext env;
1695 v8::HandleScope scope(env->GetIsolate()); 1695 v8::HandleScope scope(env->GetIsolate());
1696 v8::HeapProfiler* heap_profiler = env->GetIsolate()->GetHeapProfiler(); 1696 v8::HeapProfiler* heap_profiler = env->GetIsolate()->GetHeapProfiler();
1697 CompileRun("obj = {};"); 1697 CompileRun("obj = {};");
1698 const v8::HeapSnapshot* snapshot = heap_profiler->TakeHeapSnapshot(); 1698 const v8::HeapSnapshot* snapshot = heap_profiler->TakeHeapSnapshot();
1699 CHECK(ValidateSnapshot(snapshot)); 1699 CHECK(ValidateSnapshot(snapshot));
1700 const v8::HeapGraphNode* global = GetGlobalObject(snapshot); 1700 const v8::HeapGraphNode* global = GetGlobalObject(snapshot);
1701 const v8::HeapGraphNode* builtins =
1702 GetProperty(global, v8::HeapGraphEdge::kInternal, "builtins");
1703 CHECK(builtins);
1704 const v8::HeapGraphNode* native_context = 1701 const v8::HeapGraphNode* native_context =
1705 GetProperty(global, v8::HeapGraphEdge::kInternal, "native_context"); 1702 GetProperty(global, v8::HeapGraphEdge::kInternal, "native_context");
1706 CHECK(native_context); 1703 CHECK(native_context);
1707 const v8::HeapGraphNode* global_proxy = 1704 const v8::HeapGraphNode* global_proxy =
1708 GetProperty(global, v8::HeapGraphEdge::kInternal, "global_proxy"); 1705 GetProperty(global, v8::HeapGraphEdge::kInternal, "global_proxy");
1709 CHECK(global_proxy); 1706 CHECK(global_proxy);
1710 } 1707 }
1711 1708
1712 1709
1713 TEST(NoHandleLeaks) { 1710 TEST(NoHandleLeaks) {
(...skipping 1082 matching lines...) Expand 10 before | Expand all | Expand 10 after
2796 map.AddRange(ToAddress(0x180), 0x80, 6U); 2793 map.AddRange(ToAddress(0x180), 0x80, 6U);
2797 map.AddRange(ToAddress(0x180), 0x80, 7U); 2794 map.AddRange(ToAddress(0x180), 0x80, 7U);
2798 CHECK_EQ(7u, map.GetTraceNodeId(ToAddress(0x180))); 2795 CHECK_EQ(7u, map.GetTraceNodeId(ToAddress(0x180)));
2799 CHECK_EQ(5u, map.GetTraceNodeId(ToAddress(0x200))); 2796 CHECK_EQ(5u, map.GetTraceNodeId(ToAddress(0x200)));
2800 CHECK_EQ(3u, map.size()); 2797 CHECK_EQ(3u, map.size());
2801 2798
2802 map.Clear(); 2799 map.Clear();
2803 CHECK_EQ(0u, map.size()); 2800 CHECK_EQ(0u, map.size());
2804 CHECK_EQ(0u, map.GetTraceNodeId(ToAddress(0x400))); 2801 CHECK_EQ(0u, map.GetTraceNodeId(ToAddress(0x400)));
2805 } 2802 }
OLDNEW
« src/objects.h ('K') | « test/cctest/test-api.cc ('k') | test/cctest/test-object-observe.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698