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

Side by Side Diff: src/jump-target-light.cc

Issue 2087009: Custom call IC-s for String.prototype.{charAt,charCodeAt}. (Closed)
Patch Set: ARM port. Created 10 years, 7 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
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 16 matching lines...) Expand all
27 27
28 #include "v8.h" 28 #include "v8.h"
29 29
30 #include "codegen-inl.h" 30 #include "codegen-inl.h"
31 #include "jump-target-inl.h" 31 #include "jump-target-inl.h"
32 32
33 namespace v8 { 33 namespace v8 {
34 namespace internal { 34 namespace internal {
35 35
36 36
37 FrameRegisterState::FrameRegisterState(VirtualFrame* frame) {
38 // Nothing to do when register allocation is not supported.
39 ASSERT(RegisterAllocator::kNumRegisters == 0);
40 }
41
42
37 DeferredCode::DeferredCode() 43 DeferredCode::DeferredCode()
38 : masm_(CodeGeneratorScope::Current()->masm()), 44 : masm_(CodeGeneratorScope::Current()->masm()),
39 statement_position_(masm_->current_statement_position()), 45 statement_position_(masm_->current_statement_position()),
40 position_(masm_->current_position()) { 46 position_(masm_->current_position()),
47 frame_state_(CodeGeneratorScope::Current()->frame()) {
41 ASSERT(statement_position_ != RelocInfo::kNoPosition); 48 ASSERT(statement_position_ != RelocInfo::kNoPosition);
42 ASSERT(position_ != RelocInfo::kNoPosition); 49 ASSERT(position_ != RelocInfo::kNoPosition);
43 50
44 CodeGeneratorScope::Current()->AddDeferred(this); 51 CodeGeneratorScope::Current()->AddDeferred(this);
45 52
46 #ifdef DEBUG 53 #ifdef DEBUG
54 comment_ = "";
47 CodeGeneratorScope::Current()->frame()->AssertIsSpilled(); 55 CodeGeneratorScope::Current()->frame()->AssertIsSpilled();
48 #endif 56 #endif
49 } 57 }
50 58
51 59
52 // ------------------------------------------------------------------------- 60 // -------------------------------------------------------------------------
53 // BreakTarget implementation. 61 // BreakTarget implementation.
54 62
55 63
56 void BreakTarget::SetExpectedHeight() { 64 void BreakTarget::SetExpectedHeight() {
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 if (cgen()->has_valid_frame()) { 108 if (cgen()->has_valid_frame()) {
101 int count = cgen()->frame()->height() - expected_height_; 109 int count = cgen()->frame()->height() - expected_height_;
102 if (count > 0) { 110 if (count > 0) {
103 cgen()->frame()->Drop(count); 111 cgen()->frame()->Drop(count);
104 } 112 }
105 } 113 }
106 DoBind(); 114 DoBind();
107 } 115 }
108 116
109 } } // namespace v8::internal 117 } } // namespace v8::internal
OLDNEW
« src/codegen.h ('K') | « src/jump-target-heavy.cc ('k') | src/objects.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698