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

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

Issue 1899183002: [heap] Disallow allocation on the last page in address range (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: SetCC to LeaveCC on arm Created 4 years, 8 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
« no previous file with comments | « no previous file | src/arm64/macro-assembler-arm64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #if V8_TARGET_ARCH_ARM 7 #if V8_TARGET_ARCH_ARM
8 8
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/base/division-by-constant.h" 10 #include "src/base/division-by-constant.h"
(...skipping 2054 matching lines...) Expand 10 before | Expand all | Expand 10 after
2065 int shift = 0; 2065 int shift = 0;
2066 while (object_size != 0) { 2066 while (object_size != 0) {
2067 if (((object_size >> shift) & 0x03) == 0) { 2067 if (((object_size >> shift) & 0x03) == 0) {
2068 shift += 2; 2068 shift += 2;
2069 } else { 2069 } else {
2070 int bits = object_size & (0xff << shift); 2070 int bits = object_size & (0xff << shift);
2071 object_size -= bits; 2071 object_size -= bits;
2072 shift += 8; 2072 shift += 8;
2073 Operand bits_operand(bits); 2073 Operand bits_operand(bits);
2074 DCHECK(bits_operand.instructions_required(this) == 1); 2074 DCHECK(bits_operand.instructions_required(this) == 1);
2075 add(result_end, source, bits_operand, SetCC, cond); 2075 add(result_end, source, bits_operand, LeaveCC, cond);
2076 source = result_end; 2076 source = result_end;
2077 cond = cc; 2077 cond = cc;
2078 } 2078 }
2079 } 2079 }
2080 b(cs, gc_required);
2081 cmp(result_end, Operand(alloc_limit)); 2080 cmp(result_end, Operand(alloc_limit));
2082 b(hi, gc_required); 2081 b(hi, gc_required);
2083 str(result_end, MemOperand(top_address)); 2082 str(result_end, MemOperand(top_address));
2084 2083
2085 // Tag object if requested. 2084 // Tag object if requested.
2086 if ((flags & TAG_OBJECT) != 0) { 2085 if ((flags & TAG_OBJECT) != 0) {
2087 add(result, result, Operand(kHeapObjectTag)); 2086 add(result, result, Operand(kHeapObjectTag));
2088 } 2087 }
2089 } 2088 }
2090 2089
(...skipping 1855 matching lines...) Expand 10 before | Expand all | Expand 10 after
3946 } 3945 }
3947 } 3946 }
3948 if (mag.shift > 0) mov(result, Operand(result, ASR, mag.shift)); 3947 if (mag.shift > 0) mov(result, Operand(result, ASR, mag.shift));
3949 add(result, result, Operand(dividend, LSR, 31)); 3948 add(result, result, Operand(dividend, LSR, 31));
3950 } 3949 }
3951 3950
3952 } // namespace internal 3951 } // namespace internal
3953 } // namespace v8 3952 } // namespace v8
3954 3953
3955 #endif // V8_TARGET_ARCH_ARM 3954 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « no previous file | src/arm64/macro-assembler-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698