OSDN Git Service

android-x86/dalvik.git
13 years agoam ad3ff025: Merge "Update Call386ABI.S to support 16 byte alignment"
Jean-Baptiste Queru [Mon, 11 Oct 2010 01:49:37 +0000 (18:49 -0700)]
am ad3ff025: Merge "Update Call386ABI.S to support 16 byte alignment"

Merge commit 'ad3ff0252ee5c59528828e0625490f0768d2081f' into gingerbread-plus-aosp

* commit 'ad3ff0252ee5c59528828e0625490f0768d2081f':
  Update Call386ABI.S to support 16 byte alignment

13 years agoam bc02ca96: Merge "Fixed bug in OP_GOTO_32.S, added support for additional parameter...
Jean-Baptiste Queru [Mon, 11 Oct 2010 01:49:31 +0000 (18:49 -0700)]
am bc02ca96: Merge "Fixed bug in OP_GOTO_32.S, added support for additional parameters to dvmHandleStackOverflow"

Merge commit 'bc02ca96c5cd3b45939809ed43ae2e7f2e4fb5b9' into gingerbread-plus-aosp

* commit 'bc02ca96c5cd3b45939809ed43ae2e7f2e4fb5b9':
  Fixed bug in OP_GOTO_32.S, added support for additional parameters to dvmHandleStackOverflow

13 years agoMerge "Update Call386ABI.S to support 16 byte alignment"
Jean-Baptiste Queru [Mon, 11 Oct 2010 01:35:44 +0000 (18:35 -0700)]
Merge "Update Call386ABI.S to support 16 byte alignment"

13 years agoMerge "Fixed bug in OP_GOTO_32.S, added support for additional parameters to dvmHandl...
Jean-Baptiste Queru [Mon, 11 Oct 2010 01:34:16 +0000 (18:34 -0700)]
Merge "Fixed bug in OP_GOTO_32.S, added support for additional parameters to dvmHandleStackOverflow"

13 years agoam 5276cccb: Verify method invocation type.
Andy McFadden [Sun, 10 Oct 2010 21:12:00 +0000 (14:12 -0700)]
am 5276cccb: Verify method invocation type.

Merge commit '5276cccb15b6ce0133c8107ff9ff013b4a176ef7' into gingerbread-plus-aosp

* commit '5276cccb15b6ce0133c8107ff9ff013b4a176ef7':
  Verify method invocation type.

13 years agoVerify method invocation type.
Andy McFadden [Sun, 10 Oct 2010 19:59:11 +0000 (12:59 -0700)]
Verify method invocation type.

Dalvik provides five different ways to invoke a method (virtual, super,
direct, static, interface).  Using a virtual invoke instruction to call
a direct method will not produce the desired results.

This adds a test to the verifier that ensures the method targeted by
an invocation instruction is of an appropriate kind.

Bug 3082885.

(cherry-pick from dalvik-dev)

Change-Id: I3237cbefc7314f0b9d7557fc0bfd2b548ea30938

13 years agoam 9be25d09: Clarify the invoke-* opcodes.
Dan Bornstein [Sun, 10 Oct 2010 20:20:02 +0000 (13:20 -0700)]
am 9be25d09: Clarify the invoke-* opcodes.

Merge commit '9be25d09d24b3d6d0dd1a41c1c09471af4827687' into gingerbread-plus-aosp

* commit '9be25d09d24b3d6d0dd1a41c1c09471af4827687':
  Clarify the invoke-* opcodes.

13 years agoClarify the invoke-* opcodes.
Dan Bornstein [Sun, 10 Oct 2010 19:29:07 +0000 (12:29 -0700)]
Clarify the invoke-* opcodes.

In particular, make it a little more explicit what kinds of methods
are acceptable for each variant.

Change-Id: Icd9dad876c2d10c23462b4d85ccaa9441d7f2c04

13 years agoam 7d3f633d: Merge "Include static fields when dumping class objects." into gingerbread
Carl Shapiro [Fri, 1 Oct 2010 19:57:44 +0000 (12:57 -0700)]
am 7d3f633d: Merge "Include static fields when dumping class objects." into gingerbread

Merge commit '7d3f633d2c0061e579c57186276c05ddcc275641' into gingerbread-plus-aosp

* commit '7d3f633d2c0061e579c57186276c05ddcc275641':
  Include static fields when dumping class objects.

13 years agoMerge "Include static fields when dumping class objects." into gingerbread
Carl Shapiro [Fri, 1 Oct 2010 19:54:52 +0000 (12:54 -0700)]
Merge "Include static fields when dumping class objects." into gingerbread

13 years agoInclude static fields when dumping class objects.
Carl Shapiro [Fri, 1 Oct 2010 00:20:11 +0000 (17:20 -0700)]
Include static fields when dumping class objects.

Change-Id: I8e7b1d1ef7ca205b489744dcbf0f210c1f2443c4

13 years agoam 307aa79a: Merge "Change Runtime.nativeLoad to return the dlerror(3) string." into...
Elliott Hughes [Fri, 1 Oct 2010 17:49:02 +0000 (10:49 -0700)]
am 307aa79a: Merge "Change Runtime.nativeLoad to return the dlerror(3) string." into gingerbread

Merge commit '307aa79afc08c50e9ea69aac7bf5128bc75ac7ff' into gingerbread-plus-aosp

* commit '307aa79afc08c50e9ea69aac7bf5128bc75ac7ff':
  Change Runtime.nativeLoad to return the dlerror(3) string.

13 years agoMerge "Change Runtime.nativeLoad to return the dlerror(3) string." into gingerbread
Elliott Hughes [Fri, 1 Oct 2010 17:35:13 +0000 (10:35 -0700)]
Merge "Change Runtime.nativeLoad to return the dlerror(3) string." into gingerbread

13 years agoam b78c76f8: GC Card marking fix for SPUT_OBJECT - use correct object head
buzbee [Fri, 1 Oct 2010 03:24:45 +0000 (20:24 -0700)]
am b78c76f8: GC Card marking fix for SPUT_OBJECT - use correct object head

