summaryrefslogtreecommitdiffstats
path: root/runtime/utf.cc
Commit message (Collapse)AuthorAgeFilesLines
* Replace String CharArray with internal uint16_t array.Jeff Hao2015-04-271-9/+0
| | | | | | | | | | | | Summary of high level changes: - Adds compiler inliner support to identify string init methods - Adds compiler support (quick & optimizing) with new invoke code path that calls method off the thread pointer - Adds thread entrypoints for all string init methods - Adds map to verifier to log when receiver of string init has been copied to other registers. used by compiler and interpreter Change-Id: I797b992a8feb566f9ad73060011ab6f51eb7ce01
* Emit 4 byte UTF-sequences in place of encoded surrogate pairs.Narayan Kamath2015-03-251-6/+47
| | | | | | | | | Symmetric with a5afcfc73141e5e378d79a326d0 which converts 4 byte UTF-8 sequences to surrogate pairs. bug: 18848397 Change-Id: I42adc275b7e0df0cbbd9d8a799e8b0447d8f5cae
* Be more lenient with 4 byte UTF-8 sequences.Narayan Kamath2015-02-121-6/+38
| | | | | | | | | | | | | | | Accept 4 byte sequences and convert them into surrogate pairs instead of expecting 2 separate 3 byte sequences each encoding one half of a surrogate pair. Note that in addition to supporting 4 byte sequences in strings from JNI, we also tolerate them in dex files. This is mainly for consistency, and there's no need to claim any sort of official support. bug: 18848397 bug: https://code.google.com/p/android/issues/detail?id=81341 Change-Id: Ibc98d29e59d98803e640f2489ea4c56912a59b29
* Fix ImageWriter::ComputeEagerResolvedStringsCallback().Vladimir Marko2015-02-111-6/+8
| | | | Change-Id: I1a2abd6d78dd7067d9bdbadbd81dd2fd7711fbc5
* Add hash map, reduce excessive hashingMathieu Chartier2014-11-071-3/+3
| | | | | | | | | | | | | | | | | | | | | | | Changed the class def index to use a HashMap instead of unordered_map so that we can use FindWithHash to reduce how often we need to compute hashes. Fixed a bug in ClassLinker::UpdateClass where we didn't properly handle classes with the same descriptor but different class loaders. Introduced by previous CL. Before (fb launch): 1.74% art::ComputeModifiedUtf8Hash(char const*) After: 0.95% art::ComputeModifiedUtf8Hash(char const*) Bug: 18054905 Bug: 16828525 Change-Id: Iba2ee37c9837289e0ea187800ba4af322225a994 (cherry picked from commit 564ff985184737977aa26c485d0c1a413e530705)
* Avoid signed arithmetic overflow in UTF hash functions.Ian Rogers2014-10-301-6/+6
| | | | Change-Id: I3485ef8445a6034661c1e75dc11ab9ad48884458
* Reduce and speed-up class def searches.Ian Rogers2014-09-021-0/+8
| | | | | | | | | | | | | | | | | | | | Use the class linker for descriptor lookups from the compile driver so that dex caches are populated. Reduce the scope of functions for scanning class paths to just the class linker where they are performed. If we see more than a threshold number of find class def misses on a dex file lazily compute an index, so that future lookups are constant time (part of the collection code is taken from https://android-review.googlesource.com/#/c/103865/3). Note that we take a lazy approach so that we don't serialize on loading dex files, this avoids the reason the index was removed in 8b2c0b9abc3f520495f4387ea040132ba85cae69. Remove an implicit and unnecessary std::string creation for PrintableString. Single threaded interpret-only dex2oat performance is improved by roughly 10%. Bug: 16853450 Change-Id: Icf72df76b0a4328f2a24075e81f4ff267b9401f4
* Object model changes to support 64bit.Ian Rogers2014-02-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | | Modify mirror objects so that references between them use an ObjectReference value type rather than an Object* so that functionality to compress larger references can be captured in the ObjectRefererence implementation. ObjectReferences are 32bit and all other aspects of object layout remain as they are currently. Expand fields in objects holding pointers so they can hold 64bit pointers. Its expected the size of these will come down by improving where we hold compiler meta-data. Stub out x86_64 architecture specific runtime implementation. Modify OutputStream so that reads and writes are of unsigned quantities. Make the use of portable or quick code more explicit. Templatize AtomicInteger to support more than just int32_t as a type. Add missing, and fix issues relating to, missing annotalysis information on the mutator lock. Refactor and share implementations for array copy between System and uses elsewhere in the runtime. Fix numerous 64bit build issues. Change-Id: I1a5694c251a42c9eff71084dfdd4b51fff716822
* Move hot utf routines into -inl.h.Ian Rogers2013-09-231-35/+1
| | | | Change-Id: I7050d8282a7e5870b2bf671d6867c57625e00ccc
* Create separate Android.mk for main build targetsBrian Carlstrom2013-07-121-0/+156
The runtime, compiler, dex2oat, and oatdump now are in seperate trees to prevent dependency creep. They can now be individually built without rebuilding the rest of the art projects. dalvikvm and jdwpspy were already this way. Builds in the art directory should behave as before, building everything including tests. Change-Id: Ic6b1151e5ed0f823c3dd301afd2b13eb2d8feb81