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

Side by Side Diff: src/arm/macro-assembler-arm.cc

Issue 950283002: Move Maps' back pointers from "transitions" to "constructor" field (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 10 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
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 <limits.h> // For LONG_MIN, LONG_MAX. 5 #include <limits.h> // For LONG_MIN, LONG_MAX.
6 6
7 #include "src/v8.h" 7 #include "src/v8.h"
8 8
9 #if V8_TARGET_ARCH_ARM 9 #if V8_TARGET_ARCH_ARM
10 10
(...skipping 2274 matching lines...) Expand 10 before | Expand all | Expand 10 after
2285 } 2285 }
2286 2286
2287 2287
2288 void MacroAssembler::LoadWeakValue(Register value, Handle<WeakCell> cell, 2288 void MacroAssembler::LoadWeakValue(Register value, Handle<WeakCell> cell,
2289 Label* miss) { 2289 Label* miss) {
2290 GetWeakValue(value, cell); 2290 GetWeakValue(value, cell);
2291 JumpIfSmi(value, miss); 2291 JumpIfSmi(value, miss);
2292 } 2292 }
2293 2293
2294 2294
2295 void MacroAssembler::GetMapConstructor(Register result, Register map,
2296 Register temp, Register temp2) {
2297 Label done, loop;
2298 ldr(result, FieldMemOperand(map, Map::kConstructorOrBackPointerOffset));
2299 bind(&loop);
2300 CompareObjectType(result, temp, temp2, MAP_TYPE);
2301 b(ne, &done);
2302 ldr(result, FieldMemOperand(result, Map::kConstructorOrBackPointerOffset));
2303 b(&loop);
2304 bind(&done);
2305 }
2306
2307
2295 void MacroAssembler::TryGetFunctionPrototype(Register function, 2308 void MacroAssembler::TryGetFunctionPrototype(Register function,
2296 Register result, 2309 Register result,
2297 Register scratch, 2310 Register scratch,
2298 Label* miss, 2311 Label* miss,
2299 bool miss_on_bound_function) { 2312 bool miss_on_bound_function) {
2300 Label non_instance; 2313 Label non_instance;
2301 if (miss_on_bound_function) { 2314 if (miss_on_bound_function) {
2302 // Check that the receiver isn't a smi. 2315 // Check that the receiver isn't a smi.
2303 JumpIfSmi(function, miss); 2316 JumpIfSmi(function, miss);
2304 2317
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
2338 2351
2339 // Get the prototype from the initial map. 2352 // Get the prototype from the initial map.
2340 ldr(result, FieldMemOperand(result, Map::kPrototypeOffset)); 2353 ldr(result, FieldMemOperand(result, Map::kPrototypeOffset));
2341 2354
2342 if (miss_on_bound_function) { 2355 if (miss_on_bound_function) {
2343 jmp(&done); 2356 jmp(&done);
2344 2357
2345 // Non-instance prototype: Fetch prototype from constructor field 2358 // Non-instance prototype: Fetch prototype from constructor field
2346 // in initial map. 2359 // in initial map.
2347 bind(&non_instance); 2360 bind(&non_instance);
2348 ldr(result, FieldMemOperand(result, Map::kConstructorOffset)); 2361 ldr(result, FieldMemOperand(result, Map::kConstructorOrBackPointerOffset));
2349 } 2362 }
2350 2363
2351 // All done. 2364 // All done.
2352 bind(&done); 2365 bind(&done);
2353 } 2366 }
2354 2367
2355 2368
2356 void MacroAssembler::CallStub(CodeStub* stub, 2369 void MacroAssembler::CallStub(CodeStub* stub,
2357 TypeFeedbackId ast_id, 2370 TypeFeedbackId ast_id,
2358 Condition cond) { 2371 Condition cond) {
(...skipping 1616 matching lines...) Expand 10 before | Expand all | Expand 10 after
3975 } 3988 }
3976 } 3989 }
3977 if (mag.shift > 0) mov(result, Operand(result, ASR, mag.shift)); 3990 if (mag.shift > 0) mov(result, Operand(result, ASR, mag.shift));
3978 add(result, result, Operand(dividend, LSR, 31)); 3991 add(result, result, Operand(dividend, LSR, 31));
3979 } 3992 }
3980 3993
3981 } // namespace internal 3994 } // namespace internal
3982 } // namespace v8 3995 } // namespace v8
3983 3996
3984 #endif // V8_TARGET_ARCH_ARM 3997 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm/macro-assembler-arm.h ('k') | src/arm64/full-codegen-arm64.cc » ('j') | src/objects.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698