Index: runtime/vm/assembler_mips_test.cc |
=================================================================== |
--- runtime/vm/assembler_mips_test.cc (revision 24294) |
+++ runtime/vm/assembler_mips_test.cc (working copy) |
@@ -1649,6 +1649,22 @@ |
} |
+ASSEMBLER_TEST_GENERATE(Cop1CvtSD, assembler) { |
+ __ LoadImmediate(D2, -42.42); |
+ __ cvtsd(F2, D2); |
+ __ cvtds(D0, F2); |
+ __ Ret(); |
+} |
+ |
+ |
+ASSEMBLER_TEST_RUN(Cop1CvtSD, test) { |
+ typedef double (*SimpleCode)(); |
+ EXPECT(test != NULL); |
+ double res = EXECUTE_TEST_CODE_DOUBLE(SimpleCode, test->entry()); |
+ EXPECT_FLOAT_EQ(-42.42, res, 0.001); |
+} |
+ |
+ |
// Called from assembler_test.cc. |
// RA: return address. |
// A0: context. |