Age | Commit message (Collapse) | Author |
|
This should improve app startup as we can skip the target
method resolution on the first call. For `invoke-direct` we
should never go to the resolution trampoline for app image
methods and for `invoke-static` we go to the trampoline only
if the class is not yet visibly initialized and in that case
we still save time as the target method is already known.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing --speed-profile
Test: run-gtests.sh
Test: testrunner.py --target --optimizing --speed-profile
Bug: 38313278
Change-Id: I1fea5485264b433fe642c9d0092a5411813eb996
|
|
This reverts commit b63adc919ba9a53f4fbad476356c702845821149.
Bringing back map from ArtMethod to code pointers.
Bug: 297147201
Test: CtsPerfettoTestCases
Test: ./art/test/testrunner/testrunner.py --host --64 --jit -b
Test: ./art/test/testrunner/testrunner.py --host --64 --jit --cms -b
Test: ./art/test/testrunner/testrunner.py --host --64 -b
Test: ./art/test.py --host -b
Change-Id: I6a1c50598ec878393edf8ef895274da79d4ab42d
|
|
This reverts commit d92a43f4310e2d634d6e8f24103fc1e27557d784.
Reason for revert: Failing 979-const-method-handle
https://ci.chromium.org/ui/p/art/builders/ci/host-x86_64-cms/10095/overview
Change-Id: I9b44d8cc66e98db074edfa90ce2ebab087e4b115
|
|
This reverts commit 69c9ea4f93a688ff50e08060be37bcfd3f3e9910.
Instead of storing reversed method_code_map_, now just keep
MethodType-s associated with a compiled code.
Increasing constant in 979/Main.java to trigger jit more reliably.
Bug: 297147201
Test: CtsPerfettoTestCases
Test: ./art/test/testrunner/testrunner.py --host --64 --jit -b
Test: ./art/test/testrunner/testrunner.py --host --64 -b
Test: ./art/test.py --host -b
Change-Id: I5ece80b63cd0d6dac2805c94649726dc62fe85db
|
|
Add app image relocations for classes in the app image,
similar to the existing relocations for boot image. This new
load kind lets the compiled code avoid the null check and
slow path.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing --speed-profile
Test: run-test.sh
Test: testrunner.py --target --optimizing --speed-profile
Bug: 38313278
Change-Id: Iffd76fe9ac6b95c37c2781fd6257e1d5cd0790d0
|
|
Treat app image objects similar to boot image objects and
avoid unnecessary read barriers for app image `HLoadClass`
and `HInstanceOf` checks with app image `HLoadClass` input.
Extend other optimizations to treat app image classes the
same way as boot image classes even though this remains
mostly dormant because we currently do not initialize app
image classes with class initializers; the experimental
flag `--initialize-app-image-classes` is false by default.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing --speed-profile
Bug: 38313278
Change-Id: I359dd8897f6d128213602f5731d40edace298ab8
|
|
Prepare for adding app image patches to the same section.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Bug: 38313278
Change-Id: Ib552f005b3a2859152d0de9fa6b2fcd48a0f3feb
|
|
This reverts commit 53ca944020bb86199f6f80d8594d5deb1b1d46dd.
Bug: 297147201
Reason for revert: Crash on bot
Change-Id: Ibf3b53a8fe67aa633686990881a96acb783af9a3
|
|
The `*ByIdx()` and `*ByTypeIdx()` functions were doing
validity checks that were needed only for processing the
debug data, so move the checks to these callers. Replace
these functions with new overloads of other functions to
provide consistent naming.
In a few cases, rewrite calls to these functions to fetch
and work with a `string_view` instead.
Rename `GetStringLength()` to `GetStringUtf16Length()` and
change its return type to `uint32_t`.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Change-Id: I561899606f6e5ec5f23aa4be617349dacdb376e3
|
|
In aosp/2876518 JIT code made runtime calls.
Bug: 297147201
Test: ./art/test/testrunner/testrunner.py --host --64 --jit -b
Test: ./art/test/testrunner/testrunner.py --host --64 -b
Test: ./art/test.py --host -b
Change-Id: Ifdfd3ace9419b34f8079c9ec4b1b2de31cb50ef7
|
|
It was the only enum in the file
Bug: 329378408
Test: art/test/testrunner/testrunner.py --host --64 --optimizing -b
Change-Id: If0e385324afa3685f648135ba9b60e6bc79ba0ed
|
|
Do not resolve primitive field types for iput*, sput*
before updating the interpreter cache.
Introduce and use `ArtMethod::IsStringConstructor(),
a convenience helper function where we avoid a read
barrier for checking if the declaring class is the
`String` class.
Change one `CHECK_LE()` to `DCHECK_LE()`.
Test: testrunner.py --host --interpreter
Change-Id: I17b0409cee5321e0ca389f053da1f767d2913d08
|
|
This reverts commit 0a51605ddd81635135463dab08b6f7c21b58ffb0.
Reason for revert: Reland after some of the required work
was merged in other CLs.
Also address a TODO from the original CL to mark required
symbols with EXPORT in `intrinsic_objects.h`.
Also mark symbols in new files as HIDDEN.
Bug: 186902856
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Change-Id: I936d448983928af23614ca82c2d0bf9a645e2c52
|
|
And use the field offset as seen at compile time.
Implemented for x86-64, arm and arm64 but not for x86
with incomplete set of `VarHandle` intrinsics.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Test: run-gtests.sh
Test: testrunner.py --target --optimizing
Bug: 191765508
Change-Id: If68b0287c8823e69c493dcefb7e61dc34d69fb4f
|
|
After b/214850438 we took a second look at the sharpening optimization.
While it seems doable, it is not straightforward. We are adding a
comment and a test to make sure we are not mistakenly enabling it.
Test: art/test/testrunner/testrunner.py --host --64 --optimizing -b
Bug: 214850438
Bug: 154012332
Change-Id: Ic619934cdd4cd322a31afce60b9becbfa4338e81
|
|
This reverts commit 2d62882195eb97358fb8a1fd147d52a36cd3c581.
Reason for revert: Native crashes due to out of date OatFile b/217369528
Change-Id: I7bf7d6decb24934b47d5a4b2cc2ce25906032f10
|
|
This CL extends the .bss metadata section to allow for BCP methods
to be inlined into other DexFiles, even when requiring a bss entry.
Test: ART tests, compiling and launching top 100 apps
Bug: 154012332
Change-Id: Ib541e69a9c52b3fad003d286a5b57060770e1395
|
|
This reverts commit 32b8c8f33ad68982357c1fa3d0f132d06b070ab5.
Bug: 154012332
Bug: 214850438
Reason for revert: b/214850438
Change-Id: I479c0910ce5da593e170bc5e4f6fa10dfe5d67b2
|
|
We can handle some extra cross-dex cases in order to expand the support.
Bug: 154012332
Test: ART tests
Change-Id: Ic3220d809086b4b3007bf5b6d63789ffb1b91fb9
|
|
This reverts commit f1d06474baa2f7c00761db39099b89ddab71bbe4.
Bug: 177554973
Bug: 112676029
Test: test.py
Test: 815-invokeinterface-default
Test: enable text-to-speech on device, no crash
Reason for revert: Fixed issue with recursive default methods
Change-Id: I2fb9336adb6c4fc920f39aa19bfe7f0a92ce059a
|
|
To avoid doing dex cache lookup, pass the interface method instead. This
costs a few hundred KBs on speed compiled APKs (< 0.5% code size), but
improves performance when hitting a conflict (as seen on dogfood data).
For nterp, we currently pass the conflict method instead of the
interface method. We need to handle default methods before optimizing
it.
This removes our last use of dex cache in compiled code. A follow-up CL
will remove the NeedsDexCacheOfDeclaringClass from HInvokeInterface.
Test: test.py
Change-Id: I3cdd4543ad7d904b3e81950af46a48a48af6991a
|
|
Add two new load kinds to LoadClass, similar to kBssEntry
but using the access-checking entrypoint on the slow-path.
One is used for classes that are in the literal package and
the other for classes outside the literal package of the
compiling class. Associate new .bss entries with these load
kinds and update them from entrypoints based on the resolved
class properties. If the resolved class is public, both
types of entries can be updated, otherwise only the package
local entry can be updated and only if the defining class
loader of the class is the same as the caller's defining
class loader (which is identical for all code in an oat
file) because the run time access check for same package
requires both class loader and literal package name match.
Test: Additional tests in 727-checker-unresolved-class.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Test: aosp_blueline-userdebug boots.
Test: run-gtests.sh
Test: testrunner.py --target --optimizing
Bug: 161898207
Change-Id: I281e06ac2825caf81c6d7ee3128af833abd39992
|
|
Otherwise, we can end up in a state where the method on the stack is
unrelated to the receiver.
Also fix a comment related to GetCanonicalMethod and
StackVisitor::ValidateFrame.
Test: 810-checker-invoke-super-default
Change-Id: I3030e4af6059f7a4a7a1f046f2aabae8ce9057da
|
|
To prepare for using it in HInvokeInterface. For consistency, also move
CodePtrLocation.
Test: test.py
Change-Id: I84f973764275002e2adb71080ebc833b2bafb975
|
|
Add support for calling super methods that are not referenced within the
compiling dex file.
Test: 808-checker-invoke-super
Test: 809-checker-invoke-super-bss
Change-Id: Ib103f818ac8b612a79b6b18cc8eda81131bb3149
|
|
Emit direct calls from compiled managed code to the native
code registered with the method, avoiding the JNI stub.
Golem results:
art-opt-cc x86 x86-64 arm arm64
NativeDowncallStaticCritical +12.5% +62.5% +75.9% +41.7%
NativeDowncallStaticCritical6 +55.6% +87.5% +72.1% +35.3%
art-opt x86 x86-64 arm arm64
NativeDowncallStaticCritical +28.6% +85.6% +76.4% +38.4%
NativeDowncallStaticCritical6 +44.6% +44.6% +74.6% +32.2%
Test: Covered by 178-app-image-native-method.
Test: m test-art-host-gtest
Test: testrunner.py --host --debuggable --ndebuggable \
--optimizing --jit --jit-on-first-use
Test: run-gtests.sh
Test: testrunner.py --target --optimizing
Test: testrunner.py --target --debuggable --ndebuggable \
--optimizing --jit --jit-on-first-use -t 178
Test: aosp_cf_x86_phone-userdebug boots.
Test: aosp_cf_x86_phone-userdebug/jitzygote boots.
Bug: 112189621
Change-Id: I8b37da51e8fe0b7bc513bb81b127fe0416068866
|
|
Let CompilerOptions hold the information whether it is AOT
or JIT compilation, or Zygote JIT for shared code.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing --jit
Test: aosp_taimen-userdebug boots.
Change-Id: Id9200572406f8e43d99b8b61ef0e3edf43b52fff
|
|
This reverts commit e2727154f25e0db9a5bb92af494d8e47b181dfcf.
Reason for revert: Breaks ASAN tests (ODR violation).
Bug: 142365358
Change-Id: I38103d74a1297256c81d90872b6902ff1e9ef7a4
|
|
Make symbols in compiler/optimizing hidden by a namespace
attribute. The unit intrinsic_objects.{h,cc} is excluded as
it is needed by dex2oat.
As the symbols are no longer exported, gtests are now linked
with the static version of the libartd-compiler library.
libart-compiler.so size:
- before:
arm: 2396152
arm64: 3345280
- after:
arm: 2016176 (-371KiB, -15.9%)
arm64: 2874480 (-460KiB, -14.1%)
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing --jit
Bug: 142365358
Change-Id: I1fb04a33351f53f00b389a1642e81a68e40912a8
|
|
Test: m test-art-host-gtest
Test: testrunnner.py --host --optimizing
Test: aosp_taimen-userdebug boots.
Test: run-gtest.sh
Test: testrunner.py --target --optimizing
Change-Id: I8e999c96ec908f26d8c529edc9d2a3be49a9379a
|
|
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Test: aosp_taimen-userdebug boots.
Change-Id: Ib7abd10e94e995e61549b3a3111a640802b5e700
|
|
Only encode classes/strings/methods that are in a boot image.
Bug: 119800099
Test: boot
Change-Id: I7ed8ce2ce876ad1c6c1678939cafe4808a67bef4
|
|
This reverts commit 2fef66b294417d447630f9d98de68227eef476d3.
Bug: 119800099
Bug: 136110523
Reason for revert: Fixed webview_zygote case.
Change-Id: Iaae8c999463d77b7b1e62b55458493bdbc97a104
|
|
This reverts commit 05f87217ddc9b4b9186710c0135b918f456c5aef.
Bug: 119800099
Bug: 136110523
Reason for revert: testWebview flaking
Change-Id: I96afa6bc9c56c4aaf5ed72ae370f6f69c096c559
|
|
Test: boots
Bug: 119800099
Change-Id: I75ff8a58eea4de5cb833139641b4e15b8394d9b1
|
|
... in inlined methods that are not in the boot profile.
If such string is not in the boot image for other reasons,
do not resolve the string and use the kBssEntry load kind.
Boot image sizes for aosp_taimen-userdebug:
- before:
arm/boot*.art: 12349440
arm/boot*.oat: 19862024
arm64/boot*.art: 16609280
arm64/boot*.oat: 23568592
- after:
arm/boot*.art: 12324864 (-24KiB)
arm/boot*.oat: 19936612 (+73KiB)
arm64/boot*.art: 16580608 (-28KiB)
arm64/boot*.oat: 23642120 (+72KiB)
Test: aosp_taimen-userdebug boots.
Test: m test-art-host-gtest
Bug: 26687569
Change-Id: I3e0b72cd5e8c67904517856208f25a6c379ab601
|
|
Compiled classes filtering is no longer a thing.
Bug: 26687569
Bug: 76145463
Test: test-art-host
Change-Id: Iaf4b9dcea5d9fe1eae564fbd6d373af2fdc87b14
|
|
Make the last sharpening helper (methods) like the other
helpers: being invoked by the instruction builder.
Test: test.py
Change-Id: Ic80a454f9b59b0b4ef7825590b24402500ba851c
|
|
Change sharpening to use PIC load kinds for AOT compilation
and add "Jit" to the direct addressing load kind names. Use
PIC code also for the Integer.valueOf() intrinsic codegen.
Remove all support for non-PIC linker patches.
The dex2oat --compile-pic option is retained for now but
ignored by the compiler.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Test: Pixel 2 XL boots.
Test: testrunner.py --target --optimizing
Bug: 77856493
Change-Id: I54d666f6522f160a1b6ece4045a15d19363acbb6
|
|
Check for non-PIC boot image as a testing config instead.
Honor the config for HInvokeStaticOrDirect sharpening.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Change-Id: I3645f4fefe322f1fd64ea88a2b41a35ceccea688
|
|
A step toward removing the CompilerDriver dependency from
several classes, including HSharpening and ImageWriter.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Change-Id: I364ef66511fdf855cb11b12c818a40572b037727
|
|
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Change-Id: Ifb30e071d7b39ae939fc3f83d7eba82fd077c7e8
|
|
Rationale:
The change adds a return value to Run() in preparation of
conditional pass execution. The value returned by Run() is
best effort, returning false means no optimizations were
applied or no useful information was obtained. I filled
in a few cases with more exact information, others
still just return true. In addition, it integrates inlining
as a regular pass, avoiding the ugly "break" into
optimizations1 and optimziations2.
Bug: b/78171933, b/74026074
Test: test-art-host,target
Change-Id: Ia39c5c83c01dcd79841e4b623917d61c754cf075
|
|
Disabled the build time flag. (No image version bump needed.)
Bug: 26687569
Bug: 64692057
Bug: 76420366
This reverts commit 3fbd3ad99fad077e5c760e7238bcd55b07d4c06e.
Change-Id: I5d83c4ce8a7331c435d5155ac6e0ce1c77d60004
|
|
This reverts commit 3f41323cc9da335e9aa4f3fbad90a86caa82ee4d.
Reason for revert: Fails sporadically.
Bug: 26687569
Bug: 64692057
Bug: 76420366
Change-Id: I84d1e9e46c58aeecf17591ff71fbac6a1e583909
|
|
Add extra output for debugging failures and re-enable
the bitstring type checks.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing --jit
Test: testrunner.py --host -t 670-bitstring-type-check
Test: Pixel 2 XL boots.
Test: testrunner.py --target --optimizing --jit
Test: testrunner.py --target -t 670-bitstring-type-check
Bug: 64692057
Bug: 26687569
This reverts commit bff7a52e2c6c9e988c3ed1f12a2da0fa5fd37cfb.
Change-Id: I090e241983f3ac6ed8394d842e17716087d169ac
|
|
For PIC AOT-compiled app, use the .data.bimg.rel.ro to load
the boot image String/Class references instead of using the
mmapped boot image ClassTable and InternTable.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing --pictest --npictest
Test: Pixel 2 XL boots.
Test: testrunner.py --target --optimizing --pictest --npictest
Bug: 71526895
Change-Id: Id5703229777aecb589a933a41f92e44d3ec02a3d
|
|
Introduce a new .data.bimg.rel.ro section in oat files where
we store offsets of boot image objects from the beginning of
the boot image. At runtime we relocate these entries using
the actual boot image address to turn offsets to pointers.
Use the .data.bimg.rel.ro to prepare the boot image methods
used by HInvokeStaticOrDirect for PIC AOT app compilation.
Loading the ArtMethod* from .data.bimg.rel.ro instead of the
.bss avoids the initial call to the resolution trampoline.
Test: Additional test in 522-checker-sharpening
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing --pictest --npictest
Test: Pixel 2 XL boots.
Test: testrunner.py --target --optimizing --pictest --npictest
Bug: 71526895
Change-Id: Ie5f5b1f622704877b36730377146e59092e46c0c
|
|
Bug: 64692057
Bug: 71853552
Bug: 26687569
This reverts commit eb0ebed72432b3c6b8c7b38f8937d7ba736f4567.
Change-Id: I7daeaa077960ba41b2ed42bc47f17501621be4be
|
|
Test failures:
http://build.chromium.org/p/client.art/builders/fugu-debug/builds/4875
01-25 02:05:28.357 23732 23732 F /data/local/tmp/system/bin/../bin/dalvikvm: quick_throw_entrypoints.cc:132] Check failed: !dest_type->IsAssignableFrom(src_type)
This reverts commit 718e8319c728e9ee2ec15b1d56ca96baa4393028.
Change-Id: I022f88cd81ae99143e5670ae29eae326ecc83cc2
|