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

Side by Side Diff: test/mjsunit/smi-negative-zero.js

Issue 196077: X64: Extract all smi operations into MacroAssembler macros. (Closed)
Patch Set: Created 11 years, 3 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
« src/x64/codegen-x64.cc ('K') | « src/x64/virtual-frame-x64.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 2008 the V8 project authors. All rights reserved. 1 // Copyright 2008 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 29 matching lines...) Expand all
40 assertEquals(one / (-zero), -Infinity, "one / -0 I"); 40 assertEquals(one / (-zero), -Infinity, "one / -0 I");
41 41
42 assertEquals(one / (zero * minus_one), -Infinity, "one / -1"); 42 assertEquals(one / (zero * minus_one), -Infinity, "one / -1");
43 assertEquals(one / (minus_one * zero), -Infinity, "one / -0 II"); 43 assertEquals(one / (minus_one * zero), -Infinity, "one / -0 II");
44 assertEquals(one / (zero * zero), Infinity, "one / 0 I"); 44 assertEquals(one / (zero * zero), Infinity, "one / 0 I");
45 assertEquals(one / (minus_one * minus_one), 1, "one / 1"); 45 assertEquals(one / (minus_one * minus_one), 1, "one / 1");
46 46
47 assertEquals(one / (zero / minus_one), -Infinity, "one / -0 III"); 47 assertEquals(one / (zero / minus_one), -Infinity, "one / -0 III");
48 assertEquals(one / (zero / one), Infinity, "one / 0 II"); 48 assertEquals(one / (zero / one), Infinity, "one / 0 II");
49 49
50 assertEquals(one / (minus_four % two), -Infinity, "foo"); 50 assertEquals(one / (minus_four % two), -Infinity, "foo1");
51 assertEquals(one / (minus_four % minus_two), -Infinity, "foo"); 51 assertEquals(one / (minus_four % minus_two), -Infinity, "foo2");
52 assertEquals(one / (four % two), Infinity, "foo"); 52 assertEquals(one / (four % two), Infinity, "foo3");
53 assertEquals(one / (four % minus_two), Infinity, "foo"); 53 assertEquals(one / (four % minus_two), Infinity, "foo4");
54 54
55 // literal op variable 55 // literal op variable
56 56
57 assertEquals(one / (0 * minus_one), -Infinity, "bar"); 57 assertEquals(one / (0 * minus_one), -Infinity, "bar1");
58 assertEquals(one / (-1 * zero), -Infinity, "bar"); 58 assertEquals(one / (-1 * zero), -Infinity, "bar2");
59 assertEquals(one / (0 * zero), Infinity, "bar"); 59 assertEquals(one / (0 * zero), Infinity, "bar3");
60 assertEquals(one / (-1 * minus_one), 1, "bar"); 60 assertEquals(one / (-1 * minus_one), 1, "bar4");
61 61
62 assertEquals(one / (0 / minus_one), -Infinity, "baz"); 62 assertEquals(one / (0 / minus_one), -Infinity, "baz1");
63 assertEquals(one / (0 / one), Infinity, "baz"); 63 assertEquals(one / (0 / one), Infinity, "baz2");
64 64
65 assertEquals(one / (-4 % two), -Infinity, "baz"); 65 assertEquals(one / (-4 % two), -Infinity, "baz3");
66 assertEquals(one / (-4 % minus_two), -Infinity, "baz"); 66 assertEquals(one / (-4 % minus_two), -Infinity, "baz4");
67 assertEquals(one / (4 % two), Infinity, "baz"); 67 assertEquals(one / (4 % two), Infinity, "baz5");
68 assertEquals(one / (4 % minus_two), Infinity, "baz"); 68 assertEquals(one / (4 % minus_two), Infinity, "baz6");
69 69
70 // variable op literal 70 // variable op literal
71 71
72 assertEquals(one / (zero * -1), -Infinity, "fizz"); 72 assertEquals(one / (zero * -1), -Infinity, "fizz1");
73 assertEquals(one / (minus_one * 0), -Infinity, "fizz"); 73 assertEquals(one / (minus_one * 0), -Infinity, "fizz2");
74 assertEquals(one / (zero * 0), Infinity, "fizz"); 74 assertEquals(one / (zero * 0), Infinity, "fizz3");
75 assertEquals(one / (minus_one * -1), 1, "fizz"); 75 assertEquals(one / (minus_one * -1), 1, "fizz4");
76 76
77 assertEquals(one / (zero / -1), -Infinity, "buzz"); 77 assertEquals(one / (zero / -1), -Infinity, "buzz1");
78 assertEquals(one / (zero / 1), Infinity, "buzz"); 78 assertEquals(one / (zero / 1), Infinity, "buzz2");
79 79
80 assertEquals(one / (minus_four % 2), -Infinity, "buzz"); 80 assertEquals(one / (minus_four % 2), -Infinity, "buzz3");
81 assertEquals(one / (minus_four % -2), -Infinity, "buzz"); 81 assertEquals(one / (minus_four % -2), -Infinity, "buzz4");
82 assertEquals(one / (four % 2), Infinity, "buzz"); 82 assertEquals(one / (four % 2), Infinity, "buzz5");
83 assertEquals(one / (four % -2), Infinity, "buzz"); 83 assertEquals(one / (four % -2), Infinity, "buzz6");
84 84
85 // literal op literal 85 // literal op literal
86 86
87 assertEquals(one / (-0), -Infinity, "fisk1"); 87 assertEquals(one / (-0), -Infinity, "fisk1");
88 88
89 assertEquals(one / (0 * -1), -Infinity, "fisk2"); 89 assertEquals(one / (0 * -1), -Infinity, "fisk2");
90 assertEquals(one / (-1 * 0), -Infinity, "fisk3"); 90 assertEquals(one / (-1 * 0), -Infinity, "fisk3");
91 assertEquals(one / (0 * 0), Infinity, "fisk4"); 91 assertEquals(one / (0 * 0), Infinity, "fisk4");
92 assertEquals(one / (-1 * -1), 1, "fisk5"); 92 assertEquals(one / (-1 * -1), 1, "fisk5");
93 93
94 assertEquals(one / (0 / -1), -Infinity, "hest"); 94 assertEquals(one / (0 / -1), -Infinity, "hest1");
95 assertEquals(one / (0 / 1), Infinity, "hest"); 95 assertEquals(one / (0 / 1), Infinity, "hest2");
96 96
97 assertEquals(one / (-4 % 2), -Infinity, "fiskhest"); 97 assertEquals(one / (-4 % 2), -Infinity, "fiskhest1");
98 assertEquals(one / (-4 % -2), -Infinity, "fiskhest"); 98 assertEquals(one / (-4 % -2), -Infinity, "fiskhest2");
99 assertEquals(one / (4 % 2), Infinity, "fiskhest"); 99 assertEquals(one / (4 % 2), Infinity, "fiskhest3");
100 assertEquals(one / (4 % -2), Infinity, "fiskhest"); 100 assertEquals(one / (4 % -2), Infinity, "fiskhest4");
OLDNEW
« src/x64/codegen-x64.cc ('K') | « src/x64/virtual-frame-x64.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698