OSDN Git Service

android-x86/dalvik.git
11 years agoMerge "Fix dalvik tests post-conscrypt."
Elliott Hughes [Fri, 3 May 2013 18:55:51 +0000 (18:55 +0000)]
Merge "Fix dalvik tests post-conscrypt."

11 years agoFix dalvik tests post-conscrypt.
Elliott Hughes [Fri, 3 May 2013 18:54:59 +0000 (11:54 -0700)]
Fix dalvik tests post-conscrypt.

Change-Id: I36b942916330a3d6a06fad93dd9aa0533b47ff85

11 years agoMerge "Fix some leaks in VfyBasicBlock & BitVector."
Elliott Hughes [Fri, 3 May 2013 18:54:34 +0000 (18:54 +0000)]
Merge "Fix some leaks in VfyBasicBlock & BitVector."

11 years agoFix some leaks in VfyBasicBlock & BitVector.
You Kim [Wed, 3 Apr 2013 19:24:20 +0000 (04:24 +0900)]
Fix some leaks in VfyBasicBlock & BitVector.

Change-Id: I20050135588fc96268911b8ab690b04c8ad949bc

11 years agoMerge "Fix dx to match the new SDK structure."
Raphaël Moll [Fri, 3 May 2013 03:18:41 +0000 (03:18 +0000)]
Merge "Fix dx to match the new SDK structure."

11 years agoFix dx to match the new SDK structure.
Xavier Ducrohet [Tue, 26 Mar 2013 17:24:05 +0000 (10:24 -0700)]
Fix dx to match the new SDK structure.

(cherry picked from commit cb9dfa123c6fcc43be629666837c4e6f86b476ea)

Change-Id: I071d73adc4a2eb812cdbc204d27884f4a527043d

11 years agoMerge "Fix dx.bat to match the new SDK structure."
Raphael Moll [Thu, 2 May 2013 22:14:50 +0000 (22:14 +0000)]
Merge "Fix dx.bat to match the new SDK structure."

11 years agoMerge "Tracking changes to *-host for host shared libraries"
Brian Carlstrom [Thu, 2 May 2013 16:08:06 +0000 (16:08 +0000)]
Merge "Tracking changes to *-host for host shared libraries"

11 years agoTracking changes to *-host for host shared libraries
Brian Carlstrom [Thu, 2 May 2013 04:53:49 +0000 (21:53 -0700)]
Tracking changes to *-host for host shared libraries

Change-Id: I764889011cc259cdca306e2145bcc4c8c75eced5

11 years agoMerge "Fix JIT initialization race"
Elliott Hughes [Wed, 1 May 2013 20:57:13 +0000 (20:57 +0000)]
Merge "Fix JIT initialization race"

11 years agoFix JIT initialization race
buzbee [Wed, 1 May 2013 17:22:28 +0000 (10:22 -0700)]
Fix JIT initialization race

See b/8767735 Slow thread in thread spin test

A race exists in thread creation/JIT initialization that can
leave the JIT permanantly disabled for a thread (typically
the first interpreter thread).

(cherry-pick of 67985d960f5c877f86d0bba251d2d55c7a062b8d.)

Change-Id: Ic7e3a1cde2833ac78455fa5d465156b5e0896fc1

11 years agoMerge "Update dalvik host script for new conscrypt and okhttp classpath entries"
Brian Carlstrom [Wed, 1 May 2013 00:57:28 +0000 (00:57 +0000)]
Merge "Update dalvik host script for new conscrypt and okhttp classpath entries"

11 years agoUpdate dalvik host script for new conscrypt and okhttp classpath entries
Brian Carlstrom [Wed, 1 May 2013 00:51:03 +0000 (17:51 -0700)]
Update dalvik host script for new conscrypt and okhttp classpath entries

Change-Id: I9af7dfeb7387544bff98af55716f3db9808e39cb

11 years agoMerge changes I3ef1ad8c,I0bbbba1a,Ife107fb6,Ia420b766
Brian Carlstrom [Tue, 30 Apr 2013 21:45:35 +0000 (21:45 +0000)]
Merge changes I3ef1ad8c,I0bbbba1a,Ife107fb6,Ia420b766

* changes:
  Switch Dex from byte[] to ByteBuffer for backing store. Part 2.
  Move dex utilities from dalvik/dx to libcore/dex
  Mechanical refactoring of dx into two parts.
  Change com.android.dx.io.Annotation to use EncodedValue

11 years agoMerge "Teach dex how to parse encoded values from .dex files."
Brian Carlstrom [Tue, 30 Apr 2013 21:45:26 +0000 (21:45 +0000)]
Merge "Teach dex how to parse encoded values from .dex files."

