OSDN Git Service

android-x86/art.git
10 years agoRound up arena allocations to 8 bytes.
Vladimir Marko [Tue, 10 Jun 2014 13:47:51 +0000 (14:47 +0100)]
Round up arena allocations to 8 bytes.

Prevent SIGBUS/BUS_ADRALN when we use the arena for classes
with 64-bit alignment.

Change-Id: I5382ed7072fcfb2349f61558e1fd8257315ee336

10 years agoMerge "Add locking around boot image generation."
Narayan Kamath [Tue, 10 Jun 2014 11:03:14 +0000 (11:03 +0000)]
Merge "Add locking around boot image generation."

10 years agoAdd locking around boot image generation.
Narayan Kamath [Mon, 9 Jun 2014 15:50:19 +0000 (16:50 +0100)]
Add locking around boot image generation.

If zygote aborts due to an error, it will restart and
spawn another dex2oat process while the old one is still
running. If this happens fast enough, the system will
eventually need a kernel reboot since neither the zygote
nor dex2oat are killable.

This brings boot image generation in line with dex2oat
generation, which uses a similar pattern of advisory
locking.

bug: 15415316

Change-Id: Iaccd274d3d96ab002b04e246ec4b3ef9a422ff7c

10 years agoMerge "Plug code generator into liveness analysis."
Nicolas Geoffray [Tue, 10 Jun 2014 09:54:07 +0000 (09:54 +0000)]
Merge "Plug code generator into liveness analysis."

10 years agoPlug code generator into liveness analysis.
Nicolas Geoffray [Mon, 9 Jun 2014 14:02:22 +0000 (15:02 +0100)]
Plug code generator into liveness analysis.

Also implement spill slot support.

Change-Id: If5e28811e9fbbf3842a258772c633318a2f4fafc

10 years agoMerge "Add a type propagation phase after building SSA."
Nicolas Geoffray [Tue, 10 Jun 2014 08:26:04 +0000 (08:26 +0000)]
Merge "Add a type propagation phase after building SSA."

10 years agoMerge "X86_64: Pass 'hidden method index' in EAX"
Ian Rogers [Tue, 10 Jun 2014 06:35:22 +0000 (06:35 +0000)]
Merge "X86_64: Pass 'hidden method index' in EAX"

10 years agoMerge "Tidy up x86 assembler and fix byte register encoding."
Ian Rogers [Tue, 10 Jun 2014 05:52:13 +0000 (05:52 +0000)]
Merge "Tidy up x86 assembler and fix byte register encoding."

10 years agoMerge "ART: Generic JNI for x86"
Andreas Gampe [Tue, 10 Jun 2014 05:48:30 +0000 (05:48 +0000)]
Merge "ART: Generic JNI for x86"

10 years agoTidy up x86 assembler and fix byte register encoding.
Ian Rogers [Mon, 9 Jun 2014 08:32:12 +0000 (01:32 -0700)]
Tidy up x86 assembler and fix byte register encoding.

Also fix reg storage int size issues.
Also fix bad use of byte registers in GenInlinedCas.

Change-Id: Id47424f36f9000e051110553e0b51816910e2fe8

10 years agoMerge "Fix output of 107 art/test"
Bill Buzbee [Tue, 10 Jun 2014 04:06:35 +0000 (04:06 +0000)]
Merge "Fix output of 107 art/test"

10 years agoMerge "X86_64: Fix core.oat compilation issues"
Bill Buzbee [Tue, 10 Jun 2014 04:06:29 +0000 (04:06 +0000)]
Merge "X86_64: Fix core.oat compilation issues"

10 years agoMerge "x86_64: Reduce dex2oat compilation logs"
Bill Buzbee [Tue, 10 Jun 2014 04:06:22 +0000 (04:06 +0000)]
Merge "x86_64: Reduce dex2oat compilation logs"

10 years agoMerge "AArch64: fix and enable sparse- and packed-switch."
Bill Buzbee [Tue, 10 Jun 2014 04:06:14 +0000 (04:06 +0000)]
Merge "AArch64: fix and enable sparse- and packed-switch."

10 years agoART: Generic JNI for x86
Andreas Gampe [Tue, 10 Jun 2014 01:29:38 +0000 (18:29 -0700)]
ART: Generic JNI for x86

Add the generic JNI trampoline for x86. Small cleanup in the C code.

Change-Id: Icaf9de7c0e5e8d1e6cb1135a54552040344cc5a3

10 years agoX86_64: Pass 'hidden method index' in EAX
Mark Mendell [Mon, 9 Jun 2014 19:10:50 +0000 (15:10 -0400)]
X86_64: Pass 'hidden method index' in EAX

