OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
2 // | 2 // |
3 // Redistribution and use in source and binary forms, with or without | 3 // Redistribution and use in source and binary forms, with or without |
4 // modification, are permitted provided that the following conditions are | 4 // modification, are permitted provided that the following conditions are |
5 // met: | 5 // met: |
6 // | 6 // |
7 // * Redistributions of source code must retain the above copyright | 7 // * Redistributions of source code must retain the above copyright |
8 // notice, this list of conditions and the following disclaimer. | 8 // notice, this list of conditions and the following disclaimer. |
9 // * Redistributions in binary form must reproduce the above | 9 // * Redistributions in binary form must reproduce the above |
10 // copyright notice, this list of conditions and the following | 10 // copyright notice, this list of conditions and the following |
(...skipping 3124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3135 } | 3135 } |
3136 | 3136 |
3137 | 3137 |
3138 void Assembler::RecordConstPool(int size) { | 3138 void Assembler::RecordConstPool(int size) { |
3139 // We only need this for debugger support, to correctly compute offsets in the | 3139 // We only need this for debugger support, to correctly compute offsets in the |
3140 // code. | 3140 // code. |
3141 RecordRelocInfo(RelocInfo::CONST_POOL, static_cast<intptr_t>(size)); | 3141 RecordRelocInfo(RelocInfo::CONST_POOL, static_cast<intptr_t>(size)); |
3142 } | 3142 } |
3143 | 3143 |
3144 | 3144 |
3145 Handle<ConstantPoolArray> Assembler::NewConstantPool(Isolate* isolate) { | |
3146 // No out-of-line constant pool support. | |
3147 DCHECK(!FLAG_enable_ool_constant_pool); | |
3148 return isolate->factory()->empty_constant_pool_array(); | |
3149 } | |
3150 | |
3151 | |
3152 void Assembler::PopulateConstantPool(ConstantPoolArray* constant_pool) { | |
3153 // No out-of-line constant pool support. | |
3154 DCHECK(!FLAG_enable_ool_constant_pool); | |
3155 return; | |
3156 } | |
3157 | |
3158 | |
3159 void PatchingAssembler::PatchAdrFar(int64_t target_offset) { | 3145 void PatchingAssembler::PatchAdrFar(int64_t target_offset) { |
3160 // The code at the current instruction should be: | 3146 // The code at the current instruction should be: |
3161 // adr rd, 0 | 3147 // adr rd, 0 |
3162 // nop (adr_far) | 3148 // nop (adr_far) |
3163 // nop (adr_far) | 3149 // nop (adr_far) |
3164 // movz scratch, 0 | 3150 // movz scratch, 0 |
3165 | 3151 |
3166 // Verify the expected code. | 3152 // Verify the expected code. |
3167 Instruction* expected_adr = InstructionAt(0); | 3153 Instruction* expected_adr = InstructionAt(0); |
3168 CHECK(expected_adr->IsAdr() && (expected_adr->ImmPCRel() == 0)); | 3154 CHECK(expected_adr->IsAdr() && (expected_adr->ImmPCRel() == 0)); |
(...skipping 17 matching lines...) Expand all Loading... |
3186 movk(scratch, (target_offset >> 32) & 0xFFFF, 32); | 3172 movk(scratch, (target_offset >> 32) & 0xFFFF, 32); |
3187 DCHECK((target_offset >> 48) == 0); | 3173 DCHECK((target_offset >> 48) == 0); |
3188 add(rd, rd, scratch); | 3174 add(rd, rd, scratch); |
3189 } | 3175 } |
3190 | 3176 |
3191 | 3177 |
3192 } // namespace internal | 3178 } // namespace internal |
3193 } // namespace v8 | 3179 } // namespace v8 |
3194 | 3180 |
3195 #endif // V8_TARGET_ARCH_ARM64 | 3181 #endif // V8_TARGET_ARCH_ARM64 |
OLD | NEW |