11 years agoSwitch Dex from byte[] to ByteBuffer for backing store. Part 2.
Jesse Wilson [Mon, 19 Sep 2011 02:45:39 +0000 (22:45 -0400)]
Switch Dex from byte[] to ByteBuffer for backing store. Part 2.

Change-Id: Ifd3672027d075b6c9f8df208a04bc33122c883af
(cherry picked from commit f8357511efd16d76ce4410459c15dbb08b0140b6)

Conflicts:
dx/src/com/android/dx/merge/DexMerger.java

11 years agoMove dex utilities from dalvik/dx to libcore/dex
Jesse Wilson [Sun, 18 Sep 2011 16:53:38 +0000 (12:53 -0400)]
Move dex utilities from dalvik/dx to libcore/dex

Change-Id: If0022a069ba3ac51ae5cdc4b0eabb6b913cd8afe
(cherry picked from commit 7b13a4d41243f81fe80a76e2ff2f877b53610446)

Conflicts:
dx/src/com/android/dex/Code.java
dx/src/com/android/dex/Dex.java
dx/src/com/android/dex/SizeOf.java
dx/src/com/android/dex/TableOfContents.java

11 years agoMechanical refactoring of dx into two parts.
Jesse Wilson [Sat, 17 Sep 2011 03:10:02 +0000 (23:10 -0400)]
Mechanical refactoring of dx into two parts.

This splits off a new package, com.android.dex that contains
code for parsing and modelling dex files. This code is usable
both at build time (for compilation and analysis) and at runtime
(for introspection).

The original package, com.android.dx is the tool that compiles
.class files into .dex files. That package also includes utilities
for merging and querying dex files, all visible to the dx command
line application.

In a follow up change I'll move the new com.android.dex package
into the libcore/ project, and configure build rules so that it's
included in both dx.jar and core.jar. The core.jar will then be
able to use it for annotation processing.

Change-Id: I3c58cf87e728e4dda1925a0992c1ee7b8130e81a
(cherry picked from commit bab4abb07335d162ecdb8091fc395cf84803a580)

Conflicts:
dx/junit-tests/com/android/dx/util/BitIntSetTest.java
dx/junit-tests/com/android/dx/util/BitsTest.java
dx/junit-tests/com/android/dx/util/IntListTest.java
dx/junit-tests/com/android/dx/util/ListIntSetTest.java
dx/src/com/android/dex/Dex.java
dx/src/com/android/dex/TableOfContents.java
dx/src/com/android/dx/annotations/AnnotationAccess.java
dx/src/com/android/dx/command/Main.java
dx/src/com/android/dx/dex/code/OutputFinisher.java
dx/src/com/android/dx/dex/code/form/Form32s.java
dx/src/com/android/dx/dex/code/form/Form33x.java
dx/src/com/android/dx/dex/code/form/Form41c.java
dx/src/com/android/dx/dex/code/form/Form52c.java
dx/src/com/android/dx/gen/DexGenerator.java
dx/src/com/android/dx/merge/DexMerger.java

11 years agoChange com.android.dx.io.Annotation to use EncodedValue
Brian Carlstrom [Tue, 30 Apr 2013 01:26:09 +0000 (18:26 -0700)]
Change com.android.dx.io.Annotation to use EncodedValue

(cherry picked from commit 4ec022b0b6c84f994ab2fc78934110ad96d0bdec)

Change-Id: Ia420b7661f372c59af8fe62bdab7982a1d2b008f

11 years agoTeach dex how to parse encoded values from .dex files.
Jesse Wilson [Thu, 15 Sep 2011 19:49:25 +0000 (15:49 -0400)]
Teach dex how to parse encoded values from .dex files.

Previously primitive values were treated as opaque byte arrays.
Now the encoded values can be interpreted as their proper types:
integers, indices, floats, chars, etc. This gets complicated
pretty fast due to the dense packing dx performs when encoding
the values.

The encoding code is moved from ValueEncoder. The decoding code
is ported from C++ to Java from Annotation.cpp.

There's a bunch of new tests to make sure the decoding is correct;
porting from C++ to Java was tricky because of the '>>' shifts on
unsigned values. The test input data is generated by dex!

Change-Id: I83b2fc3e16115d667fa94b3dab782d1a9687f3ad
(cherry picked from commit 27847605b9255358f0577ffec28886c450263898)

11 years agoMerge "Fix JIT bug related to immediate doubles"
Elliott Hughes [Fri, 26 Apr 2013 17:37:22 +0000 (17:37 +0000)]
Merge "Fix JIT bug related to immediate doubles"