Method* is in EDI, and EAX isn't an argument register, so EAX is free
to hold the hidden method index.

Change-Id: I793a54d00a4593e140f97144419d849b53bfdf44
Signed-off-by: Mark Mendell <mark.p.mendell@intel.com>
10 years agoMerge "Fix GetFreeMemory to use fooprint limit instead of max memory."
Mathieu Chartier [Mon, 9 Jun 2014 20:54:50 +0000 (20:54 +0000)]
Merge "Fix GetFreeMemory to use fooprint limit instead of max memory."

10 years agoFix GetFreeMemory to use fooprint limit instead of max memory.
Mathieu Chartier [Mon, 9 Jun 2014 20:25:22 +0000 (13:25 -0700)]
Fix GetFreeMemory to use fooprint limit instead of max memory.

Based on definitions in:
http://developer.android.com/reference/java/lang/Runtime.html

Bug: 15507122
Change-Id: I02f34682d7ac2d379a07631b5207b6cfb224da6b

10 years agoFix output of 107 art/test
Dmitry Petrochenko [Mon, 9 Jun 2014 19:45:42 +0000 (02:45 +0700)]
Fix output of 107 art/test

This patch affects 107 only when it is failed.

Change-Id: Ic33e6088d3fa4ca2cf47997f2bd6615462fc13cd
Signed-off-by: Dmitry Petrochenko <dmitry.petrochenko@intel.com>
10 years agox86_64: Reduce dex2oat compilation logs
Dmitry Petrochenko [Fri, 6 Jun 2014 08:18:14 +0000 (15:18 +0700)]
x86_64: Reduce dex2oat compilation logs

Disable printing of all compiled methods to logcat.

Change-Id: Ie210809f2595cc25da688a4ad0363c258bcf9233
Signed-off-by: Dmitry Petrochenko <dmitry.petrochenko@intel.com>
10 years agoX86_64: Fix core.oat compilation issues
Mark Mendell [Mon, 9 Jun 2014 16:49:55 +0000 (12:49 -0400)]
X86_64: Fix core.oat compilation issues

Fix neg-long and X86Mir2Lir::GenInstanceofFinal

Change-Id: I7fbcc1a89857cc461f74b55573ac6cb7c8e64561
Signed-off-by: Mark Mendell <mark.p.mendell@intel.com>
10 years agoMerge "AArch64: Fix kOpLsl, rem-float/double."
Bill Buzbee [Mon, 9 Jun 2014 16:29:12 +0000 (16:29 +0000)]
Merge "AArch64: Fix kOpLsl, rem-float/double."

10 years agoAArch64: fix and enable sparse- and packed-switch.
Matteo Franchin [Thu, 5 Jun 2014 14:10:35 +0000 (15:10 +0100)]
AArch64: fix and enable sparse- and packed-switch.

Changed implementation of sparse- and packed-switch to use w and x
registers appropriately. Also added a couple of utilities to obtain a
w/s register corresponding to a given x/d register and viceversa.

Change-Id: I485a110f6e91b09227d9e2a0b8b14224a10bca90

10 years agoAdd a type propagation phase after building SSA.
Nicolas Geoffray [Mon, 9 Jun 2014 13:06:02 +0000 (14:06 +0100)]
Add a type propagation phase after building SSA.

This ensures all phis have a type.

Change-Id: I7e4f9a16d1efb5f64c493c1351749b352c870cbd

10 years agoMerge "Avoid a memory allocation in OatFile::GetOatDexFile()."
Vladimir Marko [Mon, 9 Jun 2014 09:16:36 +0000 (09:16 +0000)]
Merge "Avoid a memory allocation in OatFile::GetOatDexFile()."

10 years agoAArch64: Fix kOpLsl, rem-float/double.
Zheng Xu [Mon, 9 Jun 2014 03:05:31 +0000 (11:05 +0800)]
AArch64: Fix kOpLsl, rem-float/double.

Change-Id: I6f7293493c0f94f96882d2e559e3eef659a23aec

10 years agoMerge "Fix some bugs in graph construction/simplification methods."
Nicolas Geoffray [Mon, 9 Jun 2014 08:00:05 +0000 (08:00 +0000)]
Merge "Fix some bugs in graph construction/simplification methods."

10 years agoFix some bugs in graph construction/simplification methods.
Nicolas Geoffray [Fri, 6 Jun 2014 10:24:33 +0000 (11:24 +0100)]
Fix some bugs in graph construction/simplification methods.

Also fix a brano during SSA construction. The code should
not have been commented out. Added a test to cover what the code
intends.

Change-Id: Ia00ae79dcf75eb0d412f07649d73e7f94dbfb6f0

