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

Side by Side Diff: src/builtins.cc

Issue 363323003: More OStreamsUse OStreams more often. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased and polished. Created 6 years, 5 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/ast.cc ('k') | src/code-stubs.cc » ('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 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #include "src/api.h" 7 #include "src/api.h"
8 #include "src/arguments.h" 8 #include "src/arguments.h"
9 #include "src/base/once.h" 9 #include "src/base/once.h"
10 #include "src/bootstrapper.h" 10 #include "src/bootstrapper.h"
(...skipping 1622 matching lines...) Expand 10 before | Expand all | Expand 10 after
1633 Handle<Code> code = 1633 Handle<Code> code =
1634 isolate->factory()->NewCode(desc, flags, masm.CodeObject()); 1634 isolate->factory()->NewCode(desc, flags, masm.CodeObject());
1635 // Log the event and add the code to the builtins array. 1635 // Log the event and add the code to the builtins array.
1636 PROFILE(isolate, 1636 PROFILE(isolate,
1637 CodeCreateEvent(Logger::BUILTIN_TAG, *code, functions[i].s_name)); 1637 CodeCreateEvent(Logger::BUILTIN_TAG, *code, functions[i].s_name));
1638 GDBJIT(AddCode(GDBJITInterface::BUILTIN, functions[i].s_name, *code)); 1638 GDBJIT(AddCode(GDBJITInterface::BUILTIN, functions[i].s_name, *code));
1639 builtins_[i] = *code; 1639 builtins_[i] = *code;
1640 #ifdef ENABLE_DISASSEMBLER 1640 #ifdef ENABLE_DISASSEMBLER
1641 if (FLAG_print_builtin_code) { 1641 if (FLAG_print_builtin_code) {
1642 CodeTracer::Scope trace_scope(isolate->GetCodeTracer()); 1642 CodeTracer::Scope trace_scope(isolate->GetCodeTracer());
1643 PrintF(trace_scope.file(), "Builtin: %s\n", functions[i].s_name); 1643 OFStream os(trace_scope.file());
1644 code->Disassemble(functions[i].s_name, trace_scope.file()); 1644 os << "Builtin: " << functions[i].s_name << "\n";
1645 PrintF(trace_scope.file(), "\n"); 1645 code->Disassemble(functions[i].s_name, os);
1646 os << "\n";
1646 } 1647 }
1647 #endif 1648 #endif
1648 } else { 1649 } else {
1649 // Deserializing. The values will be filled in during IterateBuiltins. 1650 // Deserializing. The values will be filled in during IterateBuiltins.
1650 builtins_[i] = NULL; 1651 builtins_[i] = NULL;
1651 } 1652 }
1652 names_[i] = functions[i].s_name; 1653 names_[i] = functions[i].s_name;
1653 } 1654 }
1654 1655
1655 // Mark as initialized. 1656 // Mark as initialized.
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
1711 } 1712 }
1712 BUILTIN_LIST_C(DEFINE_BUILTIN_ACCESSOR_C) 1713 BUILTIN_LIST_C(DEFINE_BUILTIN_ACCESSOR_C)
1713 BUILTIN_LIST_A(DEFINE_BUILTIN_ACCESSOR_A) 1714 BUILTIN_LIST_A(DEFINE_BUILTIN_ACCESSOR_A)
1714 BUILTIN_LIST_H(DEFINE_BUILTIN_ACCESSOR_H) 1715 BUILTIN_LIST_H(DEFINE_BUILTIN_ACCESSOR_H)
1715 BUILTIN_LIST_DEBUG_A(DEFINE_BUILTIN_ACCESSOR_A) 1716 BUILTIN_LIST_DEBUG_A(DEFINE_BUILTIN_ACCESSOR_A)
1716 #undef DEFINE_BUILTIN_ACCESSOR_C 1717 #undef DEFINE_BUILTIN_ACCESSOR_C
1717 #undef DEFINE_BUILTIN_ACCESSOR_A 1718 #undef DEFINE_BUILTIN_ACCESSOR_A
1718 1719
1719 1720
1720 } } // namespace v8::internal 1721 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/ast.cc ('k') | src/code-stubs.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698