Merge "Remove system properties that are now handled in libcore." into dalvik-dev
Fix prelink for libdvm.

Change-Id: If91f46f80c1b1947683720e8187cecb0f7077b94
Bug: 3470019
Fix an off-by-one error.

I can't believe I wrote this, but I can't find an original that would let me
pass this off as a copy & paste of someone else's bug.

Bug: 3471497
Change-Id: I40a33f62a1551147adaf8e3bdf0e796ab1918398
am 6c360b86: Fix prelink for libdvm.

* commit '6c360b86f5774376140636ff60ad4af3814fef21':
  Fix prelink for libdvm.
Retain annotations when merging dex files.

This change has one major limitation: it doesn't deduplicate
equal annotation directories or annotation sets across dex
files. That will result in unnecessarily large dex files.

Change-Id: If63273d16eba1d989c6b5695d102b378d4047119
http://b/3447216
Interpreter restructuring: eliminate InterpState

The key datastructure for the interpreter is InterpState.
This change eliminates it, merging its data with the Thread structure.

Here's why:

In principio creavit Fadden Thread et InterpState.  And it was good.

Thread holds thread-private state, while InterpState captures data
associated with a Dalvik interpreter activation.  Because JNI calls
can result in nested interpreter invocations, we can have more than one
InterpState for each actual thread.  InterpState was relatively small,
and it all worked well.  It was used enough that in the Arm version
a register (rGLUE) was dedicated to it.

Then, along came the JIT guys, who saw InterpState as a convenient place
to dump all sorts of useful data that they wanted quick access to through
that dedicated register.  InterpState grew and grew.  In terms of
space, this wasn't a big problem - but it did mean that the initialization
cost of each interpreter activation grew as well.  For applications
that do a lot of callbacks from native code into Dalvik, this is
measurable.  It's also mostly useless cost because much of the JIT-related
InterpState initialization was setting up useful constants - things that
don't need to be saved and restored all the time.

The biggest problem, though, deals with thread control.  When something
interesting is happening that needs all threads to be stopped (such as
GC and debugger attach), we have access to all of the Thread structures,
but we don't have access to all of the InterpState structures (which
may be buried/nested on the native stack).  As a result, polling for
thread suspension is done via a one-indirection pointer chase.  InterpState
itself can't hold the stop bits because we can't always find it, so
instead it holds a pointer to the global or thread-specific stop control.

Yuck.

With this change, we eliminate InterpState and merge all needed data
into Thread.  Further, we replace the decidated rGLUE register with a
pointer to the Thread structure (rSELF).  The small subset of state
data that needs to be saved and restored across nested interpreter
activations is collected into a record that is saved to the interpreter
frame, and restored on exit.  Further, these small records are linked
together to allow tracebacks to show nested activations.  Old InterpState
variables that simply contain useful constants are initialized once at
thread creation time.

This CL is large enough by itself that the new ability to streamline
suspend checks is not done here - that will happen in a future CL.  Here
we just focus on consolidation.

Change-Id: Ide6b2fb85716fea454ac113f5611263a96687356
Merge "Interpreter restructuring: eliminate InterpState" into dalvik-dev
Merge "Retain annotations when merging dex files." into dalvik-dev
Update to allow x86-atom build for FI on Gingerbread

Also handles most TODO.txt items and contains some rewriting of the dispatch code.
Also adds a newline to the end of files that did not previously end with a newline.

Change-Id: I0cf3e77dc7bbf5ed7ec8538ef4d7d8740e296640
Added flags to dvmCloneObject

Updated the call site to use "don't track".

Change-Id: Ibd4b5a9d93b0043c3906ad86b9ae19d1bf70541d
Fix for 3477749 WITH_TRACKREF_CHECKS

Failed to specify grouping struct on access to debugTrackedRefStart
in recent InterpState/Thread consolidation.  Fixed.

Change-Id: Ib996b96fa1f322e3c433377bea79293eb984fca9
Bump Dalvik version.

Minor increase to differentiate HC MR1 from HC.

Change-Id: I2ccd57d4952c19c2df2fe948ce60c476819450d4
Merge "Added flags to dvmCloneObject" into dalvik-dev
Merge "Open dexdump files in binary mode."
Remove a comment about cloning partially initialized objects.

The compiler and verifier should make this situation impossible.

Change-Id: I0be561108ff7ed221ab98172919c59e80a0365b7
am 636ed3eb: Bump Dalvik version.

* commit '636ed3eba9e28d9630c8d8177b2ae601e7990f0e':
  Bump Dalvik version.
Bump up the Dalvik versions

Increase the human-readable form to differentiate from HC.

Increase the build number because we need to re-DEX stuff after
some recent changes (e.g. we've increased the number of methods
that need to use return-void-barrier).

Change-Id: I8f2c94694f7a11e86de882963ba509711f668f47
Optimize Class.getMethod() by loading only one method.

Change-Id: Ia2cd776c0a14914264e8d94e978d55854ed75623
http://b/3431686
Merge "Optimize Class.getMethod() by loading only one method."
Factor out class names from throw statements.

Most exception throwing now happens via purpose-built wrapper
functions, each of which encapsulates the actual exception class name,
reducing one source of error (examples of which I fixed during this
exercise) and generally tidying things up.

This change doesn't fix all uses of exception class names, nor even
all throws, because (a) there were classes I didn't get to; (b)
because I didn't make wrappers for all the possible throw function
variants (e.g. the one that takes a cause, the one that takes varargs
for string formatting, etc.); and (c) there are uses of exception
classes in contexts other than throwing. But this change at least makes
a dent in the problem.

Change-Id: I6586ddd3e66ac0fc32c23181b17600ded0b914b2