10 years agoMerge "Add Move with Sign Extend Double to disassembler"
Ian Rogers [Mon, 9 Jun 2014 05:28:30 +0000 (05:28 +0000)]
Merge "Add Move with Sign Extend Double to disassembler"

10 years agoAdd Move with Sign Extend Double to disassembler
Mark Mendell [Fri, 6 Jun 2014 19:19:45 +0000 (15:19 -0400)]
Add Move with Sign Extend Double to disassembler

I noticed another missing instruction.

Change-Id: I71170496b014ac2609116eff2aeb13a13e71e263
Signed-off-by: Mark Mendell <mark.p.mendell@intel.com>
10 years agoMerge "ART: Fix inline assembly constraints in stub_test"
Ian Rogers [Mon, 9 Jun 2014 04:19:55 +0000 (04:19 +0000)]
Merge "ART: Fix inline assembly constraints in stub_test"

10 years agoMerge "ART: Fix casts in atomic.h to please GCC"
Ian Rogers [Mon, 9 Jun 2014 04:15:07 +0000 (04:15 +0000)]
Merge "ART: Fix casts in atomic.h to please GCC"

10 years agoMerge "x86_64: Add long bytecode supports (2/2)"
Bill Buzbee [Sat, 7 Jun 2014 19:50:43 +0000 (19:50 +0000)]
Merge "x86_64: Add long bytecode supports (2/2)"

10 years agox86_64: Add long bytecode supports (2/2)
Chao-ying Fu [Sat, 7 Jun 2014 01:38:49 +0000 (18:38 -0700)]
x86_64: Add long bytecode supports (2/2)

This patch adds implementation of math and complex long bytcodes,
and basic long arithmetic.

Change-Id: I811397d7e0ee8ad0d12b23d32ba58314d479d714
Signed-off-by: Chao-ying Fu <chao-ying.fu@intel.com>
Signed-off-by: Serguei Katkov <serguei.i.katkov@intel.com>
Signed-off-by: Dmitry Petrochenko <dmitry.petrochenko@intel.com>
Signed-off-by: Mark Mendell <mark.p.mendell@intel.com>
10 years agoMerge "x86_64: Add long bytecode supports (1/2)"
Bill Buzbee [Sat, 7 Jun 2014 19:12:08 +0000 (19:12 +0000)]
Merge "x86_64: Add long bytecode supports (1/2)"

10 years agox86_64: Add long bytecode supports (1/2)
Chao-ying Fu [Sat, 7 Jun 2014 00:32:37 +0000 (17:32 -0700)]
x86_64: Add long bytecode supports (1/2)

This patch includes switch enabling and GenFillArray,
assembler changes, updates of regalloc behavior for 64-bit,
usage in basic utility operations, loading constants,
and update for memory operations.

Change-Id: I6d8aa35a75c5fd01d69c38a770c3398d0188cc8a
Signed-off-by: Chao-ying Fu <chao-ying.fu@intel.com>
Signed-off-by: Serguei Katkov <serguei.i.katkov@intel.com>
Signed-off-by: Dmitry Petrochenko <dmitry.petrochenko@intel.com>
Signed-off-by: Mark Mendell <mark.p.mendell@intel.com>
10 years agoMerge "x86_64: Hard Float ABI support in QCG"
Bill Buzbee [Sat, 7 Jun 2014 18:28:59 +0000 (18:28 +0000)]
Merge "x86_64: Hard Float ABI support in QCG"

10 years agoART: Fix inline assembly constraints in stub_test
Andreas Gampe [Sat, 7 Jun 2014 08:32:33 +0000 (01:32 -0700)]
ART: Fix inline assembly constraints in stub_test

GCC 4.9 is the first compiler actually using the (incorrect)
absence of the memory clobber constraint to elide some stores
and reloads to the thread, leaving garbage in there on exit
of the invoke method when the called stub will reach C code
with FinishCalleeSaveFrame.

Change-Id: I3afe9926bf537e6e92e3ad44eb6541776ac0e75f

10 years agoART: Fix casts in atomic.h to please GCC
Andreas Gampe [Sat, 7 Jun 2014 04:27:01 +0000 (21:27 -0700)]
ART: Fix casts in atomic.h to please GCC

GCC 4.9 for ARM64 is not happy about reinterpret_cast-ing between
int64_t and uint64_t, which is according to spec. Change the
concrete casts to static_cast.

However, we also use this for pointers, and we cannot static_cast
those to int64_t. So add a reinterpret_cast to uintptr_t.

Change-Id: If6513fbcbb8ee8f610f172310af61cf2e9ab0c43

