Revision: 14198
Author:   [email protected]
Date:     Wed Apr 10 01:10:51 2013
Log:      GDBJIT: Use runtime_zone to fix --gdbjit_full

[email protected]
BUG=v8:2608

Review URL: https://codereview.chromium.org/13813014
Patch from Haitao Feng <[email protected]>.
http://code.google.com/p/v8/source/detail?r=14198

Modified:
 /branches/bleeding_edge/src/gdb-jit.cc

=======================================
--- /branches/bleeding_edge/src/gdb-jit.cc      Tue Apr  9 08:25:40 2013
+++ /branches/bleeding_edge/src/gdb-jit.cc      Wed Apr 10 01:10:51 2013
@@ -1019,9 +1019,9 @@

 #if defined(__ELF)
 static void CreateSymbolsTable(CodeDescription* desc,
+                               Zone* zone,
                                ELF* elf,
                                int text_section_index) {
-  Zone* zone = desc->info()->zone();
   ELFSymbolTable* symtab = new(zone) ELFSymbolTable(".symtab", zone);
   ELFStringTable* strtab = new(zone) ELFStringTable(".strtab");

@@ -1789,8 +1789,9 @@

 #endif  // V8_TARGET_ARCH_X64

-static void CreateDWARFSections(CodeDescription* desc, DebugObject* obj) {
-  Zone* zone = desc->info()->zone();
+static void CreateDWARFSections(CodeDescription* desc,
+                                Zone* zone,
+                                DebugObject* obj) {
   if (desc->IsLineInfoAvailable()) {
     obj->AddSection(new(zone) DebugInfoSection(desc), zone);
     obj->AddSection(new(zone) DebugAbbrevSection(desc), zone);
@@ -1915,8 +1916,7 @@
 }


-static JITCodeEntry* CreateELFObject(CodeDescription* desc) {
-  Zone* zone = desc->info()->zone();
+static JITCodeEntry* CreateELFObject(CodeDescription* desc, Zone* zone) {
   ZoneScope zone_scope(zone, DELETE_ON_EXIT);
 #ifdef __MACH_O
   MachO mach_o;
@@ -1944,9 +1944,9 @@
           ELFSection::FLAG_ALLOC | ELFSection::FLAG_EXEC),
       zone);

-  CreateSymbolsTable(desc, &elf, text_section_index);
+  CreateSymbolsTable(desc, zone, &elf, text_section_index);

-  CreateDWARFSections(desc, &elf);
+  CreateDWARFSections(desc, zone, &elf);

   elf.Write(&w);
 #endif
@@ -2083,7 +2083,8 @@
   }

   AddUnwindInfo(&code_desc);
-  JITCodeEntry* entry = CreateELFObject(&code_desc);
+  Zone* zone = code->GetIsolate()->runtime_zone();
+  JITCodeEntry* entry = CreateELFObject(&code_desc, zone);
   ASSERT(!IsLineInfoTagged(entry));

   delete lineinfo;

--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to