Merge commit 'b78c76f88ea42e7a3b295c210ca9ee86e7290043' into gingerbread-plus-aosp

* commit 'b78c76f88ea42e7a3b295c210ca9ee86e7290043':
  GC Card marking fix for SPUT_OBJECT - use correct object head

13 years agoGC Card marking fix for SPUT_OBJECT - use correct object head
buzbee [Fri, 1 Oct 2010 02:08:20 +0000 (19:08 -0700)]
GC Card marking fix for SPUT_OBJECT - use correct object head

Change-Id: I8b84a4f1e1690f5b62de7404ea6ede00317848bb

13 years agoChange Runtime.nativeLoad to return the dlerror(3) string.
Elliott Hughes [Thu, 30 Sep 2010 22:51:31 +0000 (15:51 -0700)]
Change Runtime.nativeLoad to return the dlerror(3) string.

This has a companion change in libcore:
  https://android-git.corp.google.com/g/71342

Bug: 3044042
Change-Id: I070a80a41ec2f306f5092a641807017f70179451

13 years agoam d8b5f50d: Correct dexopt for uniprocessors.
Andy McFadden [Thu, 30 Sep 2010 22:40:43 +0000 (15:40 -0700)]
am d8b5f50d: Correct dexopt for uniprocessors.

Merge commit 'd8b5f50d0c6c9a0ce157e89df4ee1e8eb8b334c3' into gingerbread-plus-aosp

* commit 'd8b5f50d0c6c9a0ce157e89df4ee1e8eb8b334c3':
  Correct dexopt for uniprocessors.

13 years agoCorrect dexopt for uniprocessors.
Andy McFadden [Thu, 30 Sep 2010 21:02:54 +0000 (14:02 -0700)]
Correct dexopt for uniprocessors.

The SMP flag was defaulting to "true" for dexopt, even on uniprocessors.
With this change the VM now has three choices: dexopt for SMP, dexopt
for uniprocessor, or dexopt for current system.  The last is used for
just-in-time dexopt (used by -eng and -userdebug builds on bootstrap DEX
files) and installd dexopt (used for apps on all builds).

The dexopt used by the build system during -user builds will either be
explicitly SMP or explicitly uniprocessor, since "current system" has
no meaning when you're cross-dexopting.

Also, unified the dexopt control flags into a single enum.

(cherry-pick from dalvik-dev)

Change-Id: Id1d9c548ca8567585a28ef9ee911cc2ac6b116dd

13 years agoam f45b6cbe: Be explicit about both uniprocessor and SMP when calling dexopt.
Dan Bornstein [Thu, 30 Sep 2010 22:11:27 +0000 (15:11 -0700)]
am f45b6cbe: Be explicit about both uniprocessor and SMP when calling dexopt.

Merge commit 'f45b6cbed6ce7cb6a38746b5abe0213263106a71' into gingerbread-plus-aosp

* commit 'f45b6cbed6ce7cb6a38746b5abe0213263106a71':
  Be explicit about both uniprocessor and SMP when calling dexopt.

13 years agoBe explicit about both uniprocessor and SMP when calling dexopt.
Dan Bornstein [Thu, 30 Sep 2010 22:04:34 +0000 (15:04 -0700)]
Be explicit about both uniprocessor and SMP when calling dexopt.

Change-Id: Ic1b68dddf6822773041de6023c594a062e141325

13 years agoam 1e053438: Merge "After trimming, set the footprint to the number of pages in use...
Carl Shapiro [Wed, 29 Sep 2010 21:30:25 +0000 (14:30 -0700)]
am 1e053438: Merge "After trimming, set the footprint to the number of pages in use." into gingerbread

Merge commit '1e053438810dbd8406ec8339b94801195261e849' into gingerbread-plus-aosp

* commit '1e053438810dbd8406ec8339b94801195261e849':
  After trimming, set the footprint to the number of pages in use.

13 years agoMerge "After trimming, set the footprint to the number of pages in use." into gingerbread
Carl Shapiro [Wed, 29 Sep 2010 21:27:50 +0000 (14:27 -0700)]
Merge "After trimming, set the footprint to the number of pages in use." into gingerbread

13 years agoam d4cdb357: Merge "Update the card table scanning for header-only card marks." into...
Carl Shapiro [Wed, 29 Sep 2010 19:40:05 +0000 (12:40 -0700)]
am d4cdb357: Merge "Update the card table scanning for header-only card marks." into gingerbread

Merge commit 'd4cdb3572b489e770d20a6afba0f86563f380825' into gingerbread-plus-aosp

* commit 'd4cdb3572b489e770d20a6afba0f86563f380825':
  Update the card table scanning for header-only card marks.

13 years agoMerge "Update the card table scanning for header-only card marks." into gingerbread
Carl Shapiro [Wed, 29 Sep 2010 19:38:19 +0000 (12:38 -0700)]
Merge "Update the card table scanning for header-only card marks." into gingerbread

13 years agoam 87f66617: Add --uniprocessor option to dex-preopt.
Dan Bornstein [Wed, 29 Sep 2010 17:04:22 +0000 (10:04 -0700)]
am 87f66617: Add --uniprocessor option to dex-preopt.

Merge commit '87f666172f55863d6a50762a1a07a31b67eb48f6' into gingerbread-plus-aosp

* commit '87f666172f55863d6a50762a1a07a31b67eb48f6':
  Add --uniprocessor option to dex-preopt.

13 years agoUpdate the card table scanning for header-only card marks.
Carl Shapiro [Wed, 29 Sep 2010 08:09:11 +0000 (01:09 -0700)]
Update the card table scanning for header-only card marks.

Previously, the card table accessors assumed that objects had either
their header marked or would be marked exactly.  As such, after
reckoning a marked card the scan would back up until it found an
object header and then move forward blackening each object within the
address range of the marked card.

Following a recent change we exclusively mark headers.  The scan only
has to move forward until the end of a card.  This saves scanning time
as dlmalloc's binning may leave large segments of the heap unused.  It
is not uncommon for hundreds of cards to be spanned when backing up to
the first live object below a marked card.

