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

Unified Diff: runtime/vm/intrinsifier_arm.cc

Issue 2005723004: Fraction class prototype and test (not to be committed). (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: work in progress Created 4 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/intermediate_language.cc ('k') | runtime/vm/intrinsifier_arm64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/intrinsifier_arm.cc
diff --git a/runtime/vm/intrinsifier_arm.cc b/runtime/vm/intrinsifier_arm.cc
index 2daafedeeafe74c9f895d599b153b6769e5c8c24..2397f340b3db7a4d26e40e7e62283039b4fe43cc 100644
--- a/runtime/vm/intrinsifier_arm.cc
+++ b/runtime/vm/intrinsifier_arm.cc
@@ -707,11 +707,14 @@ void Intrinsifier::Integer_equalToInteger(Assembler* assembler) {
__ tst(R1, Operand(kSmiTagMask)); // Check receiver.
__ b(&receiver_not_smi, NE);
- // Left (receiver) is Smi, return false if right is not Double.
+ // Left (receiver) is Smi, return false if right is not Double or Fraction.
// Note that an instance of Mint or Bigint never contains a value that can be
// represented by Smi.
- __ CompareClassId(R0, kDoubleCid, R2);
+ __ LoadClassId(R2, R0);
+ __ CompareImmediate(R2, kDoubleCid);
+ __ b(&fall_through, EQ);
+ __ CompareImmediate(R2, kFractionCid);
__ b(&fall_through, EQ);
__ LoadObject(R0, Bool::False()); // Smi == Mint -> false.
__ Ret();
« no previous file with comments | « runtime/vm/intermediate_language.cc ('k') | runtime/vm/intrinsifier_arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698