11 years agoFix JIT bug related to immediate doubles
buzbee [Tue, 12 Feb 2013 00:52:31 +0000 (16:52 -0800)]
Fix JIT bug related to immediate doubles

Change 256211 (JIT: Performance Fix for const doubles) introduced a
defect that can cause the JIT to use the wrong floating point
double constant in traces in which the following conditions hold:

   o Two (or more) different 64-bit floating point constants are used.
   o The physical register holding the first constant is still live
     at the time the second constant is used.
   o The low 32 bits of the two constants are identical.

In this situation, the load/copy optimization pass will incorrectly
determine that the two constants are the same, delete the load of
the second constant and re-use the first constant value.

Note: this problem only occurs with 64-bit floating point literals.
64-bit long literals are unaffected.

This CL works around the problem, and a subsequent CL will rework
disambiguation of 64-bit immediates in a somewhat cleaner fashion.

(cherry-pick of c1757a6deab0ca0bfd42c38612d92b2f26c41dbe.)

Change-Id: I795b4b753550d2745cbbdd83ae25f4a7088990f6

11 years agoMerge "Don't duplicate annotation set ref lists when merging."
Elliott Hughes [Thu, 25 Apr 2013 18:36:21 +0000 (18:36 +0000)]
Merge "Don't duplicate annotation set ref lists when merging."

11 years agoFix dx.bat to match the new SDK structure.
Raphael Moll [Wed, 24 Apr 2013 22:02:13 +0000 (15:02 -0700)]
Fix dx.bat to match the new SDK structure.

(Cherry-picked from c26c1291743ce7877cf11f3dc73d6f0c240229f7)

Change-Id: I57a7678178fc58e2a101c9d86da5009c6ec4f6a0

11 years agoMerge "Remove spammy logging from 8470684 investigation."
Elliott Hughes [Tue, 23 Apr 2013 18:44:41 +0000 (18:44 +0000)]
Merge "Remove spammy logging from 8470684 investigation."

11 years agoRemove spammy logging from 8470684 investigation.
Elliott Hughes [Tue, 23 Apr 2013 18:35:17 +0000 (11:35 -0700)]
Remove spammy logging from 8470684 investigation.

This has been tracked down to a kernel bug, so we no longer need
the extra diagnostics.

Bug: 8470684
Change-Id: Ib170d1f7b94488ed4acc763f8dddc44c81807aed

11 years agoMerge "Work around a dalvik JDWP/GC deadlock."
Elliott Hughes [Wed, 17 Apr 2013 20:18:08 +0000 (20:18 +0000)]
Merge "Work around a dalvik JDWP/GC deadlock."

11 years agoWork around a dalvik JDWP/GC deadlock.
Elliott Hughes [Wed, 17 Apr 2013 19:08:56 +0000 (12:08 -0700)]
Work around a dalvik JDWP/GC deadlock.

Also add a few missing TEMP_FAILURE_RETRYs that can cause dalvik to
incorrectly decide that the debugger connection has been broken.

Bug: 8191824
Change-Id: I791b514c6bec1ca634a65d9f87c5fa06da01b5ed

11 years agoMerge "More native stack dump hardening."
Elliott Hughes [Fri, 12 Apr 2013 20:47:54 +0000 (20:47 +0000)]
Merge "More native stack dump hardening."

11 years agoMore native stack dump hardening.
Elliott Hughes [Fri, 12 Apr 2013 18:51:51 +0000 (11:51 -0700)]
More native stack dump hardening.

Threads just starting up or shutting down might not have any managed
stack frames, leading to a NULL "currFrame" frame pointer in the
interpreter stack.

Bug: 8596028
Change-Id: Ie24c8d5f8e78a5abe882a9e639046c03abb91649

11 years agoMerge "Fix flakiness in test 080-oom-throw."
Elliott Hughes [Fri, 12 Apr 2013 00:23:03 +0000 (00:23 +0000)]
Merge "Fix flakiness in test 080-oom-throw."

11 years agoFix flakiness in test 080-oom-throw.
Elliott Hughes [Fri, 12 Apr 2013 00:14:50 +0000 (17:14 -0700)]
Fix flakiness in test 080-oom-throw.

The problem was that the instance test could potentially fill the
heap close enough to the edge that you'd hit a follow-on OOME in
the attempt to print the success message, causing the test to fail.

I've also made the code a bit clearer while I'm here.

Bug: https://code.google.com/p/android/issues/detail?id=54114
Change-Id: I39127c3ea6a99940fa66ad8763bbbf6c01d308ef

