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

Side by Side Diff: src/api.cc

Issue 5188006: Push version 2.5.7 to trunk.... (Closed) Base URL: http://v8.googlecode.com/svn/trunk/
Patch Set: Created 10 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/allocation.cc ('k') | src/arm/assembler-arm.h » ('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 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 108
109 static FatalErrorCallback exception_behavior = NULL; 109 static FatalErrorCallback exception_behavior = NULL;
110 110
111 static void DefaultFatalErrorHandler(const char* location, 111 static void DefaultFatalErrorHandler(const char* location,
112 const char* message) { 112 const char* message) {
113 ENTER_V8; 113 ENTER_V8;
114 API_Fatal(location, message); 114 API_Fatal(location, message);
115 } 115 }
116 116
117 117
118
119 static FatalErrorCallback& GetFatalErrorHandler() { 118 static FatalErrorCallback& GetFatalErrorHandler() {
120 if (exception_behavior == NULL) { 119 if (exception_behavior == NULL) {
121 exception_behavior = DefaultFatalErrorHandler; 120 exception_behavior = DefaultFatalErrorHandler;
122 } 121 }
123 return exception_behavior; 122 return exception_behavior;
124 } 123 }
125 124
126 125
126 void i::FatalProcessOutOfMemory(const char* location) {
127 i::V8::FatalProcessOutOfMemory(location, false);
128 }
129
127 130
128 // When V8 cannot allocated memory FatalProcessOutOfMemory is called. 131 // When V8 cannot allocated memory FatalProcessOutOfMemory is called.
129 // The default fatal error handler is called and execution is stopped. 132 // The default fatal error handler is called and execution is stopped.
130 void i::V8::FatalProcessOutOfMemory(const char* location, bool take_snapshot) { 133 void i::V8::FatalProcessOutOfMemory(const char* location, bool take_snapshot) {
131 i::HeapStats heap_stats; 134 i::HeapStats heap_stats;
132 int start_marker; 135 int start_marker;
133 heap_stats.start_marker = &start_marker; 136 heap_stats.start_marker = &start_marker;
134 int new_space_size; 137 int new_space_size;
135 heap_stats.new_space_size = &new_space_size; 138 heap_stats.new_space_size = &new_space_size;
136 int new_space_capacity; 139 int new_space_capacity;
(...skipping 4863 matching lines...) Expand 10 before | Expand all | Expand 10 after
5000 5003
5001 5004
5002 char* HandleScopeImplementer::Iterate(ObjectVisitor* v, char* storage) { 5005 char* HandleScopeImplementer::Iterate(ObjectVisitor* v, char* storage) {
5003 HandleScopeImplementer* thread_local = 5006 HandleScopeImplementer* thread_local =
5004 reinterpret_cast<HandleScopeImplementer*>(storage); 5007 reinterpret_cast<HandleScopeImplementer*>(storage);
5005 thread_local->IterateThis(v); 5008 thread_local->IterateThis(v);
5006 return storage + ArchiveSpacePerThread(); 5009 return storage + ArchiveSpacePerThread();
5007 } 5010 }
5008 5011
5009 } } // namespace v8::internal 5012 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/allocation.cc ('k') | src/arm/assembler-arm.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698