| OLD | NEW |
| 1 // Copyright (c) 1994-2006 Sun Microsystems Inc. | 1 // Copyright (c) 1994-2006 Sun Microsystems Inc. |
| 2 // All Rights Reserved. | 2 // All Rights Reserved. |
| 3 // | 3 // |
| 4 // Redistribution and use in source and binary forms, with or without | 4 // Redistribution and use in source and binary forms, with or without |
| 5 // modification, are permitted provided that the following conditions are | 5 // modification, are permitted provided that the following conditions are |
| 6 // met: | 6 // met: |
| 7 // | 7 // |
| 8 // - Redistributions of source code must retain the above copyright notice, | 8 // - Redistributions of source code must retain the above copyright notice, |
| 9 // this list of conditions and the following disclaimer. | 9 // this list of conditions and the following disclaimer. |
| 10 // | 10 // |
| (...skipping 1956 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1967 return 1; // Number of instructions patched. | 1967 return 1; // Number of instructions patched. |
| 1968 } | 1968 } |
| 1969 } | 1969 } |
| 1970 | 1970 |
| 1971 | 1971 |
| 1972 void Assembler::GrowBuffer() { | 1972 void Assembler::GrowBuffer() { |
| 1973 if (!own_buffer_) FATAL("external code buffer is too small"); | 1973 if (!own_buffer_) FATAL("external code buffer is too small"); |
| 1974 | 1974 |
| 1975 // Compute new buffer size. | 1975 // Compute new buffer size. |
| 1976 CodeDesc desc; // The new buffer. | 1976 CodeDesc desc; // The new buffer. |
| 1977 if (buffer_size_ < 4*KB) { | 1977 if (buffer_size_ < 1 * MB) { |
| 1978 desc.buffer_size = 4*KB; | |
| 1979 } else if (buffer_size_ < 1*MB) { | |
| 1980 desc.buffer_size = 2*buffer_size_; | 1978 desc.buffer_size = 2*buffer_size_; |
| 1981 } else { | 1979 } else { |
| 1982 desc.buffer_size = buffer_size_ + 1*MB; | 1980 desc.buffer_size = buffer_size_ + 1*MB; |
| 1983 } | 1981 } |
| 1984 CHECK_GT(desc.buffer_size, 0); // No overflow. | 1982 CHECK_GT(desc.buffer_size, 0); // No overflow. |
| 1985 | 1983 |
| 1986 // Set up new buffer. | 1984 // Set up new buffer. |
| 1987 desc.buffer = NewArray<byte>(desc.buffer_size); | 1985 desc.buffer = NewArray<byte>(desc.buffer_size); |
| 1988 | 1986 |
| 1989 desc.instr_size = pc_offset(); | 1987 desc.instr_size = pc_offset(); |
| (...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2314 void Assembler::PopulateConstantPool(ConstantPoolArray* constant_pool) { | 2312 void Assembler::PopulateConstantPool(ConstantPoolArray* constant_pool) { |
| 2315 // No out-of-line constant pool support. | 2313 // No out-of-line constant pool support. |
| 2316 DCHECK(!FLAG_enable_ool_constant_pool); | 2314 DCHECK(!FLAG_enable_ool_constant_pool); |
| 2317 return; | 2315 return; |
| 2318 } | 2316 } |
| 2319 | 2317 |
| 2320 | 2318 |
| 2321 } } // namespace v8::internal | 2319 } } // namespace v8::internal |
| 2322 | 2320 |
| 2323 #endif // V8_TARGET_ARCH_MIPS | 2321 #endif // V8_TARGET_ARCH_MIPS |
| OLD | NEW |