Revert experimental lambda feature.
This is a revert of the following changes :
30c475a2046951a81769c2db0b2dad66cd71e189.
lambda: Minor capture-variable/liberate-variable clean-up after post-merge reviews.
6918bf13eb855b3aa8ccdddda2d27ae8c60cec56.
lambda: Experimental support for capture-variable and liberate-variable
fc1ccd740b7c8e96dfac675cfc580122cd1b40a6.
lambda: Infrastructure to support capture/liberate-variable dex opcodes
e2facc5b18cd756a8b5500fb3d90da69c9ee0fb7.
runtime: Add lambda box/unbox object equality
2ee54e249ad21c74f29a161e248bebe7d22fddf1.
runtime: Partially implement box-lambda and unbox-lambda experimental opcodes
158f35c98e2ec0d40d2c032b8cdce5fb60944a7f.
interpreter: Add experimental lambda opcodes for invoke/create-lambda
a3bb72036f5454e410467f7151dc89f725ae1151.
Added format 25x to dexdump(2).
Plus surrounding cleanups.
Test: make test-art
Change-Id: Ic6f999ad17385ef933f763641049cf721510b202
diff --git a/runtime/dex_instruction.cc b/runtime/dex_instruction.cc
index d04087a..fabc47b 100644
--- a/runtime/dex_instruction.cc
+++ b/runtime/dex_instruction.cc
@@ -71,7 +71,7 @@
#define INSTRUCTION_SIZE(opcode, c, p, format, i, a, v) \
(((opcode) == NOP) ? -1 : \
(((format) >= k10x) && ((format) <= k10t)) ? 1 : \
- (((format) >= k20t) && ((format) <= k25x)) ? 2 : \
+ (((format) >= k20t) && ((format) <= k22c)) ? 2 : \
(((format) >= k32x) && ((format) <= k3rc)) ? 3 : \
((format) == k51l) ? 5 : -1),
#include "dex_instruction_list.h"
@@ -241,14 +241,6 @@
break;
}
FALLTHROUGH_INTENDED;
- case CREATE_LAMBDA:
- if (file != nullptr) {
- uint32_t method_idx = VRegB_21c();
- os << opcode << " v" << static_cast<int>(VRegA_21c()) << ", " << PrettyMethod(method_idx, *file, true)
- << " // method@" << method_idx;
- break;
- }
- FALLTHROUGH_INTENDED;
default:
os << StringPrintf("%s v%d, thing@%d", opcode, VRegA_21c(), VRegB_21c());
break;
@@ -329,26 +321,6 @@
}
break;
}
- case k25x: {
- if (Opcode() == INVOKE_LAMBDA) {
- uint32_t arg[kMaxVarArgRegs25x];
- GetAllArgs25x(arg);
- const size_t num_extra_var_args = VRegB_25x();
- DCHECK_LE(num_extra_var_args + 2, arraysize(arg));
-
- // invoke-lambda vC, {vD, vE, vF, vG}
- os << opcode << " v" << arg[0] << ", {";
- for (size_t i = 0; i < num_extra_var_args; ++i) {
- if (i != 0) {
- os << ", ";
- }
- os << "v" << arg[i + 2]; // Don't print the pair of vC registers. Pair is implicit.
- }
- os << "}";
- break;
- }
- FALLTHROUGH_INTENDED;
- }
case k32x: os << StringPrintf("%s v%d, v%d", opcode, VRegA_32x(), VRegB_32x()); break;
case k30t: os << StringPrintf("%s %+d", opcode, VRegA_30t()); break;
case k31t: os << StringPrintf("%s v%d, %+d", opcode, VRegA_31t(), VRegB_31t()); break;