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/arm64/macro-assembler-arm64-inl.h

Issue 311133003: ARM64: Add and use SmiTagAndPush. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « src/arm64/macro-assembler-arm64.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 #ifndef V8_ARM64_MACRO_ASSEMBLER_ARM64_INL_H_ 5 #ifndef V8_ARM64_MACRO_ASSEMBLER_ARM64_INL_H_
6 #define V8_ARM64_MACRO_ASSEMBLER_ARM64_INL_H_ 6 #define V8_ARM64_MACRO_ASSEMBLER_ARM64_INL_H_
7 7
8 #include <ctype.h> 8 #include <ctype.h>
9 9
10 #include "src/globals.h" 10 #include "src/globals.h"
(...skipping 1332 matching lines...) Expand 10 before | Expand all | Expand 10 after
1343 Register src, 1343 Register src,
1344 UntagMode mode) { 1344 UntagMode mode) {
1345 ASSERT(dst.Is32Bits() && src.Is64Bits()); 1345 ASSERT(dst.Is32Bits() && src.Is64Bits());
1346 if (FLAG_enable_slow_asserts && (mode == kNotSpeculativeUntag)) { 1346 if (FLAG_enable_slow_asserts && (mode == kNotSpeculativeUntag)) {
1347 AssertSmi(src); 1347 AssertSmi(src);
1348 } 1348 }
1349 Scvtf(dst, src, kSmiShift); 1349 Scvtf(dst, src, kSmiShift);
1350 } 1350 }
1351 1351
1352 1352
1353 void MacroAssembler::SmiTagAndPush(Register src) {
1354 STATIC_ASSERT((kSmiShift == 32) && (kSmiTag == 0));
1355 Push(src.W(), wzr);
1356 }
1357
1358
1359 void MacroAssembler::SmiTagAndPush(Register src1, Register src2) {
1360 STATIC_ASSERT((kSmiShift == 32) && (kSmiTag == 0));
1361 Push(src1.W(), wzr, src2.W(), wzr);
1362 }
1363
1364
1353 void MacroAssembler::JumpIfSmi(Register value, 1365 void MacroAssembler::JumpIfSmi(Register value,
1354 Label* smi_label, 1366 Label* smi_label,
1355 Label* not_smi_label) { 1367 Label* not_smi_label) {
1356 STATIC_ASSERT((kSmiTagSize == 1) && (kSmiTag == 0)); 1368 STATIC_ASSERT((kSmiTagSize == 1) && (kSmiTag == 0));
1357 // Check if the tag bit is set. 1369 // Check if the tag bit is set.
1358 if (smi_label) { 1370 if (smi_label) {
1359 Tbz(value, 0, smi_label); 1371 Tbz(value, 0, smi_label);
1360 if (not_smi_label) { 1372 if (not_smi_label) {
1361 B(not_smi_label); 1373 B(not_smi_label);
1362 } 1374 }
(...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after
1689 // characters are reserved for controlling features of the instrumentation. 1701 // characters are reserved for controlling features of the instrumentation.
1690 ASSERT(isprint(marker_name[0]) && isprint(marker_name[1])); 1702 ASSERT(isprint(marker_name[0]) && isprint(marker_name[1]));
1691 1703
1692 InstructionAccurateScope scope(this, 1); 1704 InstructionAccurateScope scope(this, 1);
1693 movn(xzr, (marker_name[1] << 8) | marker_name[0]); 1705 movn(xzr, (marker_name[1] << 8) | marker_name[0]);
1694 } 1706 }
1695 1707
1696 } } // namespace v8::internal 1708 } } // namespace v8::internal
1697 1709
1698 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_INL_H_ 1710 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_INL_H_
OLDNEW
« no previous file with comments | « src/arm64/macro-assembler-arm64.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698