MIPS: Profiler experiments: Fix debugger in the presence of self-optimization headers
authorjkummerow@chromium.org <jkummerow@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Mon, 27 Feb 2012 14:24:08 +0000 (14:24 +0000)
committerjkummerow@chromium.org <jkummerow@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Mon, 27 Feb 2012 14:24:08 +0000 (14:24 +0000)
Port r10834 (0ce8cc524).

Note: this commit is a simple fix-up for FullCodeGenerator::self_optimization_header_size().

BUG=
TEST=

Review URL: https://chromiumcodereview.appspot.com/9466050
Patch from Daniel Kalmar <kalmard@homejinni.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10843 ce2b1a6d-e550-0410-aec6-3dcde31c8c00

src/mips/full-codegen-mips.cc

index c8239e32461c4fe675ff2aae2806e397a765fb71..312f49b60a2333a55d7752427932f677f416a4f0 100644 (file)
@@ -120,7 +120,7 @@ class JumpPatchSite BASE_EMBEDDED {
 
 
 int FullCodeGenerator::self_optimization_header_size() {
-  return 0;  // TODO(jkummerow): determine correct value.
+  return 11 * Instruction::kInstrSize;
 }
 
 
@@ -164,7 +164,7 @@ void FullCodeGenerator::Generate() {
       Handle<Code> compile_stub(
           isolate()->builtins()->builtin(Builtins::kLazyRecompile));
       __ Jump(compile_stub, RelocInfo::CODE_TARGET, eq, a3, Operand(zero_reg));
-      ASSERT(masm_->pc_offset() == self_optimization_header_size());
+      ASSERT_EQ(masm_->pc_offset(), self_optimization_header_size());
     }
   }