In addition, this change fixes the card table verifier to search the
mark stack for gray objects.  It is permissible for roots to point to
white objects on unmarked cards.  This was incorrectly treated as an
error.

Change-Id: Ia6b6ee2012e381d644b8b3f38b39d746749ea47a

13 years agoAfter trimming, set the footprint to the number of pages in use.
Carl Shapiro [Wed, 29 Sep 2010 03:30:42 +0000 (20:30 -0700)]
After trimming, set the footprint to the number of pages in use.

A trim can decrease the an mspace footprint but it will not decrease
its max footprint.  We need to decrease the max footprint to make any
pages recovered by a trim available to external allocations.

By setting the ideal footprint after a trim we lift any soft limit in
effect and make the mspace footprint and max footprints equal.

Change-Id: Ia6eb99634ce1d732b417a90291b110d1fc46c2e3

13 years agoAdd --uniprocessor option to dex-preopt.
Dan Bornstein [Wed, 29 Sep 2010 01:53:28 +0000 (18:53 -0700)]
Add --uniprocessor option to dex-preopt.

This tells the preoptimizer to target a uniprocessor (unsurprisingly).
By default, it targets SMP, which makes it do more changes than it has
to for a uniprocessor (e.g. editing how non-wide volatile fields are
accessed within bytecode). To be clear, when SMP-optimized code is run
on a uniprocessor, it should still work. We're just aiming to only
make truly necessary changes during optimization.

While I was in the territory, I went ahead and cleaned up some single
vs. double quote hygiene in the file.

Change-Id: Ia45992939a436d0be6db8363c43d430de4acb80b

13 years agoam 148283d7: Plumb SMP optimization control through to dexopt.
Dan Bornstein [Wed, 29 Sep 2010 01:37:39 +0000 (18:37 -0700)]
am 148283d7: Plumb SMP optimization control through to dexopt.

Merge commit '148283d71a7e35b9b506cbb49294b6822719c25e' into gingerbread-plus-aosp

* commit '148283d71a7e35b9b506cbb49294b6822719c25e':
  Plumb SMP optimization control through to dexopt.

13 years agoPlumb SMP optimization control through to dexopt.
Dan Bornstein [Tue, 28 Sep 2010 22:46:54 +0000 (15:46 -0700)]
Plumb SMP optimization control through to dexopt.

Change-Id: I3bfaf6723e7b14d001f9de60cc1c1fd4f8e1ed99

13 years agoam de9cdfa9: Fix verification of switch offsets in large methods.
Andy McFadden [Tue, 28 Sep 2010 22:15:04 +0000 (15:15 -0700)]
am de9cdfa9: Fix verification of switch offsets in large methods.

Merge commit 'de9cdfa9d6d5fa5c46a0ec0f3f1e8de08a688841' into gingerbread-plus-aosp

* commit 'de9cdfa9d6d5fa5c46a0ec0f3f1e8de08a688841':
  Fix verification of switch offsets in large methods.

13 years agoFixed bug in OP_GOTO_32.S, added support for additional parameters to dvmHandleStackO...
Johnnie Birch [Tue, 28 Sep 2010 21:58:37 +0000 (14:58 -0700)]
Fixed bug in OP_GOTO_32.S, added support for additional parameters to dvmHandleStackOverflow

Change-Id: I4d8d75418395661ffc8e7055eeb4600bb5b8b0bc

13 years agoFix verification of switch offsets in large methods.
Andy McFadden [Tue, 28 Sep 2010 21:43:28 +0000 (14:43 -0700)]
Fix verification of switch offsets in large methods.

The verifier was only using the low 16 bits when checking the offset
to a switch table.  This was failing on really large methods.