11 years agoMerge "Harden the native stack dumping decision."
Elliott Hughes [Thu, 11 Apr 2013 23:41:29 +0000 (23:41 +0000)]
Merge "Harden the native stack dumping decision."

11 years agoHarden the native stack dumping decision.
Elliott Hughes [Thu, 11 Apr 2013 23:28:38 +0000 (16:28 -0700)]
Harden the native stack dumping decision.

We've seen monkey crashes in this code, though I haven't been
able to reproduce them in my own SIGQUIT stress tests. Address
the two most likely causes of trouble: dumping the signal catcher's
own thread (which will always be runnable), and assuming that the
Method* pulled from the save area is non-NULL.

Bug: 8596028
Change-Id: I59d1dcb2264a774d8416d50a5f77a06c70d37c59

11 years agoMerge "Dump native stacks for all threads in native code."
Elliott Hughes [Sat, 6 Apr 2013 00:01:03 +0000 (00:01 +0000)]
Merge "Dump native stacks for all threads in native code."

11 years agoDump native stacks for all threads in native code.
Elliott Hughes [Fri, 5 Apr 2013 22:45:24 +0000 (15:45 -0700)]
Dump native stacks for all threads in native code.

Bug: 7432159
Change-Id: I83cb530155edfc35ae3be0f7a2a044245223d2d5

11 years agoDon't duplicate annotation set ref lists when merging.
jwilson [Fri, 5 Apr 2013 07:46:53 +0000 (03:46 -0400)]
Don't duplicate annotation set ref lists when merging.

See exception reported on this thread:
https://groups.google.com/d/msg/android-contrib/h0sDMo5DVBI/MAMiBv5XR44J

Change-Id: I867a8d2328b32625e5baa0b029f55e373fe11271

11 years agoMerge "Tiny optimization for complier templates for arm."
Elliott Hughes [Tue, 2 Apr 2013 20:33:04 +0000 (20:33 +0000)]
Merge "Tiny optimization for complier templates for arm."

11 years agoMerge "Fix a leak in Dalvik_dalvik_system_DexFile_openDexFile"
Elliott Hughes [Tue, 2 Apr 2013 20:28:05 +0000 (20:28 +0000)]
Merge "Fix a leak in Dalvik_dalvik_system_DexFile_openDexFile"

11 years agoMerge "Fix a minor leaks caused by failed initializations.(typo)"
Elliott Hughes [Tue, 2 Apr 2013 20:12:14 +0000 (20:12 +0000)]
Merge "Fix a minor leaks caused by failed initializations.(typo)"

11 years agoMerge "Fix a minor leak in handleVM_CreateString"
Elliott Hughes [Tue, 2 Apr 2013 18:29:18 +0000 (18:29 +0000)]
Merge "Fix a minor leak in handleVM_CreateString"

11 years agoFix a minor leak in handleVM_CreateString
You Kim [Tue, 2 Apr 2013 17:47:24 +0000 (02:47 +0900)]
Fix a minor leak in handleVM_CreateString

Change-Id: I3273e5d2eb4621202837c43270a466fe056d6894

11 years agoFix a minor leaks caused by failed initializations.(typo)
You Kim [Tue, 2 Apr 2013 17:13:46 +0000 (02:13 +0900)]
Fix a minor leaks caused by failed initializations.(typo)

Change-Id: I62bc3ea48938a4f54e9f47218d4025e954a6d566

11 years agoFix a leak in Dalvik_dalvik_system_DexFile_openDexFile
You Kim [Tue, 2 Apr 2013 16:58:30 +0000 (01:58 +0900)]
Fix a leak in Dalvik_dalvik_system_DexFile_openDexFile

Change-Id: I2b394c620af31914606763b35847b7f412774cf4

11 years agoTiny optimization for complier templates for arm.
You Kim [Tue, 2 Apr 2013 16:41:19 +0000 (01:41 +0900)]
Tiny optimization for complier templates for arm.

1. Remove possible bubble in TEMPLATE_STRING_INDEXOF.S
2. Remove 1 instruction and reorder the opcodes
   TEMPLATE_MUL_LONG.S
3. Reorder ldr r2 instruction in TEMPLATE_RETURN.S

Change-Id: I571c1278aa72cb1e6dbc6efe433932d5e9591b80

11 years agoMerge "[x86] Fix errors with WITH_JIT_TUNING defined"
Elliott Hughes [Mon, 1 Apr 2013 23:04:54 +0000 (23:04 +0000)]
Merge "[x86] Fix errors with WITH_JIT_TUNING defined"

