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

Side by Side Diff: src/x87/macro-assembler-x87.h

Issue 1894923002: X87: [Atomics] code stubs for atomic operations. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: 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 | « src/x87/interface-descriptors-x87.cc ('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 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 #ifndef V8_X87_MACRO_ASSEMBLER_X87_H_ 5 #ifndef V8_X87_MACRO_ASSEMBLER_X87_H_
6 #define V8_X87_MACRO_ASSEMBLER_X87_H_ 6 #define V8_X87_MACRO_ASSEMBLER_X87_H_
7 7
8 #include "src/assembler.h" 8 #include "src/assembler.h"
9 #include "src/bailout-reason.h" 9 #include "src/bailout-reason.h"
10 #include "src/frames.h" 10 #include "src/frames.h"
(...skipping 482 matching lines...) Expand 10 before | Expand all | Expand 10 after
493 test(value, Immediate(kSmiTagMask)); 493 test(value, Immediate(kSmiTagMask));
494 j(zero, smi_label, distance); 494 j(zero, smi_label, distance);
495 } 495 }
496 // Jump if register contain a non-smi. 496 // Jump if register contain a non-smi.
497 inline void JumpIfNotSmi(Register value, Label* not_smi_label, 497 inline void JumpIfNotSmi(Register value, Label* not_smi_label,
498 Label::Distance distance = Label::kFar) { 498 Label::Distance distance = Label::kFar) {
499 test(value, Immediate(kSmiTagMask)); 499 test(value, Immediate(kSmiTagMask));
500 j(not_zero, not_smi_label, distance); 500 j(not_zero, not_smi_label, distance);
501 } 501 }
502 502
503 // Jump if the value cannot be represented by a smi.
504 inline void JumpIfNotValidSmiValue(Register value, Register scratch,
505 Label* on_invalid,
506 Label::Distance distance = Label::kFar) {
507 mov(scratch, value);
508 add(scratch, Immediate(0x40000000U));
509 j(sign, on_invalid, distance);
510 }
511
512 // Jump if the unsigned integer value cannot be represented by a smi.
513 inline void JumpIfUIntNotValidSmiValue(
514 Register value, Label* on_invalid,
515 Label::Distance distance = Label::kFar) {
516 cmp(value, Immediate(0x40000000U));
517 j(above_equal, on_invalid, distance);
518 }
519
503 void LoadInstanceDescriptors(Register map, Register descriptors); 520 void LoadInstanceDescriptors(Register map, Register descriptors);
504 void EnumLength(Register dst, Register map); 521 void EnumLength(Register dst, Register map);
505 void NumberOfOwnDescriptors(Register dst, Register map); 522 void NumberOfOwnDescriptors(Register dst, Register map);
506 void LoadAccessor(Register dst, Register holder, int accessor_index, 523 void LoadAccessor(Register dst, Register holder, int accessor_index,
507 AccessorComponent accessor); 524 AccessorComponent accessor);
508 525
509 template<typename Field> 526 template<typename Field>
510 void DecodeField(Register reg) { 527 void DecodeField(Register reg) {
511 static const int shift = Field::kShift; 528 static const int shift = Field::kShift;
512 static const int mask = Field::kMask >> Field::kShift; 529 static const int mask = Field::kMask >> Field::kShift;
(...skipping 515 matching lines...) Expand 10 before | Expand all | Expand 10 after
1028 } \ 1045 } \
1029 masm-> 1046 masm->
1030 #else 1047 #else
1031 #define ACCESS_MASM(masm) masm-> 1048 #define ACCESS_MASM(masm) masm->
1032 #endif 1049 #endif
1033 1050
1034 } // namespace internal 1051 } // namespace internal
1035 } // namespace v8 1052 } // namespace v8
1036 1053
1037 #endif // V8_X87_MACRO_ASSEMBLER_X87_H_ 1054 #endif // V8_X87_MACRO_ASSEMBLER_X87_H_
OLDNEW
« no previous file with comments | « src/x87/interface-descriptors-x87.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698