We also blew up the arbitrary size cap again, so I made it a warning
rather than a failure (it really wasn't doing anybody any good).

Changed to width-specific types for the various offsets and sizes.

Bug 3044850.

(cherry-pick+squash from dalvik-dev)

Change-Id: Ic7ebb86728cb39151f617a3e69e1c1994e61b5d9

13 years agoUpdate Call386ABI.S to support 16 byte alignment
Johnnie Birch [Tue, 28 Sep 2010 21:39:15 +0000 (14:39 -0700)]
Update Call386ABI.S to support 16 byte alignment

Change-Id: I61125ffab37f728665a91907bb699a0568568418

13 years agoam b36ea791: Merge "Change GC card making to use object head, bug fix for volatile...
buzbee [Tue, 28 Sep 2010 19:28:21 +0000 (12:28 -0700)]
am b36ea791: Merge "Change GC card making to use object head, bug fix for volatile sput obj" into gingerbread

Merge commit 'b36ea7918612c81cb42ff2021443358a9f109a6d' into gingerbread-plus-aosp

* commit 'b36ea7918612c81cb42ff2021443358a9f109a6d':
  Change GC card making to use object head, bug fix for volatile sput obj

13 years agoMerge "Change GC card making to use object head, bug fix for volatile sput obj" into...
buzbee [Tue, 28 Sep 2010 19:26:06 +0000 (12:26 -0700)]
Merge "Change GC card making to use object head, bug fix for volatile sput obj" into gingerbread

13 years agoam b755f9a3: Do not grow if we are invoked for an external allocation.
Carl Shapiro [Tue, 28 Sep 2010 18:35:26 +0000 (11:35 -0700)]
am b755f9a3: Do not grow if we are invoked for an external allocation.

Merge commit 'b755f9a3caeaf65e95480ac66c2c95553bf79389' into gingerbread-plus-aosp

* commit 'b755f9a3caeaf65e95480ac66c2c95553bf79389':
  Do not grow if we are invoked for an external allocation.

13 years agoChange GC card making to use object head, bug fix for volatile sput obj
buzbee [Mon, 27 Sep 2010 18:30:22 +0000 (11:30 -0700)]
Change GC card making to use object head, bug fix for volatile sput obj

This CL changes the way we mark GC card to consistently use the object
head (previously, we marked somewhere in the object - often the head, but
not always).  Also, previously a coding error caused us to skip the card
mark for OP_APUT_OBJECT_VOLATILES.  Fixed here.

Change-Id: I133ef6395c51a0466c9708209b08e79c3083aff2

13 years agoDo not grow if we are invoked for an external allocation.
Carl Shapiro [Tue, 28 Sep 2010 00:25:49 +0000 (17:25 -0700)]
Do not grow if we are invoked for an external allocation.

The garbage collection can elect to grow the size of an mspace if the
heap utilization is sufficiently large.  This can remove pages from use
by the external allocation mechanism.

Change-Id: Ie2e9e3da9251068707a60a5835b50e485031578b

13 years agoam e8edf08f: Perform only one garbage collection before attempting a trim.
Carl Shapiro [Tue, 28 Sep 2010 02:47:16 +0000 (19:47 -0700)]
am e8edf08f: Perform only one garbage collection before attempting a trim.

Merge commit 'e8edf08f04ecbe37f3e18a650a7c9002ceee4275' into gingerbread-plus-aosp

* commit 'e8edf08f04ecbe37f3e18a650a7c9002ceee4275':
  Perform only one garbage collection before attempting a trim.

13 years agoPerform only one garbage collection before attempting a trim.
Carl Shapiro [Mon, 27 Sep 2010 23:55:21 +0000 (16:55 -0700)]
Perform only one garbage collection before attempting a trim.

Change-Id: Id7ea77fd8e6055a76a5f52bb96dd0544f88ce06b

13 years agoam 812c1bed: Provide the required out parameter to the trim routine.
Carl Shapiro [Mon, 27 Sep 2010 21:29:18 +0000 (14:29 -0700)]
am 812c1bed: Provide the required out parameter to the trim routine.

Merge commit '812c1bed55e0ed9b092d320cb29d8adc17e5a10b' into gingerbread-plus-aosp

* commit '812c1bed55e0ed9b092d320cb29d8adc17e5a10b':
  Provide the required out parameter to the trim routine.

13 years agoProvide the required out parameter to the trim routine.
Carl Shapiro [Mon, 27 Sep 2010 21:10:10 +0000 (14:10 -0700)]
Provide the required out parameter to the trim routine.

Resolves http://b/issue?id=3040192.

Change-Id: I886a2dc99956b06e953f03ac390865b118b634a3

13 years agoam 85dc40d2: Take another tilt at the "--core-library" messaging windmill.
Dan Bornstein [Sun, 26 Sep 2010 23:02:23 +0000 (16:02 -0700)]
am 85dc40d2: Take another tilt at the "--core-library" messaging windmill.

Merge commit '85dc40d2a0cb19792bf3ee6f6c57fed08eb91ea4' into gingerbread-plus-aosp

* commit '85dc40d2a0cb19792bf3ee6f6c57fed08eb91ea4':
  Take another tilt at the "--core-library" messaging windmill.

13 years agoTake another tilt at the "--core-library" messaging windmill.
Dan Bornstein [Sun, 26 Sep 2010 22:03:28 +0000 (15:03 -0700)]
Take another tilt at the "--core-library" messaging windmill.

This time, I added a note about what appears to be the most common
inadvertent triggering, and I point people at JarJar as a possible
solution when the core class inclusion was intentional.

Change-Id: I2d576df0b8944882838cbb6e2b050d59434a238b

13 years agoam 60cc993e: Support -Xbootclasspath/a and /p for dvmProcessOptions in dalvik/vm...
Norris, Lee [Sun, 26 Sep 2010 16:09:47 +0000 (09:09 -0700)]
am 60cc993e: Support -Xbootclasspath/a and /p for dvmProcessOptions in dalvik/vm/Init.c

Merge commit '60cc993e5afb3327482b172cc7e54c469b231741' into gingerbread-plus-aosp

* commit '60cc993e5afb3327482b172cc7e54c469b231741':
  Support -Xbootclasspath/a and /p for dvmProcessOptions in dalvik/vm/Init.c

13 years agoam 35b0f486: Merge "Wait for the GC to quiesce before attempting foreground GCs....
Carl Shapiro [Sat, 25 Sep 2010 00:49:51 +0000 (17:49 -0700)]
am 35b0f486: Merge "Wait for the GC to quiesce before attempting foreground GCs." into gingerbread

Merge commit '35b0f486feb23a5c199c02ab45bfa613503e2b8f' into gingerbread-plus-aosp

* commit '35b0f486feb23a5c199c02ab45bfa613503e2b8f':
  Wait for the GC to quiesce before attempting foreground GCs.

13 years agoMerge "Wait for the GC to quiesce before attempting foreground GCs." into gingerbread
Carl Shapiro [Sat, 25 Sep 2010 00:47:37 +0000 (17:47 -0700)]
Merge "Wait for the GC to quiesce before attempting foreground GCs." into gingerbread

13 years agoWait for the GC to quiesce before attempting foreground GCs.
Carl Shapiro [Sat, 25 Sep 2010 00:36:53 +0000 (17:36 -0700)]
Wait for the GC to quiesce before attempting foreground GCs.

Previously, dvmTrackExternalAllocation waited for the GC to complete
before retrying its allocation.  However, there is no guarantee that
the GC will not be active at the time we are woken.  Furthermore, the
code did not revalidate that the external allocation is still
possible, an assumption made by all externalAlloc calls.

With this change, the code loops until the GC is no longer active,
validates that the allocation is still possible, and then proceeds
with its routine for allocating additional storage.  In addition, if
we try a few heroic measures to establish the externalAllocPossible
invariant rather than immediately failing the call.

Change-Id: I2e3b8a6c9fab617990edc085f52d0df35ad6d0f6

13 years agoam ddd9d0b3: Show errors from getSchedulerGroup().
Andy McFadden [Fri, 24 Sep 2010 22:54:54 +0000 (15:54 -0700)]
am ddd9d0b3: Show errors from getSchedulerGroup().

Merge commit 'ddd9d0b3527072f83db00105e28fa88c47bd763b' into gingerbread-plus-aosp

* commit 'ddd9d0b3527072f83db00105e28fa88c47bd763b':
  Show errors from getSchedulerGroup().

13 years agoShow errors from getSchedulerGroup().
Andy McFadden [Fri, 24 Sep 2010 21:18:03 +0000 (14:18 -0700)]
Show errors from getSchedulerGroup().

If we failed to get the cgroup info, we were showing "unknown" in the
stack trace, and sometimes showing an error message in the log file.
Now we put a very brief error description into the cgroup text field,
so it shows up in the stack trace itself.

Also, replaced three strsep() calls with two strchr() calls.

Also, check return value from pthread_kill() calls.

Bug 3032532.

Change-Id: I3730cfb8a5c59048d35d746d8bffb4fa61bd5a6c

13 years agoam b14f405c: Turn off verbose chatter about libs in /vendor
Dima Zavin [Fri, 24 Sep 2010 06:34:41 +0000 (23:34 -0700)]
am b14f405c: Turn off verbose chatter about libs in /vendor

Merge commit 'b14f405c4492f770c14c9252e81ff4df4401c0ef' into gingerbread-plus-aosp

* commit 'b14f405c4492f770c14c9252e81ff4df4401c0ef':
  Turn off verbose chatter about libs in /vendor

13 years agoTurn off verbose chatter about libs in /vendor
Dima Zavin [Fri, 24 Sep 2010 05:38:45 +0000 (22:38 -0700)]
Turn off verbose chatter about libs in /vendor

Change-Id: I243d538d342b5e0424321b09b2b17555ef6343dd
Signed-off-by: Dima Zavin <dima@android.com>
13 years agoam 629e6923: Print the JIT codegen type in the VM configuration list.
Ben Cheng [Fri, 24 Sep 2010 03:16:50 +0000 (20:16 -0700)]
am 629e6923: Print the JIT codegen type in the VM configuration list.

Merge commit '629e692379a8b12641a4402ff1c9f67af879f68e' into gingerbread-plus-aosp

* commit '629e692379a8b12641a4402ff1c9f67af879f68e':
  Print the JIT codegen type in the VM configuration list.

13 years agoPrint the JIT codegen type in the VM configuration list.
Ben Cheng [Thu, 23 Sep 2010 08:23:14 +0000 (01:23 -0700)]
Print the JIT codegen type in the VM configuration list.

Example:
Configured with: debugger profiler hprof jit(armv7-a-neon) show_exception=1

So that the CPU capability on JIT-enabled devices can be exposed.

(cherry-picked from dalvik-dev)

Change-Id: I887201e7023ca94cd9c3d690f03b7b042175e6ed

13 years agoam 4934b377: Several fixes for JIT and self-verification under corner cases.
Ben Cheng [Thu, 23 Sep 2010 06:21:00 +0000 (23:21 -0700)]
am 4934b377: Several fixes for JIT and self-verification under corner cases.

Merge commit '4934b377d9cf5df6f80da7caab4f2178c6cec307' into gingerbread-plus-aosp

* commit '4934b377d9cf5df6f80da7caab4f2178c6cec307':
  Several fixes for JIT and self-verification under corner cases.

13 years agoSeveral fixes for JIT and self-verification under corner cases.
Ben Cheng [Tue, 21 Sep 2010 05:20:31 +0000 (22:20 -0700)]
Several fixes for JIT and self-verification under corner cases.

1) Fix the self-verification mode to handle backward chaining cell
properly when a single-step instruction is in the middle of the cyclic
portion of the trace. Then found issue 2 when changing the JIT
threshold to 1.
2) When the code cache is full, the VM may stop making forward progress
and bounces back and forth between the debug and fast intepreters as the
translation request is constantly rejected. The fix is to stay in the
debug interpreter until the corner case condition is cleared. Then found
issue 3.
3) Under self-verification mode, the code cache reset request may get
delayed indefinitely due to spurious indication that a thread is
running JIT'ed code. Trivial fix - make sure the inJitCodeCache flag is
cleared.