11 years agoMerge "[x86] Terminate trace if SGET/SPUT have unresolved fields in codegen"
Elliott Hughes [Mon, 1 Apr 2013 22:53:09 +0000 (22:53 +0000)]
Merge "[x86] Terminate trace if SGET/SPUT have unresolved fields in codegen"

11 years agoMerge "[x86] FPU stack needs to be reset after double conversion"
Elliott Hughes [Mon, 1 Apr 2013 21:39:58 +0000 (21:39 +0000)]
Merge "[x86] FPU stack needs to be reset after double conversion"

11 years ago[x86] FPU stack needs to be reset after double conversion
Udayan Banerji [Mon, 1 Apr 2013 21:27:09 +0000 (14:27 -0700)]
[x86] FPU stack needs to be reset after double conversion

The x86 codegen uses the FPU stack for double/float to long conversions. We
need to clear out the FPU stack after done, to prevent an eventual stack
overflow.

Change-Id: I2f306d7c228ad3da2b84faf9f08326769a9417af
Signed-off-by: Udayan Banerji <udayan.banerji@intel.com>
11 years agoMerge "[x86] Disable Method-JIT for x86 target"
Elliott Hughes [Mon, 1 Apr 2013 20:08:46 +0000 (20:08 +0000)]
Merge "[x86] Disable Method-JIT for x86 target"

11 years agoMerge "Fix a cast in JniEnv::NewDirectByteBuffer."
Elliott Hughes [Sat, 30 Mar 2013 00:42:17 +0000 (00:42 +0000)]
Merge "Fix a cast in JniEnv::NewDirectByteBuffer."

11 years agoFix a cast in JniEnv::NewDirectByteBuffer.
Elliott Hughes [Sat, 30 Mar 2013 00:27:28 +0000 (17:27 -0700)]
Fix a cast in JniEnv::NewDirectByteBuffer.

Change-Id: I8692b31c6ce64efc68124df02117b6e4529dfe98

11 years agoMerge "Track libcore's DirectByteBuffer <init> change."
Elliott Hughes [Sat, 30 Mar 2013 00:20:29 +0000 (00:20 +0000)]
Merge "Track libcore's DirectByteBuffer <init> change."

11 years agoTrack libcore's DirectByteBuffer <init> change.
Elliott Hughes [Sat, 30 Mar 2013 00:19:31 +0000 (17:19 -0700)]
Track libcore's DirectByteBuffer <init> change.

See 9ce6a2533b50ffcd24b8b10bae7f234042768819.

Change-Id: Ie736e69a3fa7bdf55709d8e2960761202a20e820

11 years agoMerge "Extra log information when pthread_create fails."
Elliott Hughes [Fri, 29 Mar 2013 23:47:53 +0000 (23:47 +0000)]
Merge "Extra log information when pthread_create fails."

11 years agoExtra log information when pthread_create fails.
Elliott Hughes [Fri, 29 Mar 2013 23:37:25 +0000 (16:37 -0700)]
Extra log information when pthread_create fails.

Bug: 8470684
Change-Id: I24d22d5ec4181614d173a582773540c8f712ab18

11 years ago[x86] Fix errors with WITH_JIT_TUNING defined
Udayan Banerji [Fri, 29 Mar 2013 21:05:18 +0000 (14:05 -0700)]
[x86] Fix errors with WITH_JIT_TUNING defined

This patch makes the necessary changes to pass on correct information to
dvmBumpNoChain, so that WITH_JIT_TUNING flag can be enabled for x86 codegen

Change-Id: Ia5e5c0406433bf645ef67143d0f1a11a28153a66
Signed-off-by: Udayan Banerji <udayan.banerji@intel.com>
11 years ago[x86] Terminate trace if SGET/SPUT have unresolved fields in codegen
Udayan Banerji [Fri, 29 Mar 2013 20:32:10 +0000 (13:32 -0700)]
[x86] Terminate trace if SGET/SPUT have unresolved fields in codegen

The interpreter doesn't allow SGET/SPUT bytecodes in a trace till the field
is resolved. However, exhaustTrace can pick up bytecodes beyond the trace
sent by the interpreter. Terminate the loop formation if this is seen.

Change-Id: I0f38d6690b3501111bd16103623fa545d0ec1873
Signed-off-by: Udayan Banerji <udayan.banerji@intel.com>
11 years ago[x86] Disable Method-JIT for x86 target
Udayan Banerji [Fri, 29 Mar 2013 17:52:32 +0000 (10:52 -0700)]
[x86] Disable Method-JIT for x86 target

