History log of /frameworks/rs/rsCppUtils.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
82e135c4bbe18855d8ed02632bb074f8da0b96e0 28-Feb-2017 Miao Wang <miaowang@google.com> Remove libutils.so dependency from libRSDriver, libRSCpuRef, and most
parts of libRS_internal.

NOTE: we're resolving dependencies to provide a model for vendors.
For us, all this code is above the HAL, thus the dependencies
are acceptable; whereas for vendors, their equivalent of this code is
below the HAL, and so the dependencies are not acceptable.

This CL resolves the libutils dependency by:
- Implement the timings functions in android::renderscript namespace
using NDK APIs, instead of using libutils counterparts.
- Replace android::Vector and android::String8 by std::vector and
std::string.
- PROPERTY_VALUE_MAX is replaced as PROP_VALUE_MAX.

This CL didn't resolve the libutils dependency of rsFont.cpp and
rsDebugger.cpp in libRS_internal:
The dependent functionality in rsDebugHelper.h is off by default, and
only intended for use during development; and rsFont.cpp is part of
graphics API which is not implemented below the HAL and is not used as
a model by vendors.

Additionally, this CL fixed the bug that mNodes was sorted in a
decreasing order. Nodes in ScriptGroup should be executed in
ascending order. The bad sort was only for support lib; so there was a
previously-unknown bug in support lib implementation of ScriptGroup.

Background:
libutils contains a collection of things like Vector, String8,
CallStack. It served the purpose similar to a STL library, when there
was no stable STL implementation available in Android. And most
importantly, it is not part of NDK.
Support lib used to use our own implementations of android::Vector and
android::String8, because it can only depend on NDK, similarly for the
timing related functions.
As part of the Treble requirements, native RS, including vendor version
libRS_internal, libRSDriver, libRSCpuRef could only depend on NDK
too. So we need to break the dependency on libutils. And since we now
have reasonable support of STLs, we should use that instead.

Bug: 34396220
Test: mm, and all CTS tests pass on Bullhead;
RsTest and RSTest_CompatLib (both native and compat path) also pass.
Change-Id: Ib9a37d16235c1dcd0f5bae3b95c374e394483c91
/frameworks/rs/rsCppUtils.cpp
2a61168a777ee434ce2c28945aa74f6a6bcf2820 28-Feb-2017 Miao Wang <miaowang@google.com> Remove libcutils dependency.

- Implement property_get using __system_property_get, remove
dependencies on cutils/properties.h.
- remove rsCompatibilityLib.cpp since it only contains propery_get, and
it is now in rsCppUtils.cpp.
- Disable ATRACE. The systrace is current done in Java level. If we
want to do it in the driver, we need to have our own implementation
similar to native/utils/trace.cc
- Remove CC_LIKELY macro.

Bug: 34396220
Test: build

Change-Id: I6a6cbcfb2ca15b9d1f09b9ce0579d39fdbe98727
/frameworks/rs/rsCppUtils.cpp
7974fc03e11f3a8dd40f794f3b33b4889483090c 09-Feb-2017 Rahul Chaudhry <rahulchaudhry@google.com> frameworks/rs: fix typos and clang-tidy warnings

This change fixes a few typos and clang tidy warnings related to the
"llvm-namespace-comment" checks.

Bug: 26936282
Test: WITH_TIDY=1 WITH_TIDY_CHECKS="llvm-namespace-comment" mm
Change-Id: Ic65182e5b4999fbd48d6a8ad7172e4bfeeb541f4
/frameworks/rs/rsCppUtils.cpp
f5ffbf2b8c885a4fc7c34812ab33ddb16dc56325 17-Oct-2016 Mark Salyzyn <salyzyn@google.com> rsCppUtils fails to include unistd.h

File makes assumptions about header side effects

Test: compile
Bug: 30465923
Change-Id: I1ae8252380b493b70a3dc104287f81ca4f9114fc
/frameworks/rs/rsCppUtils.cpp
7b29f5a5f75b1a8d830a14c6c5ae9bcb7d0b3ca4 13-Apr-2015 Pirama Arumuga Nainar <pirama@google.com> Do not call ALOGV between fork() and exec()

Move call to ALOGV earlier so we don't indirectly call malloc between
calls to fork() and exec().

Change-Id: I50517f39b509b359f62787d3ed61ea1de4ceb899
/frameworks/rs/rsCppUtils.cpp
90ea8d33a7fd9a64dd68ef7ebccf595b8eb1dd68 28-Mar-2015 Pirama Arumuga Nainar <pirama@google.com> Ensure that libRSDriver gets child's exit signal

b/19934827

ProcessManager in libcore can reap unclaimed SIGCHLDs in its process
group. To ensure that the exit signal is not caught by ProcessManager
and instead sent to libRS, set the child's PGID to its PID.

Change-Id: Ife548254c089ad50442ae202671e87e1846cba8c
/frameworks/rs/rsCppUtils.cpp
2fa8a238dd69afebdeb757adcb1d674043d78e32 26-Mar-2015 Pirama Arumuga Nainar <pirama@google.com> Wrap TEMP_FAILURE_RETRY around system calls

BUG 19934827

Wrap TEMP_FAILURE_RETRY around system calls that can return EINTR
(waitpid, close).

Refactor fork/exec flows in various places into a utility function
and log errors so we can better understand failures in the test server.

Fix a small use-after-free issue in ScriptGroups.

Change-Id: I60b192f83c395a13c27cd6bd2289c44132b84791
/frameworks/rs/rsCppUtils.cpp
2abfcc6d129fe3defddef4540aa95cc445c03a7a 18-Feb-2015 Yang Ni <yangni@google.com> Moved class ScriptExecutable to its own module

b/19283946

This move also included the related class SharedObjectUtils.

Change-Id: Iefd587b659c4ad99340c330955b41cd92df45563
/frameworks/rs/rsCppUtils.cpp
a567cfab33f09f06efa0ad09e7cdbe3392385cee 28-Jan-2015 Elliott Hughes <enh@google.com> Add missing <string.h> include.

Change-Id: Icf6dae8d8b198c6a4686485bd6d053bdb8db3216
/frameworks/rs/rsCppUtils.cpp
574854bcb2eb25a85b9b52faf2fb3e743fa7aa14 10-Jul-2013 Stephen Hines <srhines@google.com> Fix up master issues with tracing/logging and the compatibility library.

Change-Id: Ia35ca58807a78ea01c4da6c44b4d5e29e65e0cfd
/frameworks/rs/rsCppUtils.cpp
f313dc32d5ea68a7c48fb4ec6e131ec2fb97ce2d 09-Jul-2013 Jason Sams <jsams@google.com> Remove internal element builder and vector code.

Remove additional String8 references from shared includes.

Change-Id: Iede11384b9fc5a303d15d47fd4074c800dc6ad5f
/frameworks/rs/rsCppUtils.cpp