(cherry-picked from dalvik-dev)

Change-Id: Ic0b9952c0ae545f68f7eb2ae06a82a634ab62e9e

13 years agoam 95a884f7: Fix computation of primitive array widths.
Andy McFadden [Wed, 22 Sep 2010 21:29:30 +0000 (14:29 -0700)]
am 95a884f7: Fix computation of primitive array widths.

Merge commit '95a884f7844a6e7bdd820489742254f3fd002f6d' into gingerbread-plus-aosp

* commit '95a884f7844a6e7bdd820489742254f3fd002f6d':
  Fix computation of primitive array widths.

13 years agoFix computation of primitive array widths.
Andy McFadden [Wed, 22 Sep 2010 19:13:29 +0000 (12:13 -0700)]
Fix computation of primitive array widths.

The code was comparing class pointers, but the class objects for arrays
of primitives are initialized on demand.  If the class wasn't yet
instantiated, the array width code was returning a default value of 4.
This meant the "write values to an array of longs through the unsafe
methods" code was actually scribbling on the wrong part of the array,
which went unnoticed until recently.  (The new-ish ldrexd/strexd code
requires 64-bit alignment.)

We now use the existing array element width computation function.  The
code needed a bit of rearranging since it expected an instance of the
class rather than the class.

Bug 3023981.

(cherry-pick from dalvik-dev)

Change-Id: Ife3258eb6798f8e7eaee7c7b6793a16137de389b

13 years agoam 69259715: Merge "Fix a minor formatting discrepancy in the GC log message." into...
Carl Shapiro [Tue, 21 Sep 2010 20:36:47 +0000 (13:36 -0700)]
am 69259715: Merge "Fix a minor formatting discrepancy in the GC log message." into gingerbread

Merge commit '692597158c3e17fbafe80ec21895754017d4e9f1' into gingerbread-plus-aosp

* commit '692597158c3e17fbafe80ec21895754017d4e9f1':
  Fix a minor formatting discrepancy in the GC log message.