Disable Method JIT when compiling for x86 target.

Change-Id: Ide0dbd1f602ffd955b901cc152de1e05771fd529
Signed-off-by: Udayan Banerji <udayan.banerji@intel.com>
11 years agoMerge "Track 64-bit nio changes."
Elliott Hughes [Fri, 29 Mar 2013 17:14:49 +0000 (17:14 +0000)]
Merge "Track 64-bit nio changes."

11 years agoTrack 64-bit nio changes.
Elliott Hughes [Fri, 29 Mar 2013 16:59:23 +0000 (09:59 -0700)]
Track 64-bit nio changes.

Change-Id: Id7a11af5f94b8ba82d42e1e7045302aca533f31a

11 years agoMerge "Track libcore DirectByteBuffer cleanup."
Elliott Hughes [Thu, 28 Mar 2013 15:29:43 +0000 (15:29 +0000)]
Merge "Track libcore DirectByteBuffer cleanup."

11 years agoTrack libcore DirectByteBuffer cleanup.
Elliott Hughes [Wed, 27 Mar 2013 23:23:35 +0000 (16:23 -0700)]
Track libcore DirectByteBuffer cleanup.

Bug: https://code.google.com/p/android/issues/detail?id=53637
Change-Id: I7acd990a2a48b41dacb5b09f6410b4634dd60438

11 years agoMerge "pthread_create doesn't set errno."
Elliott Hughes [Wed, 27 Mar 2013 00:22:16 +0000 (00:22 +0000)]
Merge "pthread_create doesn't set errno."

11 years agopthread_create doesn't set errno.
Elliott Hughes [Tue, 26 Mar 2013 23:25:15 +0000 (16:25 -0700)]
pthread_create doesn't set errno.

Let's try to get slightly better logging and exception detail messages.

Also fix the "set but not read" warnings for the other pthread functions
in this file.

Bug: 8470684
Change-Id: I7f9dbb4d39b4e3022cd5f1a8a45c6426e68c858b

11 years agoMerge "Print the locker thread when waiting on an object"
Elliott Hughes [Tue, 26 Mar 2013 22:33:07 +0000 (22:33 +0000)]
Merge "Print the locker thread when waiting on an object"

11 years agoMerge "javac should have matching -source and -target flags."
Elliott Hughes [Thu, 21 Mar 2013 17:27:23 +0000 (17:27 +0000)]
Merge "javac should have matching -source and -target flags."

11 years agojavac should have matching -source and -target flags.
Elliott Hughes [Thu, 21 Mar 2013 17:25:39 +0000 (10:25 -0700)]
javac should have matching -source and -target flags.

Change-Id: I2ac5f0685bd5844252cc334d4040d68e01d39429

11 years agoMerge "Fix a Field.isAnnotationPresent crash."
Elliott Hughes [Tue, 19 Mar 2013 23:36:48 +0000 (23:36 +0000)]
Merge "Fix a Field.isAnnotationPresent crash."

11 years agoFix a Field.isAnnotationPresent crash.
Elliott Hughes [Tue, 19 Mar 2013 21:41:42 +0000 (14:41 -0700)]
Fix a Field.isAnnotationPresent crash.

For instances of Proxy, generated at runtime, there is no corresponding
.dex file.

Bug: https://code.google.com/p/android/issues/detail?id=24846
Change-Id: I36da43d5279a61b8cb71cdf2bbc3065b6a979830

11 years agoMerge "Check JavaVMAttachArgs::version in CheckJNI."
Elliott Hughes [Thu, 14 Mar 2013 01:40:17 +0000 (01:40 +0000)]
Merge "Check JavaVMAttachArgs::version in CheckJNI."

11 years agoCheck JavaVMAttachArgs::version in CheckJNI.
Elliott Hughes [Thu, 14 Mar 2013 01:35:54 +0000 (18:35 -0700)]
Check JavaVMAttachArgs::version in CheckJNI.

Bug: 8363798
Change-Id: I314bf6d5d64a1e27ad2c1580532133859031c623

11 years agoMerge "Don't crash if the dmtracedump -d file doesn't exist."
Elliott Hughes [Wed, 6 Mar 2013 16:35:01 +0000 (16:35 +0000)]
Merge "Don't crash if the dmtracedump -d file doesn't exist."

11 years agoDon't crash if the dmtracedump -d file doesn't exist.
Elliott Hughes [Wed, 6 Mar 2013 06:42:37 +0000 (22:42 -0800)]
Don't crash if the dmtracedump -d file doesn't exist.

