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

Side by Side Diff: src/objects-debug.cc

Issue 23691002: Add OptimizedCodeEntry as a new heap object type. An optimized code entry represents an association… (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 3 months 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
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 183 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 break; 194 break;
195 case JS_FUNCTION_PROXY_TYPE: 195 case JS_FUNCTION_PROXY_TYPE:
196 JSFunctionProxy::cast(this)->JSFunctionProxyVerify(); 196 JSFunctionProxy::cast(this)->JSFunctionProxyVerify();
197 break; 197 break;
198 case FOREIGN_TYPE: 198 case FOREIGN_TYPE:
199 Foreign::cast(this)->ForeignVerify(); 199 Foreign::cast(this)->ForeignVerify();
200 break; 200 break;
201 case SHARED_FUNCTION_INFO_TYPE: 201 case SHARED_FUNCTION_INFO_TYPE:
202 SharedFunctionInfo::cast(this)->SharedFunctionInfoVerify(); 202 SharedFunctionInfo::cast(this)->SharedFunctionInfoVerify();
203 break; 203 break;
204 case OPTIMIZED_CODE_ENTRY_TYPE:
205 OptimizedCodeEntry::cast(this)->OptimizedCodeEntryVerify();
206 break;
204 case JS_MESSAGE_OBJECT_TYPE: 207 case JS_MESSAGE_OBJECT_TYPE:
205 JSMessageObject::cast(this)->JSMessageObjectVerify(); 208 JSMessageObject::cast(this)->JSMessageObjectVerify();
206 break; 209 break;
207 case JS_ARRAY_BUFFER_TYPE: 210 case JS_ARRAY_BUFFER_TYPE:
208 JSArrayBuffer::cast(this)->JSArrayBufferVerify(); 211 JSArrayBuffer::cast(this)->JSArrayBufferVerify();
209 break; 212 break;
210 case JS_TYPED_ARRAY_TYPE: 213 case JS_TYPED_ARRAY_TYPE:
211 JSTypedArray::cast(this)->JSTypedArrayVerify(); 214 JSTypedArray::cast(this)->JSTypedArrayVerify();
212 break; 215 break;
213 case JS_DATA_VIEW_TYPE: 216 case JS_DATA_VIEW_TYPE:
(...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after
570 VerifyObjectField(kCodeOffset); 573 VerifyObjectField(kCodeOffset);
571 VerifyObjectField(kOptimizedCodeMapOffset); 574 VerifyObjectField(kOptimizedCodeMapOffset);
572 VerifyObjectField(kScopeInfoOffset); 575 VerifyObjectField(kScopeInfoOffset);
573 VerifyObjectField(kInstanceClassNameOffset); 576 VerifyObjectField(kInstanceClassNameOffset);
574 VerifyObjectField(kFunctionDataOffset); 577 VerifyObjectField(kFunctionDataOffset);
575 VerifyObjectField(kScriptOffset); 578 VerifyObjectField(kScriptOffset);
576 VerifyObjectField(kDebugInfoOffset); 579 VerifyObjectField(kDebugInfoOffset);
577 } 580 }
578 581
579 582
583 void OptimizedCodeEntry::OptimizedCodeEntryVerify() {
584 CHECK(IsOptimizedCodeEntry());
585 VerifyObjectField(kNativeContextOffset);
586 VerifyObjectField(kFunctionOffset);
587 VerifyObjectField(kCodeOffset);
588 VerifyObjectField(kLiteralsOffset);
589 VerifyObjectField(kNextBySharedInfoOffset);
590 VerifyObjectField(kNextByNativeContextOffset);
591 }
592
593
580 void JSGlobalProxy::JSGlobalProxyVerify() { 594 void JSGlobalProxy::JSGlobalProxyVerify() {
581 CHECK(IsJSGlobalProxy()); 595 CHECK(IsJSGlobalProxy());
582 JSObjectVerify(); 596 JSObjectVerify();
583 VerifyObjectField(JSGlobalProxy::kNativeContextOffset); 597 VerifyObjectField(JSGlobalProxy::kNativeContextOffset);
584 // Make sure that this object has no properties, elements. 598 // Make sure that this object has no properties, elements.
585 CHECK_EQ(0, properties()->length()); 599 CHECK_EQ(0, properties()->length());
586 CHECK(HasFastObjectElements()); 600 CHECK(HasFastObjectElements());
587 CHECK_EQ(0, FixedArray::cast(elements())->length()); 601 CHECK_EQ(0, FixedArray::cast(elements())->length());
588 } 602 }
589 603
(...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after
1169 for (int i = 0; i < number_of_transitions(); ++i) { 1183 for (int i = 0; i < number_of_transitions(); ++i) {
1170 if (!CheckOneBackPointer(current_map, GetTarget(i))) return false; 1184 if (!CheckOneBackPointer(current_map, GetTarget(i))) return false;
1171 } 1185 }
1172 return true; 1186 return true;
1173 } 1187 }
1174 1188
1175 1189
1176 #endif // DEBUG 1190 #endif // DEBUG
1177 1191
1178 } } // namespace v8::internal 1192 } } // namespace v8::internal
OLDNEW
« src/objects.h ('K') | « src/objects.cc ('k') | src/objects-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698