| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
| |
Bug: 124338141
Test: Boot and observe no core platform api warnings from opengl
(cherry picked from commit f5480bdcdd27e492a9858599664c74e16a46a961)
Change-Id: I4680418398f0708c26c0124b418a2ccb1094a038
Merged-In: I6db85f6084dd620e08568dbdeea0d10efb20a84f
|
| |
|
|
|
|
| |
Test: in ART, two_runtimes_test.cc
Bug: 31550016
Change-Id: I33906c8d3911b696f311d8d2a58b9dab4f6ab5a1
|
| |
|
|
|
|
|
|
|
|
|
| |
Final resting place tbd (see b/122881655) but this gets
it out of libnativehelper.
Bug: 122881655
Test: m && flashall
Test: atest CtsLibcoreOkHttpTestCases:com.squareup.okhttp.CallTest
Change-Id: I23130154120f04284910bfded574e980bbf1b6ee
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This change puts a C ABI between the caller and libnativehelper which
means each could link separate libc++ library instances using
namespaces.
Bug: b/119840313
Test: Builds & boots
Test: atest JniInvocation_test
Test: atest libnativehelper_api_test
Change-Id: Idaa4ddd3118cbb4f3997abdcf355220ef80eb775
|
| |
|
|
|
|
|
|
| |
Assume at least C++11 support.
Bug: 119840313
Test: builds cleanly with WITH_TIDY=1 mma
Change-Id: I246efaa337d69b70280eec595ed80d75226ffbf5
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Removes the JniConstants from the libnativehelper API.
Most of the constants are moved into libcore.
Light tidying up in touched files.
Bug: 119840313
Test: atest libnativehelper/test
Test: atest CtsLibcoreTestCases
Test: art/test.py --host -g -j16
Test: device boots
Change-Id: I4c0daab450d2efd7e6bd7705e27dbb6309fcb92d
|
| |
|
|
|
|
|
|
| |
It's 2018. Everyone should be using std::unique_ptr now...
Bug: http://b/22403888
Test: builds
Change-Id: Ifb94f06e55666f8626cce9ed0d5bc137cedbf8de
|
| |
|
|
|
|
|
|
| |
It's 2018. Everyone should be using std::unique_ptr by now.
Bug: http://b/22403888
Test: builds
Change-Id: I90b74e375a1cfee4290ed9a000b4f3d36666a162
|
| |
|
|
|
|
|
|
|
| |
Add null checks to jniSetFileDescriptorOfFD and to its callers where
appropriate.
Bug: 111523523
Test: cts-tradefed run cts -m CtsLibcoreTestCases
Change-Id: Ic8a236b854d455cd51f379a80e15ee2080b6a400
|
| |
|
|
|
|
| |
Bug: http://b/110100358
Test: treehugger
Change-Id: Ic87c373eb099aa3d06c4e33e28d441fd66604966
|
| |
|
|
|
|
|
|
|
|
|
| |
Reinitializing system properties can result in crashes later in the
program, and is generally not recommended or even supported. Instead,
this change uses a very rudamentary approach to mocking out the system
property functions.
Bug: 62197783
Test: unit tests
Change-Id: I99c57e1d87490926e4839ee154c862ee8a199e26
|
| |
|
|
|
|
|
|
|
|
|
| |
These classes and fields are only used in libcore native code. Do
not expose them in JniConstants.
Bug: 68197265
Test: m
Test: m test-art-host
Test: vogar --mode=host libcore/luni/src/test/java/libcore/io/OsTest.java
Change-Id: I8a84fd0fa88e8174bea86a33bf58ad7eba392c82
|
| |
|
|
|
|
|
|
|
| |
Export a version of the nativehelper helpers that doesn't have
a dependency on the libnativehelper library. Instead, provide an
inline function for null throw.
Test: m
Change-Id: Idfab8809873d54db824c8bc089f003265fe5a9b9
|
| |\ |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
- setsockoptGroupSourceReq is dead code after removing
the corresponding socket options in Iobridge
Test: cts-tradefed run cts-dev --module CtsLibcoreTestCases
Test: cts-tradefed run cts-dev --module CtsLibcoreOjTestCases
Bug: 32071916
Change-Id: Ie1b8a40c77ee092b84eb80ccb3f8bde3cc01b73b
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Follow-up to commit 076bf283b9b988ee5c10d6543eb58318d95a5e8f.
Remove empty constructor, as it's dangerous to use. Remove null
assignment to mEnv as it's actually forbidden.
Runtime tests are introduced in a follow-up change.
Test: m
Test: manual
Change-Id: Ib8ad0e6b18eda57489b6ee4b325c50c360830fba
|
| | |
| |
| |
| |
| |
| |
| |
| | |
Move us into the future past, adding some C++11 goodness to
ScopedLocalRef that make it look more like unique_ptr.
Test: m
Change-Id: I793248da5a48e407bdea1a7fd83fcbc83b0a8f67
|
| |\ \
| | |
| | |
| | |
| | |
| | | |
am: cfdbad8210
Change-Id: I8e11679922ff102b6aacc604b71ca5fcebf3b51a
|
| | |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
include_deprecated contains all of the
headers that are currently used by libraries without
the "nativehelper/" prefix.
The current count of this is this:
2 ScopedLocalFrame.h
4 JniInvocation.h
4 ScopedBytes.h
5 AsynchronousCloseMonitor.h
6 toStringArray.h
7 ScopedStringChars.h
38 JniConstants.h
41 ScopedPrimitiveArray.h
79 ScopedUtfChars.h
80 UniquePtr.h
100 ScopedLocalRef.h
467 JNIHelp.h
Now we can remove each file from the global header include
on a file by file basis.
Bug: 63762847
Test: libraries still find their headers
Change-Id: I77f1dcff47389bcce55087fe18c46350992e4e06
|
| |\|
| |
| |
| |
| |
| | |
am: a22102d917
Change-Id: I66fdb72ebc6ae253948615cc85dfbeeec9cde0b5
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
In C++11, char16_t and uint16_t (which is what jchar is defined as) are
two distinct types, even though they are bitwise identical, so to not
require C++11 code using char16_t to always reinterpret_cast<uint16_t>
the argument passed to JNIEnv::NewString(), this new helper function is
overloaded to do the required cast when used in C++11.
Bug: 37554848
Test: make
Change-Id: I69632b0a7b822537cab77c43dc387d94917933b9
|
| |\|
| |
| |
| |
| |
| | |
am: faaa80e17c
Change-Id: Iac2b8ea8f224ab85234828082bc5addb0c89473f
|
| | |
| |
| |
| |
| |
| | |
Test: CtsLibcoreTestCases
Bug: 62949898
Change-Id: I9285d65ec106666b66565c17a18f7d45a18fc8e8
|
| |/
|
|
|
| |
Test: manual
Change-Id: Ibcac9b21328f5e0549075443005ac721451d9fac
|
| |
|
|
|
|
|
|
| |
* Add explicit keyword to conversion constructors.
Bug: 28341362
Test: build with WITH_TIDY=1
Change-Id: I5435bcf34e023ff49d87494accee913d1968f15d
|
| |
|
|
|
|
|
| |
Adds StructIfaddrs to JniConstants.
Bug: 28609551
Change-Id: I314524f69d1dedbea108a8066f1510f113669e55
|
| |\ |
|
| | |
| |
| |
| |
| | |
Bug: 29067535
Change-Id: Ie658014fc46e616015d85ba8cfac2a265ac11fef
|
| | |
| |
| |
| |
| |
| |
| | |
libnativehelper only uses ScopedPthreadMutexLock from libcore/include,
rewrite it with std::mutex and std::lock_guard instead.
Change-Id: I4eae9e77d21483ffb6b4aedcedcf8c7bb765294f
|
| |/
|
|
|
|
|
| |
Use <android-base/unique_fd.h> instead.
Bug: http://b/21192156
Change-Id: I29507cb69986fdd1dac49934b11bc3349e0dfbef
|
| |
|
|
|
|
| |
Bug: 28341362
Change-Id: I8e19914bdc20e734fd273e874d329d1c273db894
Test: build with clang-tidy
|
| |
|
|
|
|
|
|
|
| |
Replace T* and T& with POINTER_TYPE(T) and REFERENCE_TYPE(T)
in macros to avoid wrong clang-tidy warnings.
Use NOLINT to suppress warnings in POINTER_TYPE(T) and REFERENCE_TYPE(T).
Bug: 28705665
Change-Id: I4dc985b9050b47af020f0f3188a64a891ff88ac8
|
| |
|
|
|
|
|
| |
Remove unused class IDs preloaded in JniConstants.
Bug: 28831504
Change-Id: I845fbcda8117e03a11f90a72ca94f9b23ee56ba0
|
| |
|
|
|
| |
Bug: 27291269
Change-Id: Ia7db477a95527491245dbd774d6afe36f88c97c1
|
| |
|
|
|
|
|
|
|
|
|
| |
AsynchronousCloseMonitor is needed by both
libopenjdk and libjavacore.
Bug: 26127752
(cherry picked from commit 20d3848be7394fb9a4735b8b2148f994ff735d96)
Change-Id: I7d1d89d344180bb1e6bed2e0c83e4e7633122fe0
|
| |
|
|
|
|
| |
(cherry picked from commit 39a538702537bab23e21a41c934fdd7b772519e7)
Change-Id: I8ed14341ced9edaad723a38563efa543814de5af
|
| |
|
|
|
|
| |
(cherry picked from commit 830b9bef45a0f372d099fa81db34ade5cdddafb9)
Change-Id: Idd3637e8bc0d3c3dab3bb9dc6b4da83d915c02ac
|
| |
|
|
|
|
| |
(cherry picked from commit da7720ddf47e60f0b2a926d778b5c65bc91d1c03)
Change-Id: I84bb4ecb4e8e8dc06a3282fb123467530ed277e3
|
| |
|
|
|
|
|
|
|
| |
bidiRunClass and fieldPositionIteratorClass are no longer
necessary.
(cherry picked from commit 03e90fe122f95df27ca74a82bdf2fae343bef769)
Change-Id: I714f01fce1fb3b6917304dcf810730bcee2c03e3
|
| |
|
|
|
|
|
|
|
| |
The class is now final, and has move constructors and move assignment.
Change-Id: I5a87cd11dbf2581594919d37c08519302683f46c
Test: Full build of android completes successfully
Bug: 25242023
Signed-off-by: Casey Dahlin <sadmac@google.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For small arrays <= 1024 elements, we use GetArrayRegion with stack
allocated backing storage instead of GetArrayElements. The speedup
comes from the fact that GetArrayRegion doesn't need to allocate a
copy of array.
Timing results for:
https://android-review.googlesource.com/#/c/169727/
BEFORE
Host:
Byte length=1 ns/op=452.2633712
Short length=1 ns/op=468.6469192
Int length=1 ns/op=422.5663486
Long length=1 ns/op=423.4946638
Byte length=8 ns/op=424.8546962
Short length=8 ns/op=424.3842626
Int length=8 ns/op=424.3816324
Long length=8 ns/op=452.9407552
Byte length=64 ns/op=441.674149
Short length=64 ns/op=472.2310028
Int length=64 ns/op=455.6142958
Long length=64 ns/op=487.6810328
Byte length=512 ns/op=454.0858634
Short length=512 ns/op=497.675829
Int length=512 ns/op=481.2103832
Long length=512 ns/op=507.4674306
Byte length=4096 ns/op=531.7923602
Short length=4096 ns/op=648.254466
Int length=4096 ns/op=578.0794842
Long length=4096 ns/op=563.3641424
N5:
Byte length=1 ns/op=3118.2292802
Short length=1 ns/op=3083.7797488
Int length=1 ns/op=3177.8996446
Long length=1 ns/op=3151.0892072
Byte length=8 ns/op=3287.7326966
Short length=8 ns/op=3126.5799676
Int length=8 ns/op=3197.3203112
Long length=8 ns/op=3201.0613218
Byte length=64 ns/op=3178.7730612
Short length=64 ns/op=3162.2255092
Int length=64 ns/op=3241.3191864
Long length=64 ns/op=3117.6674886
Byte length=512 ns/op=3106.540978
Short length=512 ns/op=3183.0501344
Int length=512 ns/op=3513.8142382
Long length=512 ns/op=3592.4372798
Byte length=4096 ns/op=3552.9428216
Short length=4096 ns/op=3997.586686
Int length=4096 ns/op=4545.2151442
Long length=4096 ns/op=4371.4996338
AFTER
Host:
Byte length=1 ns/op=261.764995
Short length=1 ns/op=238.6584262
Int length=1 ns/op=262.856902
Long length=1 ns/op=238.0286378
Byte length=8 ns/op=242.4962264
Short length=8 ns/op=247.8668746
Int length=8 ns/op=263.9420024
Long length=8 ns/op=243.3675294
Byte length=64 ns/op=243.3372902
Short length=64 ns/op=249.0408034
Int length=64 ns/op=250.2168296
Long length=64 ns/op=253.837053
Byte length=512 ns/op=252.8071526
Short length=512 ns/op=271.689653
Int length=512 ns/op=291.8933238
Long length=512 ns/op=341.6303746
Byte length=4096 ns/op=540.8749038
Short length=4096 ns/op=661.7068158
Int length=4096 ns/op=569.030217
Long length=4096 ns/op=565.0571702
N5:
Byte length=1 ns/op=1209.4042078
Short length=1 ns/op=1207.2498746
Int length=1 ns/op=1377.0557706
Long length=1 ns/op=1348.6359368
Byte length=8 ns/op=1260.0724162
Short length=8 ns/op=1229.6107912
Int length=8 ns/op=1414.1408952
Long length=8 ns/op=1394.1158746
Byte length=64 ns/op=1232.532947
Short length=64 ns/op=1228.1248122
Int length=64 ns/op=1468.2667912
Long length=64 ns/op=1404.232687
Byte length=512 ns/op=1256.976093
Short length=512 ns/op=1335.5540308
Int length=512 ns/op=1599.6927076
Long length=512 ns/op=1769.8866764
Byte length=4096 ns/op=3310.2486656
Short length=4096 ns/op=3956.6322484
Int length=4096 ns/op=4374.6221234
Long length=4096 ns/op=4256.71598
Bug: 19664826
Change-Id: I703d7346de732199be1feadbead021c6647a554a
|
| |
|
|
|
|
|
| |
UnixSocketAddress maps to stuct sockaddr_un from sys/un.h.
Bug: 3106438
Change-Id: Ia4d57729e286c8b3a62a78202bc2385f0d33cb52
|
| |
|
|
|
|
|
|
|
|
|
| |
According to the comments in Posix_close(), TEMP_FAILURE_RETRY() should
not be used with close():
https://android.googlesource.com/platform/libcore/+/462bdac45c10f43d88d8f07f6994e272a27c14a2%5E%21/#F12
Bug: http://b/20501816
Change-Id: Ie283f848c4fe50fcde9358c8ed307ec048e70892
Signed-off-by: Spencer Low <CompareAndSwap@gmail.com>
|
| |
|
|
|
|
| |
Also remove an outdated comment.
Change-Id: If0da380f78c1e77963953d8e64737d0f22c90fad
|
| |
|
|
|
|
|
|
| |
Developed in conjunction with:
https://android-review.googlesource.com/135491
Bug: 18581716
Change-Id: Icddee915579e4187a181138f8ef8d92f3a70de35
|
| |
|
|
|
|
| |
This is fix avoid shadow variable warning
Change-Id: I014ab622b33326470b89e3971b7ad898700f9962
|
| |
|
|
|
|
| |
For use in StrictJarFile.
Change-Id: Ife29e359cd97cf71b184151ebb0efffaa9cdb0a8
|
| |
|
|
|
|
|
|
|
|
|
| |
The declaration of std::swap here is inconsistent with the one in
libc++ (noexcept differences). Rather than worrying about keeping them
all consistent, just remove swap. It was only ever added for ART, and
ART now uses std::unique_ptr instead.
This was causing an ambiguous overload error in system/core.
Change-Id: I4cf4c41c5dda01a96915e8309af2f8be089d1a2a
|
| |
|
|
|
|
|
|
| |
Make the DISALLOW_COPY_AND_ASSIGN macro delete the member functions rather
than just not defining them to improve analysis of the Scoped.. classes.
Add a few missing const qualifiers.
Change-Id: I48eee0c22908d45a05df6979aa61442d2eedcf36
|
| |
|
|
|
|
|
|
| |
Refactor JniInvocation::GetLibrary to not return a stack-allocated
string. Instead, provide a char buffer.
Bug: 16404669
Change-Id: I34f4a40e28bc491ba630a2b1bff5792e34937101
|