Change-Id: Ie4b504b43a8a61d09ca60d68b1a62694391ac223

11 years agoMerge "Fix -Xjitthreshold (for real this time)."
Elliott Hughes [Fri, 1 Mar 2013 19:05:44 +0000 (19:05 +0000)]
Merge "Fix -Xjitthreshold (for real this time)."

11 years agoFix -Xjitthreshold (for real this time).
Elliott Hughes [Fri, 1 Mar 2013 18:45:01 +0000 (10:45 -0800)]
Fix -Xjitthreshold (for real this time).

My previous "fix" (c89d83e1c05979b68037ad15413fa4460a88e36f) had the
conditions reversed, so you _had_ to use -Xjitthreshold to get a non-zero
threshold, but when you did, you'd get the default instead of what you
asked for!

This was spotted by the jank tests.

Bug: 8285558
Bug: https://code.google.com/p/android/issues/detail?id=52017
Change-Id: I28270f2573d46929eb10d30789fecf7d5a8cea75

11 years agoMerge "Zygote: use proper header file."
Nick Kralevich [Wed, 27 Feb 2013 23:25:18 +0000 (23:25 +0000)]
Merge "Zygote: use proper header file."

11 years agoMerge "Remove CAP_NET_RAW from zygote"
Nick Kralevich [Wed, 27 Feb 2013 21:24:09 +0000 (21:24 +0000)]
Merge "Remove CAP_NET_RAW from zygote"

11 years agoRemove CAP_NET_RAW from zygote
Nick Kralevich [Wed, 27 Feb 2013 20:59:06 +0000 (12:59 -0800)]
Remove CAP_NET_RAW from zygote

ping no longer needs CAP_NET_RAW. See:

* http://lwn.net/Articles/443051/
* https://android-review.googlesource.com/52090
* https://android-review.googlesource.com/52072

Eliminate the CAP_NET_RAW special case in zygote.

Change-Id: Ie4b1d2b65a27051bbd2825d288f9838762ae31c8

11 years agoZygote: use proper header file.
Nick Kralevich [Wed, 27 Feb 2013 00:20:11 +0000 (16:20 -0800)]
Zygote: use proper header file.

capset is defined in <sys/capability.h>

Change-Id: Ifb340cfb3506830242749456706d4eddb73fb2aa

11 years agoMerge "Fix -Xjitthreshold."
Elliott Hughes [Tue, 26 Feb 2013 01:24:30 +0000 (01:24 +0000)]
Merge "Fix -Xjitthreshold."

11 years agoFix -Xjitthreshold.
Elliott Hughes [Tue, 26 Feb 2013 01:04:06 +0000 (17:04 -0800)]
Fix -Xjitthreshold.

Previously, we'd always overwrite the user-supplied value because
the architecture-specific default gets set so late.

Bug: https://code.google.com/p/android/issues/detail?id=52017
Change-Id: I469bf9ce599820f5ce3dea346aa8f680deffb0c5

11 years agoMerge "Abstract methods aren't implementations."
Elliott Hughes [Sat, 23 Feb 2013 01:32:09 +0000 (01:32 +0000)]
Merge "Abstract methods aren't implementations."

11 years agoAbstract methods aren't implementations.
Elliott Hughes [Sat, 23 Feb 2013 01:04:54 +0000 (17:04 -0800)]
Abstract methods aren't implementations.

We should only be checking the visibility of actual implementations
of interface methods. Intervening abstract methods are allowed to
be non-public.

Bug: https://code.google.com/p/android/issues/detail?id=42991
Change-Id: I510d0cc6c1f89d161d4ebad7ef058c03fa09e9b0

11 years agoMerge "Zygote: replace set?id() with setres?id()"
Nick Kralevich [Wed, 20 Feb 2013 22:29:22 +0000 (22:29 +0000)]
Merge "Zygote: replace set?id() with setres?id()"

11 years agoZygote: replace set?id() with setres?id()
Nick Kralevich [Wed, 20 Feb 2013 21:56:11 +0000 (13:56 -0800)]
Zygote: replace set?id() with setres?id()

setuid -> setresuid()
setgid -> setresgid()

Change-Id: I319a6a0ea63cf5bd3755ec8371064365be30872b

11 years agoMerge "Expand test 004-annotations to cover package annotations."
Elliott Hughes [Wed, 20 Feb 2013 19:50:04 +0000 (19:50 +0000)]
Merge "Expand test 004-annotations to cover package annotations."

11 years agoExpand test 004-annotations to cover package annotations.
Elliott Hughes [Wed, 20 Feb 2013 19:19:32 +0000 (11:19 -0800)]
Expand test 004-annotations to cover package annotations.