13 years agoMerge "Fix a minor formatting discrepancy in the GC log message." into gingerbread
Carl Shapiro [Tue, 21 Sep 2010 20:34:42 +0000 (13:34 -0700)]
Merge "Fix a minor formatting discrepancy in the GC log message." into gingerbread

13 years agoFix a minor formatting discrepancy in the GC log message.
Carl Shapiro [Tue, 21 Sep 2010 20:28:21 +0000 (13:28 -0700)]
Fix a minor formatting discrepancy in the GC log message.

Change-Id: Ia0233c78f11d5270eefd2b28c6ea239b7ff0de50

13 years agoam 7099d194: Insert "/./" into the input file path when necessary.
Dan Bornstein [Mon, 20 Sep 2010 23:27:39 +0000 (16:27 -0700)]
am 7099d194: Insert "/./" into the input file path when necessary.

Merge commit '7099d194aeb7d0524108aa3d4ed8a8da0595c007' into gingerbread-plus-aosp

* commit '7099d194aeb7d0524108aa3d4ed8a8da0595c007':
  Insert "/./" into the input file path when necessary.

13 years agoInsert "/./" into the input file path when necessary.
Dan Bornstein [Mon, 20 Sep 2010 23:13:54 +0000 (16:13 -0700)]
Insert "/./" into the input file path when necessary.

This is necessary, in particular, when the input file is on the
boot classpath.

Change-Id: I18822d7b2eceba0eb15d5548a87bff5bb641788f

13 years agoam 43c54c0b: Ensure that an explicit GC request initiates a GC.
Carl Shapiro [Mon, 20 Sep 2010 19:10:33 +0000 (12:10 -0700)]
am 43c54c0b: Ensure that an explicit GC request initiates a GC.

Merge commit '43c54c0b3a5161dedfee9c255e60788627ed8505' into gingerbread-plus-aosp

* commit '43c54c0b3a5161dedfee9c255e60788627ed8505':
  Ensure that an explicit GC request initiates a GC.

13 years agoam 18131c2e: Merge "Add more context to the garbage collection log messages." into...
Carl Shapiro [Sat, 18 Sep 2010 02:29:15 +0000 (19:29 -0700)]
am 18131c2e: Merge "Add more context to the garbage collection log messages." into gingerbread

Merge commit '18131c2e1426ba836b5a508842cd370d95d0a964' into gingerbread-plus-aosp

* commit '18131c2e1426ba836b5a508842cd370d95d0a964':
  Add more context to the garbage collection log messages.

13 years agoEnsure that an explicit GC request initiates a GC.
Carl Shapiro [Sat, 18 Sep 2010 00:10:48 +0000 (17:10 -0700)]
Ensure that an explicit GC request initiates a GC.

Previously, if a concurrent GC was in-flight when an explicit GC was
requested a warning would be logged about a recursive GC attempt.  Now,
the requesting thread will block until the GC is inactive and afterward
initiate its foreground collection.

Change-Id: Ibc4cef83315ffe7ccf822a32beb4cce5b1c816bd

13 years agoMerge "Add more context to the garbage collection log messages." into gingerbread
Carl Shapiro [Fri, 17 Sep 2010 23:05:35 +0000 (16:05 -0700)]
Merge "Add more context to the garbage collection log messages." into gingerbread

13 years agoAdd more context to the garbage collection log messages.
Carl Shapiro [Fri, 17 Sep 2010 22:53:16 +0000 (15:53 -0700)]
Add more context to the garbage collection log messages.

With this change, the heap size, number of bytes allocated, the
percentage of free heap, the external allocation limit, and the number
of external bytes allocated are logged.  The number of objects freed
and suspend times are no longer logged but are still included in the
event log records.

Change-Id: I5d5a9d623ae8cb72ad7d4bc5014e218c61a33561

13 years agoam 49f62de0: Add --dexopt option to explicitly specify the dexopt binary.
Dan Bornstein [Fri, 17 Sep 2010 21:22:06 +0000 (14:22 -0700)]
am 49f62de0: Add --dexopt option to explicitly specify the dexopt binary.

Merge commit '49f62de02d20143f73d7afbb4c5e36a6b7082c3a' into gingerbread-plus-aosp

* commit '49f62de02d20143f73d7afbb4c5e36a6b7082c3a':
  Add --dexopt option to explicitly specify the dexopt binary.

13 years agoAdd --dexopt option to explicitly specify the dexopt binary.
Dan Bornstein [Fri, 17 Sep 2010 21:11:19 +0000 (14:11 -0700)]
Add --dexopt option to explicitly specify the dexopt binary.

Also, cleaned up the docs and usage message a little.

Change-Id: I5bb0ce1b4f8153c19da69fca05cd9318c7e02536

13 years agoam 2b9e8c1d: Modify dex-preopt to take better arguments for the build process.
Dan Bornstein [Fri, 17 Sep 2010 20:53:33 +0000 (13:53 -0700)]
am 2b9e8c1d: Modify dex-preopt to take better arguments for the build process.

Merge commit '2b9e8c1db0e886a57a13f778c01469713a8f5985' into gingerbread-plus-aosp

* commit '2b9e8c1db0e886a57a13f778c01469713a8f5985':
  Modify dex-preopt to take better arguments for the build process.

13 years agoModify dex-preopt to take better arguments for the build process.
Dan Bornstein [Fri, 17 Sep 2010 19:54:07 +0000 (12:54 -0700)]
Modify dex-preopt to take better arguments for the build process.

In particular, it now takes a --product-dir that doesn't assume any
particular build tree structure, and it takes a --boot-dir for the
target path (which will be under the product-dir) for the boot
classpath files.

Change-Id: I8986f1d4d37330ab32ebe8b55d38bdd5e24d4aaf

13 years agoSupport -Xbootclasspath/a and /p for dvmProcessOptions in dalvik/vm/Init.c
Norris, Lee [Thu, 16 Sep 2010 06:06:26 +0000 (14:06 +0800)]
Support -Xbootclasspath/a and /p for dvmProcessOptions in dalvik/vm/Init.c