10 years agoMerge "Don't assert int64_t alignment on x86."
Hans Boehm [Sat, 7 Jun 2014 01:41:29 +0000 (01:41 +0000)]
Merge "Don't assert int64_t alignment on x86."

10 years agoMerge "Add missing initializtaion of last_gc_time_ns_."
Mathieu Chartier [Sat, 7 Jun 2014 01:41:18 +0000 (01:41 +0000)]
Merge "Add missing initializtaion of last_gc_time_ns_."

10 years agoDon't assert int64_t alignment on x86.
Hans Boehm [Sat, 7 Jun 2014 01:17:43 +0000 (18:17 -0700)]
Don't assert int64_t alignment on x86.

Fix build.

Change-Id: I1b798bb3c5ab4954b46d54cda8f8c237ab4ae53e

10 years agox86_64: Hard Float ABI support in QCG
Dmitry Petrochenko [Fri, 16 May 2014 18:02:18 +0000 (01:02 +0700)]
x86_64: Hard Float ABI support in QCG

This patch shows our efforts on resolving the ART limitations:
 - passing "float"/"double" arguments via FPR
 - passing "long" arguments via single GPR, not pair
 - passing more than 3 agruments via GPR.

Work done:
 - Extended SpecialTargetRegister enum with kARG4, kARG5, fARG4..fARG7.
 - Created initial LoadArgRegs/GenDalvikX/FlushIns version in X86Mir2Lir.
 - Unlimited number of long/double/float arguments support
 - Refactored (v2)

Change-Id: I5deadd320b4341d5b2f50ba6fa4a98031abc3902
Signed-off-by: Serguei Katkov <serguei.i.katkov@intel.com>
Signed-off-by: Dmitry Petrochenko <dmitry.petrochenko@intel.com>
Signed-off-by: Chao-ying Fu <chao-ying.fu@intel.com>
Signed-off-by: Mark Mendell <mark.p.mendell@intel.com>
10 years agoAdd missing initializtaion of last_gc_time_ns_.
Mathieu Chartier [Sat, 7 Jun 2014 00:51:16 +0000 (17:51 -0700)]
Add missing initializtaion of last_gc_time_ns_.

Fixes some valgrind warnings.

Bug: 15426766
Change-Id: Ibaa78465739bf6919509cf87c72b25c84ed1d12c

10 years agoMerge "Fix white space issues and long long use in assertion."
Hans Boehm [Sat, 7 Jun 2014 00:21:19 +0000 (00:21 +0000)]
Merge "Fix white space issues and long long use in assertion."

10 years agoMerge "Fix mismatched new[] delete in verifier."
Mathieu Chartier [Sat, 7 Jun 2014 00:19:05 +0000 (00:19 +0000)]
Merge "Fix mismatched new[] delete in verifier."

10 years agoFix white space issues and long long use in assertion.
Hans Boehm [Sat, 7 Jun 2014 00:13:03 +0000 (17:13 -0700)]
Fix white space issues and long long use in assertion.

Fix Build.

Change-Id: If67a910ffed25c03c46638d6c132dc0e3a20ef62

10 years agoFix mismatched new[] delete in verifier.
Mathieu Chartier [Fri, 6 Jun 2014 20:59:39 +0000 (13:59 -0700)]
Fix mismatched new[] delete in verifier.

Done in order to please valgrind.

Bug: 15432385
Change-Id: Iebb6fe50eb71fc7f4c2f8e7aa93ad6ab226be5a8

10 years agoMerge "Clean up and augment Atomic class. Replace QuasiAtomic MemBars."
Hans Boehm [Fri, 6 Jun 2014 23:45:51 +0000 (23:45 +0000)]
Merge "Clean up and augment Atomic class.  Replace QuasiAtomic MemBars."

10 years agoMerge "Change FieldHelper to use a handle."
Mathieu Chartier [Fri, 6 Jun 2014 23:37:27 +0000 (23:37 +0000)]
Merge "Change FieldHelper to use a handle."

10 years agoMerge "Reduce header files including header files."
Ian Rogers [Fri, 6 Jun 2014 23:37:16 +0000 (23:37 +0000)]
Merge "Reduce header files including header files."

10 years agoReduce header files including header files.
Ian Rogers [Fri, 6 Jun 2014 22:58:22 +0000 (15:58 -0700)]
Reduce header files including header files.

Main focus is getting heap.h out of runtime.h.

Change-Id: I8d13dce8512816db2820a27b24f5866cc871a04b

10 years agoClean up and augment Atomic class. Replace QuasiAtomic MemBars.
Hans Boehm [Thu, 22 May 2014 00:46:23 +0000 (17:46 -0700)]
Clean up and augment Atomic class.  Replace QuasiAtomic MemBars.

