| OLD | NEW |
| 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/code-stubs.h" | 5 #include "src/code-stubs.h" |
| 6 | 6 |
| 7 #include <sstream> | 7 #include <sstream> |
| 8 | 8 |
| 9 #include "src/bootstrapper.h" | 9 #include "src/bootstrapper.h" |
| 10 #include "src/factory.h" | 10 #include "src/factory.h" |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 101 ic->FindAndReplace(pattern); | 101 ic->FindAndReplace(pattern); |
| 102 RecordCodeGeneration(ic); | 102 RecordCodeGeneration(ic); |
| 103 return ic; | 103 return ic; |
| 104 } | 104 } |
| 105 | 105 |
| 106 | 106 |
| 107 Handle<Code> PlatformCodeStub::GenerateCode() { | 107 Handle<Code> PlatformCodeStub::GenerateCode() { |
| 108 Factory* factory = isolate()->factory(); | 108 Factory* factory = isolate()->factory(); |
| 109 | 109 |
| 110 // Generate the new code. | 110 // Generate the new code. |
| 111 MacroAssembler masm(isolate(), NULL, 256); | 111 MacroAssembler masm(isolate(), NULL, 256, CodeObjectRequired::kYes); |
| 112 | 112 |
| 113 { | 113 { |
| 114 // Update the static counter each time a new code stub is generated. | 114 // Update the static counter each time a new code stub is generated. |
| 115 isolate()->counters()->code_stubs()->Increment(); | 115 isolate()->counters()->code_stubs()->Increment(); |
| 116 | 116 |
| 117 // Generate the code for the stub. | 117 // Generate the code for the stub. |
| 118 masm.set_generating_stub(true); | 118 masm.set_generating_stub(true); |
| 119 // TODO(yangguo): remove this once we can serialize IC stubs. | 119 // TODO(yangguo): remove this once we can serialize IC stubs. |
| 120 masm.enable_serializer(); | 120 masm.enable_serializer(); |
| 121 NoCurrentFrameScope scope(&masm); | 121 NoCurrentFrameScope scope(&masm); |
| (...skipping 932 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1054 if (type->Is(Type::UntaggedPointer())) { | 1054 if (type->Is(Type::UntaggedPointer())) { |
| 1055 return Representation::External(); | 1055 return Representation::External(); |
| 1056 } | 1056 } |
| 1057 | 1057 |
| 1058 DCHECK(!type->Is(Type::Untagged())); | 1058 DCHECK(!type->Is(Type::Untagged())); |
| 1059 return Representation::Tagged(); | 1059 return Representation::Tagged(); |
| 1060 } | 1060 } |
| 1061 | 1061 |
| 1062 } // namespace internal | 1062 } // namespace internal |
| 1063 } // namespace v8 | 1063 } // namespace v8 |
| OLD | NEW |