Change-Id: I5549031ae6d6414797a22421e6bf62d1be08ac9a

13 years agoam 42929e15: Add optional tags to dalvik.
Jesse Wilson [Fri, 17 Sep 2010 00:37:21 +0000 (17:37 -0700)]
am 42929e15: Add optional tags to dalvik.

Merge commit '42929e15765640324d9181ec1159effd22aa86ca' into gingerbread-plus-aosp

* commit '42929e15765640324d9181ec1159effd22aa86ca':
  Add optional tags to dalvik.

13 years agoAdd optional tags to dalvik.
Jesse Wilson [Thu, 16 Sep 2010 22:56:25 +0000 (15:56 -0700)]
Add optional tags to dalvik.

Change-Id: I29a78ccb6312d12b3ef0ed02cfbc638a5b01db9c

13 years agoam 4c5d26bc: Make the app processing variant of dex-preopt more consistent.
Dan Bornstein [Wed, 15 Sep 2010 21:55:22 +0000 (14:55 -0700)]
am 4c5d26bc: Make the app processing variant of dex-preopt more consistent.

Merge commit '4c5d26bcfe9027a6e350af70a67cf2b584534509' into gingerbread-plus-aosp

* commit '4c5d26bcfe9027a6e350af70a67cf2b584534509':
  Make the app processing variant of dex-preopt more consistent.

13 years agoMake the app processing variant of dex-preopt more consistent.
Dan Bornstein [Wed, 15 Sep 2010 21:44:01 +0000 (14:44 -0700)]
Make the app processing variant of dex-preopt more consistent.

In particular, make it take paths relative to the product, just like
how the bootclasspath is found and processed.

Change-Id: I3f2a98a6bf6bbcf3145cf9be8edc1c3be4d763b9

13 years agoam def30fc2: Clarify the use of --boot-dirs in the header comment.
Dan Bornstein [Tue, 14 Sep 2010 23:21:21 +0000 (16:21 -0700)]
am def30fc2: Clarify the use of --boot-dirs in the header comment.

Merge commit 'def30fc213d62fc93edce2ca63967ab93380075d' into gingerbread-plus-aosp

* commit 'def30fc213d62fc93edce2ca63967ab93380075d':
  Clarify the use of --boot-dirs in the header comment.

13 years agoClarify the use of --boot-dirs in the header comment.
Dan Bornstein [Tue, 14 Sep 2010 23:15:49 +0000 (16:15 -0700)]
Clarify the use of --boot-dirs in the header comment.

Change-Id: I89cf275e6188d5615bfb4e45fe35580b0ebe5be2

13 years agoam 32bc0787: Add use of sentinel in BOOTCLASSPATH entries during preopt.
Dan Bornstein [Tue, 14 Sep 2010 20:01:58 +0000 (13:01 -0700)]
am 32bc0787: Add use of sentinel in BOOTCLASSPATH entries during preopt.

Merge commit '32bc0787307ba57e92fa74c52da550e2ca22af7f' into gingerbread-plus-aosp

* commit '32bc0787307ba57e92fa74c52da550e2ca22af7f':
  Add use of sentinel in BOOTCLASSPATH entries during preopt.

13 years agoAdd use of sentinel in BOOTCLASSPATH entries during preopt.
Dan Bornstein [Tue, 14 Sep 2010 00:30:10 +0000 (17:30 -0700)]
Add use of sentinel in BOOTCLASSPATH entries during preopt.

This change introduces the use of the sentinel string "/./" inside
BOOTCLASSPATH entries to signal the start of the portion of the paths
that should be preserved in optimized dex file dependency lists. It's
a little grotty, but it does serve the purpose of allowing host side
dexopt to do its thing inside a build directory without letting the
host path leading up to that build directory to leak into the results.

This change also makes it an error (instead of just a warning) for
there to be BOOTCLASSPATH entries that are not absolute paths (either
truly absolute or ones with the sentinels as per above).

FWIW, dx uses this sentinel in a similar way.

Change-Id: Ic8d0533d3ee0bd7a1d4d06fcf9232c56f0a60abf

13 years agoam 96604831: First possibly-working cut of dex-preopt.
Dan Bornstein [Mon, 13 Sep 2010 23:43:59 +0000 (16:43 -0700)]
am 96604831: First possibly-working cut of dex-preopt.

Merge commit '96604831505a9ffef8d2da38c24a533a593efb34' into gingerbread-plus-aosp

* commit '96604831505a9ffef8d2da38c24a533a593efb34':
  First possibly-working cut of dex-preopt.

13 years agoFirst possibly-working cut of dex-preopt.
Dan Bornstein [Mon, 13 Sep 2010 22:37:28 +0000 (15:37 -0700)]
First possibly-working cut of dex-preopt.

Change-Id: I65c8ca76d75285ebd510babe5d0b3e0a157f82b7

13 years agoam 20228de2: Flesh out dex-preopt a bit more.
Dan Bornstein [Mon, 13 Sep 2010 20:49:41 +0000 (13:49 -0700)]
am 20228de2: Flesh out dex-preopt a bit more.

Merge commit '20228de2a8b0902d919b8acc27a9e954a597d16b' into gingerbread-plus-aosp

* commit '20228de2a8b0902d919b8acc27a9e954a597d16b':
  Flesh out dex-preopt a bit more.

13 years agoFlesh out dex-preopt a bit more.
Dan Bornstein [Mon, 13 Sep 2010 20:40:33 +0000 (13:40 -0700)]
Flesh out dex-preopt a bit more.

It's still not done.

Change-Id: I8b1cbe14841f12c8f299638c1ddaeec659ec441b

13 years agoam 46f7d54c: We also need to tell it the file mode when creating the output.
Dan Bornstein [Mon, 13 Sep 2010 18:52:10 +0000 (11:52 -0700)]
am 46f7d54c: We also need to tell it the file mode when creating the output.

Merge commit '46f7d54cbda931213bbe710c065e1bd82aa0af6c' into gingerbread-plus-aosp