Add a number of missing C++11 operations to Atomic class.
Invoke the 64 bit routines in QuasiAtomic when necessary.
Replace QuasiAtomic membars with fences that correspond to C++11 fences.

QuasiAtomic was moved to the top of the file.  Only fence implementations
actually changed.

This replaces some buggy uses of MembarStoreStore, as reported
in b/14685856 .

Avoid some redundant fences for long volatile operations.

Incompletely converts low-level memory access operations to Atomic.

Change-Id: Iea828431a0cea46540eb74fcaa02071cab6fdcda

10 years agoMerge "x86_64: Fix stubs after 4-byte method handler"
Andreas Gampe [Fri, 6 Jun 2014 21:08:40 +0000 (21:08 +0000)]
Merge "x86_64: Fix stubs after 4-byte method handler"

10 years agox86_64: Fix stubs after 4-byte method handler
Serguei Katkov [Fri, 6 Jun 2014 17:50:37 +0000 (10:50 -0700)]
x86_64: Fix stubs after 4-byte method handler

It is 4 byte now and should be handled accordingly.

Change-Id: Ie373235f961eabfd33266bd89fbf8169a3714a03
Signed-off-by: Serguei Katkov <serguei.i.katkov@intel.com>
10 years agoChange FieldHelper to use a handle.
Mathieu Chartier [Fri, 6 Jun 2014 00:42:53 +0000 (17:42 -0700)]
Change FieldHelper to use a handle.

Fixed compaction bugs related to FieldHelper::GetType in:
artSet32InstanceFromCode
SetFieldValueImpl
CheckReceiver
Field_set
interpreter::DoFieldPut
MethodVerifier::VerifyISGet
MethodVerifier::VerifyISPut
MethodVerifier::VerifyIGetQuick

Bug: 13077697

Change-Id: I7de9ded2893b5568d43e4daa86fd135bf5508b72

10 years agoMerge "Fix top K percentage computation when loading profile data."
Calin Juravle [Fri, 6 Jun 2014 15:02:08 +0000 (15:02 +0000)]
Merge "Fix top K percentage computation when loading profile data."

10 years agoFix top K percentage computation when loading profile data.
Calin Juravle [Fri, 6 Jun 2014 11:24:21 +0000 (12:24 +0100)]
Fix top K percentage computation when loading profile data.

Don't count boot and null methods when computing top K percentage for
sampled methods.

Bug: 15462067
Bug: 12877748
Change-Id: I11c2ea541066a15bc8a5ad323e21ccbfdf81c2c5

10 years agoMerge "Use ScopedArenaVector instead of std::vector in SSA transformation."
Vladimir Marko [Fri, 6 Jun 2014 11:24:31 +0000 (11:24 +0000)]
Merge "Use ScopedArenaVector instead of std::vector in SSA transformation."

10 years agoMerge "Fixed and refactored profiler options handling"
Calin Juravle [Fri, 6 Jun 2014 11:15:25 +0000 (11:15 +0000)]
Merge "Fixed and refactored profiler options handling"

10 years agoFixed and refactored profiler options handling
Calin Juravle [Fri, 30 May 2014 22:44:11 +0000 (23:44 +0100)]
Fixed and refactored profiler options handling

- extracted profiler options in a separate class
- switched from system property reading to command line arguments
- added profile based compilation options to CompilerOptions
- removed no longer used kProfile compilation filter
- optimize dex files only if the profiler is enabled
- clean up unused arguments

Bug: 12877748
Bug: 15275634
Change-Id: I37ff68e7694370950ce8db2360562e9058ecebb7

10 years agoMerge "Clean up the sampling profiler"
Calin Juravle [Fri, 6 Jun 2014 10:58:10 +0000 (10:58 +0000)]
Merge "Clean up the sampling profiler"

10 years agoClean up the sampling profiler
Calin Juravle [Fri, 23 May 2014 16:33:29 +0000 (17:33 +0100)]
Clean up the sampling profiler

- rename variables/fields names to match the code style (use
_underscore_names_)
- extract common property parsing in utils.cc
- fail to load profile file if any line is malformed
- added ProfileFile to manage the profile data generate in the previous
runs (replaces ProfileHelper and nests ProfileData)

Bug: 12877748
Change-Id: Ie7bda30bfdeb7e78534c986615b0649eac12a97b

10 years agoUse ScopedArenaVector instead of std::vector in SSA transformation.
Vladimir Marko [Thu, 5 Jun 2014 19:09:47 +0000 (20:09 +0100)]
Use ScopedArenaVector instead of std::vector in SSA transformation.

