Mercurial > hg > truffle
annotate graal/com.oracle.graal.jtt/src/com/oracle/graal/jtt/optimize/InferStamp01.java @ 14529:82c3b54d1f08
added HotSpotConstantPool.JVM_CONSTANT enum
author | twisti |
---|---|
date | Wed, 12 Mar 2014 15:12:28 -0700 |
parents | 2e7e7a22940f |
children | 64dcb92ee75a |
rev | line source |
---|---|
10575
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
1 /* |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
2 * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
4 * |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
5 * This code is free software; you can redistribute it and/or modify it |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
6 * under the terms of the GNU General Public License version 2 only, as |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
7 * published by the Free Software Foundation. |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
8 * |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
9 * This code is distributed in the hope that it will be useful, but WITHOUT |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
12 * version 2 for more details (a copy is included in the LICENSE file that |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
13 * accompanied this code). |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
14 * |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
15 * You should have received a copy of the GNU General Public License version |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
16 * 2 along with this work; if not, write to the Free Software Foundation, |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
18 * |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
20 * or visit www.oracle.com if you need additional information or have any |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
21 * questions. |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
22 */ |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
23 package com.oracle.graal.jtt.optimize; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
24 |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
25 import com.oracle.graal.jtt.*; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
26 import org.junit.*; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
27 |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
28 /** |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
29 * test some stamps in combination with full loop unrolling and shifts. |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
30 */ |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
31 public class InferStamp01 extends JTTTest { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
32 |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
33 public static int testi0(int arg) { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
34 int a = arg; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
35 for (int i = 0; i < 2; i++) { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
36 a = a >> 16; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
37 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
38 return a; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
39 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
40 |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
41 @Test |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
42 public void runi0() throws Throwable { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
43 runTest("testi0", 0x7788_99aa); |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
44 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
45 |
10603
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
46 @Test |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
47 public void runi0neg() throws Throwable { |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
48 runTest("testi0", 0xf788_99aa); |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
49 } |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
50 |
10575
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
51 public static int testi1(int arg) { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
52 int a = arg; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
53 for (int i = 0; i < 2; i++) { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
54 a = a >>> 16; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
55 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
56 return a; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
57 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
58 |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
59 @Test |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
60 public void runi1() throws Throwable { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
61 runTest("testi1", 0x7788_99aa); |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
62 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
63 |
10603
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
64 @Test |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
65 public void runi1neg() throws Throwable { |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
66 runTest("testi1", 0xf788_99aa); |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
67 } |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
68 |
10575
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
69 public static int testi2(int arg) { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
70 int a = arg; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
71 for (int i = 0; i < 2; i++) { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
72 a = a << 16; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
73 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
74 return a; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
75 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
76 |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
77 @Test |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
78 public void runi2() throws Throwable { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
79 runTest("testi2", 0x7788_99aa); |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
80 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
81 |
10603
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
82 @Test |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
83 public void runi2neg() throws Throwable { |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
84 runTest("testi2", 0xf788_99aa); |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
85 } |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
86 |
10575
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
87 public static long testl0(long arg) { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
88 long a = arg; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
89 for (long i = 0; i < 2; i++) { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
90 a = a >> 32; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
91 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
92 return a; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
93 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
94 |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
95 @Test |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
96 public void runl0() throws Throwable { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
97 runTest("testl0", 0x3344_5566_7788_99aaL); |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
98 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
99 |
10603
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
100 @Test |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
101 public void runl0neg() throws Throwable { |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
102 runTest("testl0", 0xf344_5566_7788_99aaL); |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
103 } |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
104 |
10575
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
105 public static long testl1(long arg) { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
106 long a = arg; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
107 for (long i = 0; i < 2; i++) { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
108 a = a >>> 32; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
109 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
110 return a; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
111 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
112 |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
113 @Test |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
114 public void runl1() throws Throwable { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
115 runTest("testl1", 0x3344_5566_7788_99aaL); |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
116 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
117 |
10603
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
118 @Test |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
119 public void runl1neg() throws Throwable { |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
120 runTest("testl1", 0xf344_5566_7788_99aaL); |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
121 } |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
122 |
10575
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
123 public static long testl2(long arg) { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
124 long a = arg; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
125 for (long i = 0; i < 2; i++) { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
126 a = a << 32; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
127 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
128 return a; |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
129 } |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
130 |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
131 @Test |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
132 public void runl2() throws Throwable { |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
133 runTest("testl2", 0x3344_5566_7788_99aaL); |
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
134 } |
10603
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
135 |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
136 @Test |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
137 public void runl2neg() throws Throwable { |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
138 runTest("testl2", 0xf344_5566_7788_99aaL); |
2e7e7a22940f
RightShiftNode: fix canonicalization for negative input
Bernhard Urban <bernhard.urban@jku.at>
parents:
10575
diff
changeset
|
139 } |
10575
97d280a879ff
ShiftNode: add constant with correct stamp in canonical()
Bernhard Urban <bernhard.urban@jku.at>
parents:
diff
changeset
|
140 } |