Bug: https://code.google.com/p/android/issues/detail?id=16149
Change-Id: I0fa26a5201fc80a6f049d61d34e403d4cb5c505a

11 years agoMerge "Added missing initialization of modLock when DvmDex structures are allocated."
Elliott Hughes [Tue, 19 Feb 2013 19:01:26 +0000 (19:01 +0000)]
Merge "Added missing initialization of modLock when DvmDex structures are allocated."

11 years agoAdded missing initialization of modLock when DvmDex structures are allocated.
msg555 [Tue, 19 Feb 2013 14:47:28 +0000 (09:47 -0500)]
Added missing initialization of modLock when DvmDex structures are allocated.

The structure is zeroed with dvmAllocRegion (use to be calloc) which for most
implementations of pthreads behaves correctly as if initialized. However, an explicit
initialization is more correct.

Change-Id: I172fed73c2a8a6962d720f78c60436b4f58cc168

11 years agoMerge "Move the arraycopy implementation out of bionic and into dalvik."
Elliott Hughes [Fri, 15 Feb 2013 23:22:05 +0000 (23:22 +0000)]
Merge "Move the arraycopy implementation out of bionic and into dalvik."

11 years agoMove the arraycopy implementation out of bionic and into dalvik.
Elliott Hughes [Fri, 15 Feb 2013 22:25:15 +0000 (14:25 -0800)]
Move the arraycopy implementation out of bionic and into dalvik.

Change-Id: I5b7964e53eca6f2da949d6ef24d42a9c6ed3996c

11 years agoMerge "Zygote: address comments from previous review."
Nick Kralevich [Thu, 14 Feb 2013 19:11:46 +0000 (19:11 +0000)]
Merge "Zygote: address comments from previous review."

11 years agoZygote: address comments from previous review.
Nick Kralevich [Thu, 14 Feb 2013 19:00:33 +0000 (11:00 -0800)]
Zygote: address comments from previous review.

Previous review at https://android-review.googlesource.com/51731

Change-Id: Idfe6c95976cc8f82ec473bcb630678fa9ec9486a

11 years agoMerge "Zygote: limit the bounding capability set to CAP_NET_RAW"
Nick Kralevich [Thu, 14 Feb 2013 18:50:37 +0000 (18:50 +0000)]
Merge "Zygote: limit the bounding capability set to CAP_NET_RAW"

11 years agoZygote: limit the bounding capability set to CAP_NET_RAW
Nick Kralevich [Thu, 14 Feb 2013 17:56:41 +0000 (09:56 -0800)]
Zygote: limit the bounding capability set to CAP_NET_RAW

Prevent a zygote spawned application from acquiring
capabilities other than CAP_NET_RAW.  The only Zygote
accessible program on Android which grants capabilities
is /system/bin/ping (CAP_NET_RAW), so we don't need to
keep the other capabilities in our bounding set.

If the kernel doesn't support file capabilities, we
end up printing approx 30 lines of warning messages. Hopefully
this will encourage kernel developers to upgrade. In a future
change, we can turn a prctl(PR_CAPBSET_DROP) failure into
a fatal error.

Change-Id: I8560fa5ad125bf31f0d13be513431697bc7d22bb

11 years agoMerge "Remove stray references to non-existent opcodes."
Elliott Hughes [Thu, 14 Feb 2013 18:20:14 +0000 (18:20 +0000)]
Merge "Remove stray references to non-existent opcodes."

11 years agoRemove stray references to non-existent opcodes.
Elliott Hughes [Thu, 14 Feb 2013 18:09:00 +0000 (10:09 -0800)]
Remove stray references to non-existent opcodes.

Change-Id: I83ca6ea12344a8df7ef14d600baf5060b76870f5

11 years agoMerge "Revert "Zygote: limit the bounding capability set to CAP_NET_RAW""
Elliott Hughes [Thu, 14 Feb 2013 01:29:29 +0000 (01:29 +0000)]
Merge "Revert "Zygote: limit the bounding capability set to CAP_NET_RAW""

11 years agoRevert "Zygote: limit the bounding capability set to CAP_NET_RAW"
Elliott Hughes [Thu, 14 Feb 2013 01:29:19 +0000 (01:29 +0000)]
Revert "Zygote: limit the bounding capability set to CAP_NET_RAW"

This reverts commit 921e9aea72bc2aa99a52ccdb90573bbd3bf3508f, which prevents the emulator from booting.

Change-Id: I73b7afba38d4087d552dd685c56d4e5ddb3103cf