summaryrefslogtreecommitdiffstats
path: root/vm/InlineNative.h
Commit message (Collapse)AuthorAgeFilesLines
* dalvik: dalvik device extension pack.Xin Qi2013-10-311-0/+39
| | | | | | | | | Add support for customer device extension Change-Id: I0402a630ba212d1c5e81cda110f61210f7b60384 (cherry picked from commit 11499df326462bfe25890a35c6abbf019ff7784e) (cherry picked from commit e03b8f8da9cf4eef64cedf39ce9ca90d26ce5124) (cherry picked from commit fb360be406f35b9591f12c61936657f03cc5880f)
* Optimize those StrictMath routines that are identical to Math routines.Elliott Hughes2012-09-141-1/+8
| | | | | | | We can just use the existing Math intinsics. Bug: 7146208 Change-Id: I9e78d33cf65a5dcc5a7c0133e67bd9c3c1e43f23
* Normalize the include guard style.Carl Shapiro2011-06-141-3/+3
| | | | | | | | | | An leading underscore followed by a capital letter is a reserved name space in C and C++. This change also moves any #include directives within the include guard in some of the compiler/codegen/arm header files. Change-Id: I9715e2c5301699d31886e61d0fe6e29483555a2a
* Get rid of uneeded extern, enum, typedef and struct qualifiers.Carl Shapiro2011-04-271-13/+5
| | | | Change-Id: I236c5a1553a51f82c9bc3eaaab042046c854d3b4
* Convert the internal and in-line natives to C++.Carl Shapiro2011-04-121-0/+69
| | | | Change-Id: I2ece682bc3b4d3b55ab27c60fd84a0b3243d7ca6
* Compile the garbage collector and heap profiler as C++.Carl Shapiro2011-04-081-0/+8
| | | | Change-Id: I25d8fa821987a3dd6d7109d07fd42dbf2fe0e589
* Interpreter restructuringbuzbee2011-03-231-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a restructuring of the Dalvik ARM and x86 interpreters: o Combine the old portstd and portdbg interpreters into a single portable interpreter. o Add debug/profiling support to the fast (mterp) interpreters. o Delete old mechansim of switching between interpreters. Now, once you choose an interpreter at startup, you stick with it. o Allow JIT to co-exist with profiling & debugging (necessary for first-class support of debugging with the JIT active). o Adds single-step capability to the fast assembly interpreters without slowing them down (and, in fact, measurably improves their performance). o Remove old "polling for safe point" mechanism. Breakouts now achieved via modifying base of interpreter handler table. o Simplify interpeter control mechanism. o Allow thread-granularity control for profiling & debugging The primary motivation behind this change was to improve the responsiveness of debugging and profiling and to make it easier to add new debugging and profiling capabilities in the future. Instead of always bailing out to the slow debug portable interpreter, we can now stay in the fast interpreter. A nice side effect of the change is that the fast interpreters got a healthy speed boost because we were able to replace the polling safepoint check that involved a dozen or so instructions with a single table-base reload. When combined with the two earlier CLs related to this restructuring, we show a 5.6% performance improvement using libdvm_interp.so on the Checkers benchmark relative to Honeycomb. Change-Id: I8d37e866b3618def4e582fc73f1cf69ffe428f3c
* Ensure we always call inline natives.Elliott Hughes2011-02-161-1/+5
| | | | | | | | | | | | | | Even though execute-inline is now a mandatory optimization, you can't be sure the inline natives will be invoked that way. There's reflection and JNI, for example, and there's the special case of String.equals that might be invoked as Object.equals. This patch adds a regular native method corresponding to each inline native, so that a corresponding libcore patch can drop its implementations. (For example, despite the fact that we all believed last week that the Java implementation of String.equals is never used, that turned out not to be true: every HashMap lookup will have used it. This pair of patches brings reality in line with our existing belief.) Change-Id: I19e64c23bea83e91696206ca40ce4e3faf853040
* Make more DEX optimizations "essential"Andy McFadden2011-01-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This shifts two dexopt optimizations from the "non-essential" category to "essential", which means they will be performed at class load time for classes that did not successfully verify in dexopt. (This has an impact on memory and start time, but measurements have indicated that it's negligible because dexopt usually succeeds.) First, invoke-direct --> invoke-direct-empty. This is part of the work needed for bug 3342343, which needs to do a little extra work when returning from Object.<init> in a finalizable class. Second, invoke-* --> execute-inline. We currently have three copies of methods like String.length(): one in libcore, one in InlineNatives.c, and one in the JIT's code generator. If we guarantee inlining, we can get rid of the copy in libcore. We also ensure that certain libcore tests (which are organized in a way that makes dexopt unhappy) are using the version that will most likely be used on production. Note there is currently no support for "jumbo" opcodes here. Also, made the inline method lookup abort-on-failure. Once upon a time these were "best effort" optimizations, but now they're mandatory. And seriously, if you don't have String.length() and Math.min() you shouldn't be trying to run anyway. dvmInlineNativeCheck() is now redundant and has been removed. Change-Id: I4244e011839f77311fea0570195b3b0df4d84dcf
* Check at startup that we can resolve all the inline natives.Elliott Hughes2010-09-171-0/+4
| | | | | | | | | Also fix a bug where we'd dereference NULL if an inline native's class failed to resolve. Also merge this method lookup with Optimize.c's (superior) near-duplicate. Change-Id: Ic7a95e1f7445b6c9964ddd5e2e1d14d70792a622
* Intrinsics for float/int and double/long conversions.Elliott Hughes2010-08-231-0/+6
| | | | | Bug: 2935622 Change-Id: I0f9e564f1f94ccf6596a37a6f1c10253481d5062
* Fix supplementary character support.Elliott Hughes2010-04-121-13/+12
| | | | | | | | | | Fixes all known bugs in our handling of supplementary characters. This change introduces a performance regression on the assumption that it won't be released without a corresponding JIT change to enable the code to be inlined back to pretty much what it used to be. Bug: 2587122 Change-Id: I3449c9718bbe32ebe53b6c10454ae1dc82105b59
* An InlineNative for String.isEmpty, so it's not slower than length() == 0.Elliott Hughes2010-04-081-10/+11
| | | | | | | | | | | | | | | | | | | | | | Before: benchmark ns logarithmic runtime IsEmpty 115 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX LengthEqualsZero 21 XXXXX|||||||||||||| With C intrinsic: IsEmpty 30 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX LengthEqualsZero 20 XXXXXXXXXXXXXXXXXXXX|||||| With assembler intrinsic: IsEmpty 15 XXXXXXXXXXXXXXXXXXXX|||||| LengthEqualsZero 21 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX (All times on passion.) Change-Id: Ifcc37fe7b8efdd377675a448e0085e490d6767bc
* Update the JIT to use the new indexAt() inline native routines.Bill Buzbee2009-09-031-10/+12
|
* Inline-execute for Java.Lang.Math routines, jit codegen restructure, various ↵Bill Buzbee2009-07-101-0/+18
| | | | bug fixes.
* auto import from //depot/cupcake/@135843The Android Open Source Project2009-03-031-0/+85
|
* auto import from //depot/cupcake/@135843The Android Open Source Project2009-03-031-85/+0
|
* Initial ContributionThe Android Open Source Project2008-10-211-0/+85