Bug 998251 - Fix JSON spew by only printing new-lines in LInstruction::dump(). r=h4writer
authorNicolas B. Pierron <nicolas.b.pierron@mozilla.com>
Tue, 29 Apr 2014 08:58:17 -0700
changeset 181109 31d08ac9bebed1cde25e581e26edb330593c31dc
parent 181108 b7a8d76c6685d02f4831c33b97011872bfa2c2ab
child 181110 c5edc4d488cbea6ac87c31ef192064b604e199db
push id272
push userpvanderbeken@mozilla.com
push dateMon, 05 May 2014 16:31:18 +0000
reviewersh4writer
bugs998251
milestone32.0a1
Bug 998251 - Fix JSON spew by only printing new-lines in LInstruction::dump(). r=h4writer
js/src/jit/LIR.cpp
--- a/js/src/jit/LIR.cpp
+++ b/js/src/jit/LIR.cpp
@@ -363,36 +363,34 @@ LInstruction::dump(FILE *fp)
     for (size_t i = 0; i < numDefs(); i++) {
         PrintDefinition(fp, *getDef(i));
         if (i != numDefs() - 1)
             fprintf(fp, ", ");
     }
     fprintf(fp, "} <- ");
 
     printName(fp);
-
-
     printInfo(fp);
 
     if (numTemps()) {
         fprintf(fp, " t=(");
         for (size_t i = 0; i < numTemps(); i++) {
             PrintDefinition(fp, *getTemp(i));
             if (i != numTemps() - 1)
                 fprintf(fp, ", ");
         }
         fprintf(fp, ")");
     }
-    fprintf(fp, "\n");
 }
 
 void
 LInstruction::dump()
 {
-    return dump(stderr);
+    dump(stderr);
+    fprintf(stderr, "\n");
 }
 
 void
 LInstruction::initSafepoint(TempAllocator &alloc)
 {
     JS_ASSERT(!safepoint_);
     safepoint_ = new(alloc) LSafepoint(alloc);
     JS_ASSERT(safepoint_);