Change-Id: Ibf8471274f2d5e11fcc185044745434c3c82ed74

10 years agoMerge "Fix crash in JDWP ReferenceType.SourceFile command"
Sebastien Hertz [Fri, 6 Jun 2014 07:02:39 +0000 (07:02 +0000)]
Merge "Fix crash in JDWP ReferenceType.SourceFile command"

10 years agoMerge "Add an optimization for removing redundant suspend tests in ART"
Bill Buzbee [Thu, 5 Jun 2014 22:34:57 +0000 (22:34 +0000)]
Merge "Add an optimization for removing redundant suspend tests in ART"

10 years agoAdd an optimization for removing redundant suspend tests in ART
Wei Jin [Fri, 30 May 2014 01:04:29 +0000 (18:04 -0700)]
Add an optimization for removing redundant suspend tests in ART

This CL:
(1) eliminates redundant suspend checks (dominated by another check),

(2) removes the special treatment of the R4 register, which got
reset on every native call, possibly yielding long execution
sequences without any suspend checks, and

(3) fixes the absence of suspend checks in leaf methods.

(2) and (3) increase the frequency of suspend checks, which improves
the performance of GC and the accuracy of profile data.  To
compensate for the increased number of checks, we implemented an
optimization that leverages dominance information to remove
redundant suspend checks on back edges.  Based on the results of
running the Caffeine benchmark on Nexus 7, the patch performs
roughly 30% more useful suspend checks, spreading them much more
evenly along the execution trace, while incurring less than 1%
overhead.  For flexibility consideration, this CL defines two flags
to control the enabling of optimizations.  The original
implementation is the default.

Change-Id: I31e81a5b3c53030444dbe0434157274c9ab8640f
Signed-off-by: Wei Jin <wejin@google.com>
10 years agoMerge "Disable thumb assembler test to fix art build"
Dave Allison [Thu, 5 Jun 2014 22:01:16 +0000 (22:01 +0000)]
Merge "Disable thumb assembler test to fix art build"

10 years agoDisable thumb assembler test to fix art build
Dave Allison [Thu, 5 Jun 2014 21:44:13 +0000 (14:44 -0700)]
Disable thumb assembler test to fix art build

Having difficulty getting this to run on the build server.
Disable until I can figure out how to do it.

Change-Id: I4f356fd1168b213b770426adc34bf62b8fb56b8f

10 years agoMerge "Remove unused variable in assembler test."
Dave Allison [Thu, 5 Jun 2014 21:27:40 +0000 (21:27 +0000)]
Merge "Remove unused variable in assembler test."

10 years agoRemove unused variable in assembler test.
Dave Allison [Thu, 5 Jun 2014 21:16:30 +0000 (14:16 -0700)]
Remove unused variable in assembler test.

This is flagged as an error when building master, but not others...

Change-Id: Iaea5307b06d8e4fa1a9d1035905fc204eb98559a

10 years agoMerge "Fix assembler test to use path if it can't find tools."
Dave Allison [Thu, 5 Jun 2014 21:05:59 +0000 (21:05 +0000)]
Merge "Fix assembler test to use path if it can't find tools."

10 years agoFix assembler test to use path if it can't find tools.
Dave Allison [Thu, 5 Jun 2014 20:58:56 +0000 (13:58 -0700)]
Fix assembler test to use path if it can't find tools.

This fixes build breakage.

Change-Id: I8074d47f1c1470cf886d517e9e68a6a6b4330485

10 years agoMerge "Thumb2 assembler for JNI compiler and optimizing compiler"
Dave Allison [Thu, 5 Jun 2014 19:47:18 +0000 (19:47 +0000)]
Merge "Thumb2 assembler for JNI compiler and optimizing compiler"

10 years agoThumb2 assembler for JNI compiler and optimizing compiler
Dave Allison [Mon, 28 Apr 2014 20:45:27 +0000 (13:45 -0700)]
Thumb2 assembler for JNI compiler and optimizing compiler

This provides a programmatic assembler for the thumb2 instruction set for
ARM.  The interface is the same as the ARM assembler and the ARM assembler has
been moved into Arm32Assembler.  The assembler handles most 16 and 32 bit instructions
and also allows relocations due to branch expansion.  It will also rewrite cbz/cbnz
instructions if they go out of range.

It also changes the JNI compiler to use the thumb2 assembler as opposed
to forcing it to use ARM32.  The trampoline compiler still uses ARM due to the
way it returns the address of its generated code.  A trampoline in thumb2 is the
same size as that in ARM anyway (8 bytes).

Provides gtest for testing the thumb2 instruction output.  This gtest only runs
on the host as it uses arm-eabi-objdump to disassemble the generated code.  On the
target the output is not checked but the assembler will still be run to perform
all its checks.