* commit '46f7d54cbda931213bbe710c065e1bd82aa0af6c':
  We also need to tell it the file mode when creating the output.

13 years agoWe also need to tell it the file mode when creating the output.
Dan Bornstein [Mon, 13 Sep 2010 01:27:00 +0000 (18:27 -0700)]
We also need to tell it the file mode when creating the output.

Thanks to Elliott for catching this.

Change-Id: Ibb89ece3dd2e1d39a8a2d51cb8b7278842e057a1

13 years agoam 17e4ea8f: Actually, dexopt needs to read the optimized dex file too.
Dan Bornstein [Mon, 13 Sep 2010 01:17:08 +0000 (18:17 -0700)]
am 17e4ea8f: Actually, dexopt needs to read the optimized dex file too.

Merge commit '17e4ea8f17b6e4e14c483de49b3a3f053af188b4' into gingerbread-plus-aosp

* commit '17e4ea8f17b6e4e14c483de49b3a3f053af188b4':
  Actually, dexopt needs to read the optimized dex file too.

13 years agoam dd2502bd: Move declarations to the top to avoid potential uninitialized use.
Dan Bornstein [Mon, 13 Sep 2010 01:17:06 +0000 (18:17 -0700)]
am dd2502bd: Move declarations to the top to avoid potential uninitialized use.

Merge commit 'dd2502bd371ddca554b7a3d900fe120a3e7767ec' into gingerbread-plus-aosp

* commit 'dd2502bd371ddca554b7a3d900fe120a3e7767ec':
  Move declarations to the top to avoid potential uninitialized use.

13 years agoActually, dexopt needs to read the optimized dex file too.
Dan Bornstein [Mon, 13 Sep 2010 01:12:27 +0000 (18:12 -0700)]
Actually, dexopt needs to read the optimized dex file too.

Change-Id: Ib36cc0fd134a6916100060c8e2eee5158ac87201

13 years agoMove declarations to the top to avoid potential uninitialized use.
Dan Bornstein [Mon, 13 Sep 2010 00:34:35 +0000 (17:34 -0700)]
Move declarations to the top to avoid potential uninitialized use.

I didn't catch the warnings among the build spew before. Also, made
"--preopt" use stderr for its complaints about arguments.

Change-Id: I8d470ccc40c4cdc9131beb0991060358039e2727

13 years agoam 4701d5f8: Add a new "--preopt" mode to dexopt, for running on the host.
Dan Bornstein [Mon, 13 Sep 2010 00:23:51 +0000 (17:23 -0700)]
am 4701d5f8: Add a new "--preopt" mode to dexopt, for running on the host.

Merge commit '4701d5f8d0e691eeb9a0824311d5166d301a5aa5' into gingerbread-plus-aosp

* commit '4701d5f8d0e691eeb9a0824311d5166d301a5aa5':
  Add a new "--preopt" mode to dexopt, for running on the host.

13 years agoAdd a new "--preopt" mode to dexopt, for running on the host.
Dan Bornstein [Sun, 12 Sep 2010 23:42:28 +0000 (16:42 -0700)]
Add a new "--preopt" mode to dexopt, for running on the host.

This change takes much of what used to be in the function fromZip()
(the "--zip" mode implementation) and pulls it into a helper function,
which is then also used by the new preopt() function.

Change-Id: Id54618047896366448adaec0bf973627a9f1f397

13 years agoam ab9d89fb: Pre-alpha cut of the new dex preoptimization script.
Dan Bornstein [Sun, 12 Sep 2010 20:12:29 +0000 (13:12 -0700)]
am ab9d89fb: Pre-alpha cut of the new dex preoptimization script.

Merge commit 'ab9d89fb7417157c3972278d1bd899cc091a8168' into gingerbread-plus-aosp

* commit 'ab9d89fb7417157c3972278d1bd899cc091a8168':
  Pre-alpha cut of the new dex preoptimization script.

13 years agoPre-alpha cut of the new dex preoptimization script.
Dan Bornstein [Sun, 12 Sep 2010 20:03:27 +0000 (13:03 -0700)]
Pre-alpha cut of the new dex preoptimization script.

This will successfully find all the right directories etc., but it doesn't
do any actual dex processing yet. Stay tuned!

Change-Id: I4926308231366d6bae7b6a4594b4edb99192bf42

13 years agoam 23608ab4: Fix inliner bug for empty callees.
Ben Cheng [Sat, 11 Sep 2010 00:19:42 +0000 (17:19 -0700)]
am 23608ab4: Fix inliner bug for empty callees.

Merge commit '23608ab40900463fc5c8461671ba3aa5d0a4260e' into gingerbread-plus-aosp

* commit '23608ab40900463fc5c8461671ba3aa5d0a4260e':
  Fix inliner bug for empty callees.

13 years agoFix inliner bug for empty callees.
Ben Cheng [Sat, 11 Sep 2010 00:11:11 +0000 (17:11 -0700)]
Fix inliner bug for empty callees.

Add an explicit branch to continue from the next instruction.

Bug: 2992514

(cherry-picked from dalvik-dev)

Change-Id: I6e036e330255e7cd9d1504c50c4260910c38dfff

13 years agoam 50afc65c: Merge "JIT: Fix inconsistent handling of sub-word instance git/put"...
buzbee [Thu, 9 Sep 2010 23:48:42 +0000 (16:48 -0700)]
am 50afc65c: Merge "JIT: Fix inconsistent handling of sub-word instance git/put" into gingerbread

Merge commit '50afc65c674fee10ed9a0380daaee7862cc79d5d' into gingerbread-plus-aosp

* commit '50afc65c674fee10ed9a0380daaee7862cc79d5d':
  JIT: Fix inconsistent handling of sub-word instance git/put

13 years agoMerge "JIT: Fix inconsistent handling of sub-word instance git/put" into gingerbread
buzbee [Thu, 9 Sep 2010 23:46:09 +0000 (16:46 -0700)]
Merge "JIT: Fix inconsistent handling of sub-word instance git/put" into gingerbread