| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 1111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1122 // when shortening objects. | 1122 // when shortening objects. |
| 1123 void CreateFillerObjectAt(Address addr, int size); | 1123 void CreateFillerObjectAt(Address addr, int size); |
| 1124 | 1124 |
| 1125 bool CanMoveObjectStart(HeapObject* object); | 1125 bool CanMoveObjectStart(HeapObject* object); |
| 1126 | 1126 |
| 1127 enum InvocationMode { FROM_GC, FROM_MUTATOR }; | 1127 enum InvocationMode { FROM_GC, FROM_MUTATOR }; |
| 1128 | 1128 |
| 1129 // Maintain marking consistency for IncrementalMarking. | 1129 // Maintain marking consistency for IncrementalMarking. |
| 1130 void AdjustLiveBytes(Address address, int by, InvocationMode mode); | 1130 void AdjustLiveBytes(Address address, int by, InvocationMode mode); |
| 1131 | 1131 |
| 1132 // Makes a new native code object | 1132 MUST_USE_RESULT MaybeObject* AllocateCode(int object_size, bool immovable); |
| 1133 // Returns Failure::RetryAfterGC(requested_bytes, space) if the allocation | |
| 1134 // failed. On success, the pointer to the Code object is stored in the | |
| 1135 // self_reference. This allows generated code to reference its own Code | |
| 1136 // object by containing this pointer. | |
| 1137 // Please note this function does not perform a garbage collection. | |
| 1138 MUST_USE_RESULT MaybeObject* CreateCode( | |
| 1139 const CodeDesc& desc, | |
| 1140 Code::Flags flags, | |
| 1141 Handle<Object> self_reference, | |
| 1142 bool immovable = false, | |
| 1143 bool crankshafted = false, | |
| 1144 int prologue_offset = Code::kPrologueOffsetNotSet); | |
| 1145 | 1133 |
| 1146 MUST_USE_RESULT MaybeObject* CopyCode(Code* code); | 1134 MUST_USE_RESULT MaybeObject* CopyCode(Code* code); |
| 1147 | 1135 |
| 1148 // Copy the code and scope info part of the code object, but insert | 1136 // Copy the code and scope info part of the code object, but insert |
| 1149 // the provided data as the relocation information. | 1137 // the provided data as the relocation information. |
| 1150 MUST_USE_RESULT MaybeObject* CopyCode(Code* code, Vector<byte> reloc_info); | 1138 MUST_USE_RESULT MaybeObject* CopyCode(Code* code, Vector<byte> reloc_info); |
| 1151 | 1139 |
| 1152 // Finds the internalized copy for string in the string table. | 1140 // Finds the internalized copy for string in the string table. |
| 1153 // If not found, a new string is added to the table and returned. | 1141 // If not found, a new string is added to the table and returned. |
| 1154 // Returns Failure::RetryAfterGC(requested_bytes, space) if allocation | 1142 // Returns Failure::RetryAfterGC(requested_bytes, space) if allocation |
| (...skipping 1903 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3058 DisallowHeapAllocation no_allocation; // i.e. no gc allowed. | 3046 DisallowHeapAllocation no_allocation; // i.e. no gc allowed. |
| 3059 | 3047 |
| 3060 private: | 3048 private: |
| 3061 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); | 3049 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); |
| 3062 }; | 3050 }; |
| 3063 #endif // DEBUG | 3051 #endif // DEBUG |
| 3064 | 3052 |
| 3065 } } // namespace v8::internal | 3053 } } // namespace v8::internal |
| 3066 | 3054 |
| 3067 #endif // V8_HEAP_H_ | 3055 #endif // V8_HEAP_H_ |
| OLD | NEW |