diff options
author | Mathieu Chartier <mathieuc@google.com> | 2014-11-25 18:36:01 -0800 |
---|---|---|
committer | Mathieu Chartier <mathieuc@google.com> | 2014-11-26 11:16:28 -0800 |
commit | cd195fe131842ad9ca7909203d479d325feaf9dd (patch) | |
tree | 951be836646a63d4b7300466718d1cd222d01e11 /runtime/mirror/class.h | |
parent | 3c17775c45277e90da10296d90f0f474f4a1b84a (diff) | |
download | android_art-cd195fe131842ad9ca7909203d479d325feaf9dd.tar.gz android_art-cd195fe131842ad9ca7909203d479d325feaf9dd.tar.bz2 android_art-cd195fe131842ad9ca7909203d479d325feaf9dd.zip |
Add a way to change the IMT size
Useful for having smaller imts on memory constrainted devices.
Setting ART_IMT_SIZE=x will change the size of the IMT.
(cherry picked from commit 8ee96437f8cd24e1eb0b2adc6cef3346ed4b6a98)
Change-Id: Ia74946ffc57ad32de5a8d60be3412462f19f8076
Diffstat (limited to 'runtime/mirror/class.h')
-rw-r--r-- | runtime/mirror/class.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/runtime/mirror/class.h b/runtime/mirror/class.h index a77972efc5..56867dd319 100644 --- a/runtime/mirror/class.h +++ b/runtime/mirror/class.h @@ -29,6 +29,10 @@ #include "read_barrier_option.h" #include "utils.h" +#ifndef IMT_SIZE +#error IMT_SIZE not defined +#endif + namespace art { struct ClassOffsets; @@ -58,7 +62,7 @@ class MANAGED Class FINAL : public Object { // Interface method table size. Increasing this value reduces the chance of two interface methods // colliding in the interface method table but increases the size of classes that implement // (non-marker) interfaces. - static constexpr size_t kImtSize = 64; + static constexpr size_t kImtSize = IMT_SIZE; // imtable entry embedded in class object. struct MANAGED ImTableEntry { |