Skip to content

Commit 40fe360

Browse files
committed
remove ExplodeLoop annotations from storages
1 parent a6ca186 commit 40fe360

File tree

7 files changed

+0
-32
lines changed

7 files changed

+0
-32
lines changed

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/runtime/sequence/storage/BoolSequenceStorage.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
import java.util.Arrays;
2929

3030
import com.oracle.graal.python.runtime.sequence.SequenceUtil;
31-
import com.oracle.truffle.api.nodes.ExplodeLoop;
3231

3332
public final class BoolSequenceStorage extends TypedSequenceStorage {
3433

@@ -266,7 +265,6 @@ public int index(Object value) {
266265

267266
}
268267

269-
@ExplodeLoop
270268
public int indexOfBool(boolean value) {
271269
for (int i = 0; i < length; i++) {
272270
if (values[i] == value) {
@@ -313,7 +311,6 @@ public void extendWithBoolStorage(BoolSequenceStorage other) throws ArithmeticEx
313311
length = extendedLength;
314312
}
315313

316-
@ExplodeLoop
317314
@Override
318315
public void reverse() {
319316
if (length > 0) {
@@ -330,7 +327,6 @@ public void reverse() {
330327
}
331328

332329
// TODO: Should use Collection for sorting boolean
333-
@ExplodeLoop
334330
@Override
335331
public void sort() {
336332
boolean[] copy = Arrays.copyOf(values, length);
@@ -355,7 +351,6 @@ public Object getIndicativeValue() {
355351
return 0;
356352
}
357353

358-
@ExplodeLoop
359354
@Override
360355
public boolean equals(SequenceStorage other) {
361356
if (other.length() != length() || !(other instanceof BoolSequenceStorage)) {

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/runtime/sequence/storage/ByteSequenceStorage.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@
3232

3333
import com.oracle.graal.python.PythonLanguage;
3434
import com.oracle.graal.python.runtime.sequence.SequenceUtil;
35-
import com.oracle.truffle.api.nodes.ExplodeLoop;
3635

3736
public final class ByteSequenceStorage extends TypedSequenceStorage {
3837

@@ -288,7 +287,6 @@ public int index(Object value) {
288287

289288
}
290289

291-
@ExplodeLoop
292290
public int indexOfByte(byte value) {
293291
for (int i = 0; i < length; i++) {
294292
if (values[i] == value) {
@@ -299,7 +297,6 @@ public int indexOfByte(byte value) {
299297
return -1;
300298
}
301299

302-
@ExplodeLoop
303300
public int indexOfInt(int value) {
304301
for (int i = 0; i < length; i++) {
305302
if ((values[i] & 0xFF) == value) {
@@ -342,7 +339,6 @@ public void extend(SequenceStorage other) throws SequenceStoreException {
342339
}
343340
}
344341

345-
// @ExplodeLoop
346342
public void extendWithByteStorage(ByteSequenceStorage other) {
347343
int extendedLength = length + other.length();
348344
ensureCapacity(extendedLength);

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/runtime/sequence/storage/IntSequenceStorage.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
import java.util.Arrays;
2929

3030
import com.oracle.graal.python.runtime.sequence.SequenceUtil;
31-
import com.oracle.truffle.api.nodes.ExplodeLoop;
3231

3332
public final class IntSequenceStorage extends TypedSequenceStorage {
3433

@@ -312,7 +311,6 @@ public void extendWithIntStorage(IntSequenceStorage other) {
312311
length = extendedLength;
313312
}
314313

315-
@ExplodeLoop
316314
@Override
317315
public void reverse() {
318316
if (length > 0) {
@@ -328,7 +326,6 @@ public void reverse() {
328326
}
329327
}
330328

331-
@ExplodeLoop
332329
@Override
333330
public void sort() {
334331
int[] copy = Arrays.copyOf(values, length);
@@ -342,7 +339,6 @@ public Object getIndicativeValue() {
342339
return 0;
343340
}
344341

345-
@ExplodeLoop
346342
@Override
347343
public boolean equals(SequenceStorage other) {
348344
if (other.length() != length() || !(other instanceof IntSequenceStorage)) {

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/runtime/sequence/storage/ListSequenceStorage.java

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929

3030
import com.oracle.graal.python.builtins.objects.list.PList;
3131
import com.oracle.graal.python.runtime.sequence.SequenceUtil;
32-
import com.oracle.truffle.api.nodes.ExplodeLoop;
3332

3433
public final class ListSequenceStorage extends TypedSequenceStorage {
3534

@@ -286,7 +285,6 @@ public int index(Object value) {
286285

287286
}
288287

289-
@ExplodeLoop
290288
public int indexOfList(PList value) {
291289
for (int i = 0; i < length; i++) {
292290
if (values[i] == value) {
@@ -327,7 +325,6 @@ public void extend(SequenceStorage other) throws SequenceStoreException {
327325
}
328326
}
329327

330-
@ExplodeLoop
331328
public void extendWithListStorage(ListSequenceStorage other) {
332329
int extendedLength = length + other.length();
333330
ensureCapacity(extendedLength);
@@ -340,7 +337,6 @@ public void extendWithListStorage(ListSequenceStorage other) {
340337
length = extendedLength;
341338
}
342339

343-
@ExplodeLoop
344340
@Override
345341
public void reverse() {
346342
if (length > 0) {
@@ -356,7 +352,6 @@ public void reverse() {
356352
}
357353
}
358354

359-
@ExplodeLoop
360355
@Override
361356
public void sort() {
362357
// TODO: need to be tested
@@ -371,7 +366,6 @@ public Object getIndicativeValue() {
371366
return length > 0 ? values[0] : null;
372367
}
373368

374-
@ExplodeLoop
375369
@Override
376370
public boolean equals(SequenceStorage other) {
377371
// TODO: equal algorithm might need more tests

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/runtime/sequence/storage/LongSequenceStorage.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
import java.util.Arrays;
3030

3131
import com.oracle.graal.python.runtime.sequence.SequenceUtil;
32-
import com.oracle.truffle.api.nodes.ExplodeLoop;
3332

3433
public final class LongSequenceStorage extends TypedSequenceStorage {
3534

@@ -274,7 +273,6 @@ public int index(Object val) {
274273

275274
}
276275

277-
@ExplodeLoop
278276
public int indexOfLong(long value) {
279277
for (int i = 0; i < length; i++) {
280278
if (values[i] == value) {
@@ -324,7 +322,6 @@ public void extendWithLongStorage(LongSequenceStorage other) {
324322
length = extendedLength;
325323
}
326324

327-
@ExplodeLoop
328325
@Override
329326
public void reverse() {
330327
if (length > 0) {
@@ -340,7 +337,6 @@ public void reverse() {
340337
}
341338
}
342339

343-
@ExplodeLoop
344340
@Override
345341
public void sort() {
346342
long[] copy = Arrays.copyOf(values, length);
@@ -354,7 +350,6 @@ public Object getIndicativeValue() {
354350
return 0;
355351
}
356352

357-
@ExplodeLoop
358353
@Override
359354
public boolean equals(SequenceStorage other) {
360355
if (other.length() != length() || !(other instanceof LongSequenceStorage)) {

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/runtime/sequence/storage/ObjectSequenceStorage.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
import java.util.Arrays;
2929

3030
import com.oracle.graal.python.runtime.sequence.SequenceUtil;
31-
import com.oracle.truffle.api.nodes.ExplodeLoop;
3231

3332
public final class ObjectSequenceStorage extends BasicSequenceStorage {
3433

@@ -266,7 +265,6 @@ public Object getIndicativeValue() {
266265
}
267266

268267
@Override
269-
@ExplodeLoop
270268
public boolean equals(SequenceStorage other) {
271269
if (other.length() != length()) {
272270
return false;

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/runtime/sequence/storage/TupleSequenceStorage.java

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929

3030
import com.oracle.graal.python.builtins.objects.tuple.PTuple;
3131
import com.oracle.graal.python.runtime.sequence.SequenceUtil;
32-
import com.oracle.truffle.api.nodes.ExplodeLoop;
3332

3433
public final class TupleSequenceStorage extends TypedSequenceStorage {
3534

@@ -267,7 +266,6 @@ public int index(Object value) {
267266

268267
}
269268

270-
@ExplodeLoop
271269
public int indexOfPTuple(PTuple value) {
272270
for (int i = 0; i < length; i++) {
273271
if (values[i] == value) {
@@ -302,7 +300,6 @@ public void extend(SequenceStorage other) throws SequenceStoreException {
302300
}
303301
}
304302

305-
@ExplodeLoop
306303
public void extendWithPTupleStorage(TupleSequenceStorage other) {
307304
int extendedLength = length + other.length();
308305
ensureCapacity(extendedLength);
@@ -315,7 +312,6 @@ public void extendWithPTupleStorage(TupleSequenceStorage other) {
315312
length = extendedLength;
316313
}
317314

318-
@ExplodeLoop
319315
@Override
320316
public void reverse() {
321317
if (length > 0) {
@@ -331,7 +327,6 @@ public void reverse() {
331327
}
332328
}
333329

334-
@ExplodeLoop
335330
@Override
336331
public void sort() {
337332
PTuple[] copy = Arrays.copyOf(values, length);
@@ -345,7 +340,6 @@ public Object getIndicativeValue() {
345340
return length > 0 ? values[0] : null;
346341
}
347342

348-
@ExplodeLoop
349343
@Override
350344
public boolean equals(SequenceStorage other) {
351345
if (other.length() != length() || !(other instanceof TupleSequenceStorage)) {

0 commit comments

Comments
 (0)