Change-Id: Icd9742b6f13541bec5b23097896727392e3a6fb6

10 years agoMerge "Verify there's no mem map gap for immune region not to break."
Hiroshi Yamauchi [Thu, 5 Jun 2014 18:48:54 +0000 (18:48 +0000)]
Merge "Verify there's no mem map gap for immune region not to break."

10 years agoAvoid a memory allocation in OatFile::GetOatDexFile().
Vladimir Marko [Thu, 5 Jun 2014 17:36:42 +0000 (18:36 +0100)]
Avoid a memory allocation in OatFile::GetOatDexFile().

Use StringPiece instead of std::string as the map key.

Change-Id: I05516d273de617a7d714e39ce6c4236cec6a09f7

10 years agoMerge "Workaround for running out of address space on N7v1."
Vladimir Marko [Thu, 5 Jun 2014 16:46:02 +0000 (16:46 +0000)]
Merge "Workaround for running out of address space on N7v1."

10 years agoWorkaround for running out of address space on N7v1.
Vladimir Marko [Thu, 5 Jun 2014 14:48:04 +0000 (15:48 +0100)]
Workaround for running out of address space on N7v1.

Bug: 13564922
Change-Id: I2ac466f613e465691078c41b2693f2327d07a0a8

10 years agoMerge "Use std::enable_if instead of a custom helper class."
Vladimir Marko [Thu, 5 Jun 2014 16:14:28 +0000 (16:14 +0000)]
Merge "Use std::enable_if instead of a custom helper class."

10 years agoMerge "Fix X86 disassambler printing of XMM, MM registers"
Ian Rogers [Thu, 5 Jun 2014 15:53:47 +0000 (15:53 +0000)]
Merge "Fix X86 disassambler printing of XMM, MM registers"

10 years agoUse std::enable_if instead of a custom helper class.
Vladimir Marko [Thu, 5 Jun 2014 15:35:31 +0000 (16:35 +0100)]
Use std::enable_if instead of a custom helper class.

Change-Id: Iffa0f0350ccc4fce698b9a16aefd340e16654076

10 years agoMerge "x86_64: Turn on 64-bit core registers initialization."
Bill Buzbee [Thu, 5 Jun 2014 15:08:53 +0000 (15:08 +0000)]
Merge "x86_64: Turn on 64-bit core registers initialization."

10 years agox86_64: Turn on 64-bit core registers initialization.
Dmitry Petrochenko [Thu, 5 Jun 2014 14:15:08 +0000 (21:15 +0700)]
x86_64: Turn on 64-bit core registers initialization.

This enables 64-bit core registers initialization for x86_64.
The backend update with 64-bit temp support is in progress.

Change-Id: If7c9a62c1145f81050adda86f2beed427220baa2
Signed-off-by: Chao-ying Fu <chao-ying.fu@intel.com>
Signed-off-by: Dmitry Petrochenko <dmitry.petrochenko@intel.com>
Signed-off-by: Serguei Katkov <serguei.i.katkov@intel.com>
Signed-off-by: Mark Mendell <mark.p.mendell@intel.com>
10 years agoFix X86 disassambler printing of XMM, MM registers
Mark Mendell [Thu, 5 Jun 2014 01:20:00 +0000 (21:20 -0400)]
Fix X86 disassambler printing of XMM, MM registers

Printing of uint8_t is done as a char, rather than an integer.

Change-Id: I996e7d7dd902695be6366ab816fea65b675c2ad9
Signed-off-by: Mark Mendell <mark.p.mendell@intel.com>
10 years agoMerge "Avoid register pool allocations on the heap."
Vladimir Marko [Thu, 5 Jun 2014 12:16:01 +0000 (12:16 +0000)]
Merge "Avoid register pool allocations on the heap."

10 years agoAvoid register pool allocations on the heap.
Vladimir Marko [Thu, 5 Jun 2014 09:57:05 +0000 (10:57 +0100)]
Avoid register pool allocations on the heap.

Create a helper template class ArrayRef and use it instead
of std::vector<> for register pools in target_<arch>.cc to
avoid these heap allocations during program startup.

Change-Id: I4ab0205af9c1d28a239c0a105fcdc60ba800a70a

10 years agoFix crash in JDWP ReferenceType.SourceFile command
Sebastien Hertz [Thu, 5 Jun 2014 08:15:45 +0000 (10:15 +0200)]
Fix crash in JDWP ReferenceType.SourceFile command

Updates Dbg::GetSourceFile to return ABSENT_INFORMATION error code when
Class::GetSourceFile returns nullptr. This happens if the class has no source
file information.

