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

Side by Side Diff: src/d8.cc

Issue 68203003: Enable physical memory argument to be passed as an argument to ConfigureResourceConstraintsForPlatf… (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebase Created 7 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 | Annotate | Revision Log
« no previous file with comments | « src/api.cc ('k') | src/defaults.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 1661 matching lines...) Expand 10 before | Expand all | Expand 10 after
1672 1672
1673 int Shell::Main(int argc, char* argv[]) { 1673 int Shell::Main(int argc, char* argv[]) {
1674 if (!SetOptions(argc, argv)) return 1; 1674 if (!SetOptions(argc, argv)) return 1;
1675 v8::V8::InitializeICU(); 1675 v8::V8::InitializeICU();
1676 #ifndef V8_SHARED 1676 #ifndef V8_SHARED
1677 i::FLAG_trace_hydrogen_file = "hydrogen.cfg"; 1677 i::FLAG_trace_hydrogen_file = "hydrogen.cfg";
1678 i::FLAG_redirect_code_traces_to = "code.asm"; 1678 i::FLAG_redirect_code_traces_to = "code.asm";
1679 #else 1679 #else
1680 SetStandaloneFlagsViaCommandLine(); 1680 SetStandaloneFlagsViaCommandLine();
1681 #endif 1681 #endif
1682 v8::SetDefaultResourceConstraintsForCurrentPlatform();
1683 ShellArrayBufferAllocator array_buffer_allocator; 1682 ShellArrayBufferAllocator array_buffer_allocator;
1684 v8::V8::SetArrayBufferAllocator(&array_buffer_allocator); 1683 v8::V8::SetArrayBufferAllocator(&array_buffer_allocator);
1685 int result = 0; 1684 int result = 0;
1686 Isolate* isolate = Isolate::GetCurrent(); 1685 Isolate* isolate = Isolate::GetCurrent();
1686 v8::ResourceConstraints constraints;
1687 constraints.ConfigureDefaults(i::OS::TotalPhysicalMemory());
1688 v8::SetResourceConstraints(isolate, &constraints);
1687 DumbLineEditor dumb_line_editor(isolate); 1689 DumbLineEditor dumb_line_editor(isolate);
1688 { 1690 {
1689 Initialize(isolate); 1691 Initialize(isolate);
1690 #ifdef ENABLE_VTUNE_JIT_INTERFACE 1692 #ifdef ENABLE_VTUNE_JIT_INTERFACE
1691 vTune::InitializeVtuneForV8(); 1693 vTune::InitializeVtuneForV8();
1692 #endif 1694 #endif
1693 PerIsolateData data(isolate); 1695 PerIsolateData data(isolate);
1694 InitializeDebugger(isolate); 1696 InitializeDebugger(isolate);
1695 1697
1696 #ifndef V8_SHARED 1698 #ifndef V8_SHARED
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
1757 } 1759 }
1758 1760
1759 } // namespace v8 1761 } // namespace v8
1760 1762
1761 1763
1762 #ifndef GOOGLE3 1764 #ifndef GOOGLE3
1763 int main(int argc, char* argv[]) { 1765 int main(int argc, char* argv[]) {
1764 return v8::Shell::Main(argc, argv); 1766 return v8::Shell::Main(argc, argv);
1765 } 1767 }
1766 #endif 1768 #endif
OLDNEW
« no previous file with comments | « src/api.cc ('k') | src/defaults.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698