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

Side by Side Diff: src/full-codegen.cc

Issue 181283003: Symbols for type cells. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed comments. Created 6 years, 9 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
« no previous file with comments | « src/arm/lithium-codegen-arm.cc ('k') | src/heap.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 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 370 matching lines...) Expand 10 before | Expand all | Expand 10 after
381 __ dd(back_edges_[i].id.ToInt()); 381 __ dd(back_edges_[i].id.ToInt());
382 __ dd(back_edges_[i].pc); 382 __ dd(back_edges_[i].pc);
383 __ dd(back_edges_[i].loop_depth); 383 __ dd(back_edges_[i].loop_depth);
384 } 384 }
385 return offset; 385 return offset;
386 } 386 }
387 387
388 388
389 void FullCodeGenerator::InitializeFeedbackVector() { 389 void FullCodeGenerator::InitializeFeedbackVector() {
390 int length = info_->function()->slot_count(); 390 int length = info_->function()->slot_count();
391 ASSERT_EQ(isolate()->heap()->the_hole_value(), 391 feedback_vector_ = isolate()->factory()->NewFixedArray(length, TENURED);
392 *TypeFeedbackInfo::UninitializedSentinel(isolate())); 392 Handle<Object> sentinel = TypeFeedbackInfo::UninitializedSentinel(isolate());
393 feedback_vector_ = isolate()->factory()->NewFixedArrayWithHoles(length, 393 // Ensure that it's safe to set without using a write barrier.
394 TENURED); 394 ASSERT_EQ(isolate()->heap()->uninitialized_symbol(), *sentinel);
395 for (int i = 0; i < length; i++) {
396 feedback_vector_->set(i, *sentinel, SKIP_WRITE_BARRIER);
397 }
395 } 398 }
396 399
397 400
398 void FullCodeGenerator::PopulateDeoptimizationData(Handle<Code> code) { 401 void FullCodeGenerator::PopulateDeoptimizationData(Handle<Code> code) {
399 // Fill in the deoptimization information. 402 // Fill in the deoptimization information.
400 ASSERT(info_->HasDeoptimizationSupport() || bailout_entries_.is_empty()); 403 ASSERT(info_->HasDeoptimizationSupport() || bailout_entries_.is_empty());
401 if (!info_->HasDeoptimizationSupport()) return; 404 if (!info_->HasDeoptimizationSupport()) return;
402 int length = bailout_entries_.length(); 405 int length = bailout_entries_.length();
403 Handle<DeoptimizationOutputData> data = isolate()->factory()-> 406 Handle<DeoptimizationOutputData> data = isolate()->factory()->
404 NewDeoptimizationOutputData(length, TENURED); 407 NewDeoptimizationOutputData(length, TENURED);
(...skipping 1323 matching lines...) Expand 10 before | Expand all | Expand 10 after
1728 } 1731 }
1729 return true; 1732 return true;
1730 } 1733 }
1731 #endif // DEBUG 1734 #endif // DEBUG
1732 1735
1733 1736
1734 #undef __ 1737 #undef __
1735 1738
1736 1739
1737 } } // namespace v8::internal 1740 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm/lithium-codegen-arm.cc ('k') | src/heap.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698