Updates Class:GetSourceFile to return nullptr for classes which have no
ClassDef item like generated classes. This allows to remove the IsProxyClass
test from Dbg::GetSourceFile. Adds this test in proxy_test.

Bug: 15426710
Change-Id: I019da4ced83778d5264484c43b225f8b5c95632e

10 years agoMerge "ART: Add a test checking TLS offsets and entrypoints"
Andreas Gampe [Thu, 5 Jun 2014 07:11:39 +0000 (07:11 +0000)]
Merge "ART: Add a test checking TLS offsets and entrypoints"

10 years agoMerge "Fix reflection_test failures."
Ian Rogers [Thu, 5 Jun 2014 06:23:08 +0000 (06:23 +0000)]
Merge "Fix reflection_test failures."

10 years agoMerge "ART: Allocate ostreams on the heap in Oatdump::DumpOatMethod"
Andreas Gampe [Thu, 5 Jun 2014 06:09:46 +0000 (06:09 +0000)]
Merge "ART: Allocate ostreams on the heap in Oatdump::DumpOatMethod"

10 years agoART: Allocate ostreams on the heap in Oatdump::DumpOatMethod
Andreas Gampe [Thu, 5 Jun 2014 05:42:28 +0000 (22:42 -0700)]
ART: Allocate ostreams on the heap in Oatdump::DumpOatMethod

The stack frame size for this method is above our limits. Allocate
ostreams on the heap instead of on the stack.

Bug: 15278350
Change-Id: Ia94a1f7190b7c2ac096e100682e747334f1bf6cc

10 years agoMerge "Do not force unwind info to debug_frame."
Christopher Ferris [Thu, 5 Jun 2014 03:24:08 +0000 (03:24 +0000)]
Merge "Do not force unwind info to debug_frame."

10 years agoART: Add a test checking TLS offsets and entrypoints
Andreas Gampe [Thu, 5 Jun 2014 01:59:01 +0000 (18:59 -0700)]
ART: Add a test checking TLS offsets and entrypoints

Add a test (runtime for now, as compile-time checks seem not
possible with current infrastructure) that checks the structure
of the thread tls and entrypoint structs. A failure of the test
indicates a structural change, which hints at a necessary oat
version bump.

Change-Id: I500b5cd940c916ebfc1580e9dd2c287c4d263956

10 years agoDo not force unwind info to debug_frame.
Christopher Ferris [Thu, 5 Jun 2014 00:21:11 +0000 (17:21 -0700)]
Do not force unwind info to debug_frame.

The .cfi_sections directive was forcing unwind information into the
debug_frame, which is stripped out. This causes any unwinds done by
libunwind/debuggerd through these art functions to terminate prematurely.

Bug: 15350524
Change-Id: Id6abe7c7106132083bc894a77564b652a08566cb

10 years agoMerge "Fix GetOutVROffset to use correct Method* size."
buzbee [Wed, 4 Jun 2014 23:02:08 +0000 (23:02 +0000)]
Merge "Fix GetOutVROffset to use correct Method* size."

10 years agoFix GetOutVROffset to use correct Method* size.
buzbee [Wed, 4 Jun 2014 22:35:41 +0000 (15:35 -0700)]
Fix GetOutVROffset to use correct Method* size.

[Tip 'o the hat to Mark Mendell for noticing this one]

Use StackReference to find Method* size in GetOutVROffset.

Change-Id: Ie1b25eb839c59305cadc5fdc7cbb5f41f1a85686

10 years agoMerge "Enable -Wframe-larger-than=1728 compilation error"
Andreas Gampe [Wed, 4 Jun 2014 22:57:01 +0000 (22:57 +0000)]
Merge "Enable -Wframe-larger-than=1728 compilation error"

10 years agoEnable -Wframe-larger-than=1728 compilation error
Sebastien Hertz [Tue, 27 May 2014 13:27:58 +0000 (15:27 +0200)]
Enable -Wframe-larger-than=1728 compilation error

Bug: 15278350
Change-Id: I142dc9de0312ac1f8aa55a4bce86b5bb6722535f

10 years agoVerify there's no mem map gap for immune region not to break.
Hiroshi Yamauchi [Wed, 4 Jun 2014 18:43:59 +0000 (11:43 -0700)]
Verify there's no mem map gap for immune region not to break.

This adds code that verifies that there's no memory map gap between
the image space and the main space so that the immune region
functionality won't silently break. For example, if there's a gap and
a large object is allocated in that gap, the large object is
incorrectly part of the immune region and the marking breaks.

Bug: 14059466
Change-Id: Ie6ed82988d74b6d0562ebbbaac96ee43c15b14a6