Commit graph

27238 commits

Author SHA1 Message Date
Christopher Ferris
f3ff8dc6f4 Merge "Ignore output to stderr while enumerating tests" 2018-09-27 23:23:36 +00:00
Treehugger Robot
ddf92a1ba5 Merge "Always return /vendor/bin/sh as shell for OEM ids in getpwnam() etc." 2018-09-27 23:23:34 +00:00
Colin Cross
6b755755bc Merge "Disable STL for crt objects" 2018-09-27 23:23:19 +00:00
Elliott Hughes
d7ab721ec0 Merge "Use builtins for ceil/floor/rint/trunc on arm64"
am: 7208139406

Change-Id: I6559c8d36e08b281603852d7a6e4b6173a7cc4ce
2018-09-27 13:46:16 -07:00
Tom Cherry
fa5f61c8d9 Always return /vendor/bin/sh as shell for OEM ids in getpwnam() etc.
During the review of the script that generates /vendor/etc/passwd, it
was suggested that the shell be /vendor/bin/sh instead of the typical
/system/bin/sh.  This has subsequently caused bionic unit tests to
fail, since they always check that the shell is set to /system/bin/sh.

In the spirit of that review, libc is modified to return
/vendor/bin/sh for the OEM AID ranges and the test is updated to
expect this.

Test: bionic unit tests
Change-Id: Ie7c1c48fde8a71b3df1aa0ef112d42ab7bd3baec
2018-09-27 20:29:49 +00:00
Elliott Hughes
7208139406 Merge "Use builtins for ceil/floor/rint/trunc on arm64" 2018-09-27 20:24:28 +00:00
Colin Cross
ab17944178 Disable STL for crt objects
cc_objects are getting support for STL headers, disable them for
crt objects to avoid a circular dependency through libc++.

Test: m checkbuild
Change-Id: I4e0f4a2193ce98ec4b8802492add9014ec0dba98
2018-09-27 11:03:22 -07:00
Elliott Hughes
a7ec71a93f Merge "Add reallocarray(3)."
am: e27886eaea

Change-Id: I03982fe8ad87a4938c3079a4db7454116fa8ab1c
2018-09-26 16:16:10 -07:00
Elliott Hughes
e27886eaea Merge "Add reallocarray(3)." 2018-09-26 22:54:54 +00:00
Elliott Hughes
b177085ce7 Add reallocarray(3).
Originally a BSD extension, now in glibc too. We've used it internally
for a while.

(cherry-pick of e4b13f7e3ca68edfcc5faedc5e7d4e13c4e8edb9.)

Bug: http://b/112163459
Test: ran tests
Change-Id: I813c3a62b13ddb91ba41e32a5a853d09207ea6bc
Merged-In: I813c3a62b13ddb91ba41e32a5a853d09207ea6bc
2018-09-26 14:24:18 -07:00
Dimitry Ivanov
db938a8138 Merge "linker: extract defaults and source files"
am: e4e3de819d

Change-Id: I7da222d54c9ecca34e870199b2e165fd5c84b66d
2018-09-26 02:20:59 -07:00
Dimitry Ivanov
e4e3de819d Merge "linker: extract defaults and source files" 2018-09-26 09:03:45 +00:00
Chih-hung Hsieh
eca0afd80b Merge "Add noexcept to move constructors and assignment operators."
am: fe108db540

Change-Id: Ib70e6dec446c7fe886b1dee2980fc14108b35ccf
2018-09-25 16:43:12 -07:00
Chih-hung Hsieh
fe108db540 Merge "Add noexcept to move constructors and assignment operators." 2018-09-25 23:15:54 +00:00
Elliott Hughes
edf8f1a4f1 Merge "Only use NDK libraries in the benchmarks."
am: efaa60ff6c

Change-Id: Ib1c8f6b47192686b5bac7c9c14a673acce9a306f
2018-09-25 15:30:53 -07:00
Elliott Hughes
efaa60ff6c Merge "Only use NDK libraries in the benchmarks." 2018-09-25 22:13:09 +00:00
Chih-Hung Hsieh
9a64b56334 Add noexcept to move constructors and assignment operators.
Bug: 116614593
Test: build with WITH_TIDY=1
Change-Id: I9f8760cddb3c25255cd24604606af84d837d55e9
2018-09-25 14:00:44 -07:00
dimitry
b8b3a76606 linker: extract defaults and source files
Move source files to filegroup and extract c/ldflags and
version-script to linker_defaults.

Bug: http://b/71494052
Test: make
Change-Id: Ic82885e1c006f91a8446978fabd214f87cd20510
2018-09-25 16:17:24 +02:00
dimitry
21557cdd2e Ignore output to stderr while enumerating tests
Bug: http://b/114304197
Test: adb unroot && run CtsBionicTestCases
Change-Id: I75880934fa1c25be6c76e866f97efc14d5ccd0a1
2018-09-25 12:23:33 +02:00
Stephen Hines
cd659d410a Fix up a few bionic tests for the clang-r339409 update.
Disable -Wmemset-transposed-args to ensure that FORTIFY still works
without it. Also, we can finally enable checking for
FLT_HAS_SUBNORM/DBL_HAS_SUBNORM/LDBL_HAS_SUBNORM now that those are
available in Clang.

Bug: http://b/110779387
Test: build and run bionic unit tests
Change-Id: I4bf19b870c44d981ecbd1089d0ae6a2496be5441
2018-09-24 16:59:08 -07:00
Elliott Hughes
627329915a Only use NDK libraries in the benchmarks.
It should be possible to run the benchmarks on any device, including
past and future ones, and sticking to NDK libraries ensures that.

Bug: N/A
Test: `readelf -aW`
Change-Id: I15a7a4104fa30263136bc3033d2bd9022cd8ff7b
2018-09-24 16:45:13 -07:00
Christopher Ferris
757ce0c2d7 Merge "Touch the memory when doing malloc/free benchmark."
am: 30b17e32f0

Change-Id: I535050f02d8d93e3e4c85349e3f1804cee0b40b7
2018-09-21 09:12:01 -07:00
Christopher Ferris
30b17e32f0 Merge "Touch the memory when doing malloc/free benchmark." 2018-09-21 15:51:08 +00:00
Elliott Hughes
d0cceb0499 Merge "Remove unused NetBSD compatibility cruft."
am: 8f5589faf2

Change-Id: Ic10b6409b8081dfee4138188d35e085d2c437381
2018-09-20 18:21:37 -07:00
Evgenii Stepanov
f59d04a759 Merge "[hwasan] Tweak process and thread initialization."
am: 8d11bea6c5

Change-Id: If751f9b66bacd80f21cbc9f693fb11d29680e961
2018-09-20 18:15:13 -07:00
Treehugger Robot
8f5589faf2 Merge "Remove unused NetBSD compatibility cruft." 2018-09-21 01:06:32 +00:00
Josh Gao
fbec1c0ced Merge changes from topics "fdsan_ziparchive_type", "fdsan_java_socket"
am: ce9d653b38

Change-Id: Ia9f5e9a20d471712e5fa8259c1c5d0fbf6b9a85b
2018-09-20 18:03:57 -07:00
Christopher Ferris
4fae703029 Touch the memory when doing malloc/free benchmark.
Also, update the benchmark loop for modern C++.

Test: Ran benchmarks.
Change-Id: I925446b893793eb8c2c6759716cdd3dbbcf1e7c1
2018-09-20 15:03:49 -07:00
Evgenii Stepanov
8d11bea6c5 Merge "[hwasan] Tweak process and thread initialization." 2018-09-20 21:39:55 +00:00
Elliott Hughes
64f8e7b1cc Remove unused NetBSD compatibility cruft.
Bug: N/A
Test: builds
Change-Id: I5c472c7b5c570c739363b4a454251ebf0324d43c
2018-09-20 13:27:41 -07:00
Josh Gao
ce9d653b38 Merge changes from topics "fdsan_ziparchive_type", "fdsan_java_socket"
* changes:
  fdsan: improve documentation.
  fdsan: add type for libziparchive's ZipArchive.
  fdsan: add types for Java sockets.
2018-09-20 19:22:03 +00:00
Evgenii Stepanov
13e8dcbdc9 [hwasan] Tweak process and thread initialization.
Make sure that TLS_SLOT_TSAN is always available and correctly set up in
HWASan-instrumented functions by setting up the tls register and running hwasan
initialization (__hwasan_init in the main thread and __hwasan_thread_enter in
secondary) early enough.

This is needed to accomodate a change in HWASan: https://reviews.llvm.org/D52249

Bug: 112438058
Test: boot with SANITIZE_TARGET=hwaddress, run bionic-tests
Change-Id: Icd909a4ea0da6c6c1095522bcc28debef5f2c63d
2018-09-20 12:20:12 -07:00
Elliott Hughes
99530a9049 Merge "Remove dead code."
am: a02d631163

Change-Id: I747454d10a4745c82a281fe2c362ab3a2d9c86dd
2018-09-19 10:22:15 -07:00
Elliott Hughes
a02d631163 Merge "Remove dead code." 2018-09-19 17:13:11 +00:00
Elliott Hughes
15711c1dd0 Remove dead code.
I stumbled across this because I was looking at the various locks in libc.

Bug: N/A
Test: ran tests
Change-Id: I77c9954f49aaae7519ea7f4917bbe6f138b841ad
2018-09-18 14:28:48 -07:00
Josh Gao
d747bb8f3f fdsan: improve documentation.
Fix a race condition in the example, and add a linearized version to
make it more clear what's going on.

Test: none
Change-Id: Id9158e4fd407b676ef364e7076985de3ad477457
2018-09-18 13:42:08 -07:00
Josh Gao
5fa9df8efc fdsan: add type for libziparchive's ZipArchive.
Test: debuggerd `pidof system_server` | grep " fd "
Change-Id: I6a9a4306ecffe3899e4cc7285a0eb33efaa62616
2018-09-18 13:23:31 -07:00
Elliott Hughes
4c23b05a63 Merge "State clearly that an ELF file has the wrong architecture."
am: 655f80e37f

Change-Id: I8a8eb83f3cf56d2177d12d49e2fb8991065b1524
2018-09-18 11:23:01 -07:00
Elliott Hughes
655f80e37f Merge "State clearly that an ELF file has the wrong architecture." 2018-09-18 18:15:07 +00:00
Josh Gao
d527cf1f99 fdsan: add types for Java sockets.
Test: art/tools/run-libcore-tests.sh
Change-Id: If61211bc4ae225c3f89db989a167f9dc4fce375a
2018-09-17 17:31:58 -07:00
Elliott Hughes
d16cface55 State clearly that an ELF file has the wrong architecture.
Before:

  "libx.so" has unexpected e_machine: 40 (EM_ARM)

After:

  "libx.so" is for EM_X86_64 (62) instead of EM_AARCH64 (183)

Bug: N/A
Test: `LD_PRELOAD=/system/lib64/libm-x86_64.so date` on arm64
Change-Id: I5bb40c435bd22b4e11fe802615925e10db7fb631
2018-09-17 15:50:09 -07:00
Elliott Hughes
a045992eda Merge "Explicitly say pthread_cancel in the docs."
am: 8b527f2857

Change-Id: I2c829c4596f0c4a27a6efc18ce03ccaf64ccf483
2018-09-15 08:50:24 -07:00
Elliott Hughes
8b527f2857 Merge "Explicitly say pthread_cancel in the docs." 2018-09-15 15:40:03 +00:00
Elliott Hughes
670ea7aca9 Explicitly say pthread_cancel in the docs.
Bug: http://b/33943372
Test: N/A
Change-Id: If71691f7ff20c9b8c14de15692543bbd858c9aab
2018-09-14 17:05:01 -07:00
Peter Collingbourne
c61ae56495 Merge "benchmarks: Fix the benchmark tests."
am: ed16b344e7

Change-Id: Ic3da18c7bc6d7d5f72b89360a6cf546070f04d71
2018-09-13 19:25:46 -07:00
Peter Collingbourne
ed16b344e7 Merge "benchmarks: Fix the benchmark tests." 2018-09-14 02:16:52 +00:00
Peter Collingbourne
9dda60d43b Merge "benchmarks: Update the documentation."
am: b228f4e3d3

Change-Id: I79e4d719bcc3eba24b26689ac47e97b4278209c8
2018-09-13 16:24:45 -07:00
Peter Collingbourne
b228f4e3d3 Merge "benchmarks: Update the documentation." 2018-09-13 23:12:08 +00:00
Peter Collingbourne
62011c27a7 benchmarks: Update the documentation.
Update the locations of the benchmark binaries to match where they
are currently installed.
2018-09-13 16:08:18 -07:00
Peter Collingbourne
c282ca9f44 benchmarks: Fix the benchmark tests.
Update the list of benchmarks to include the recently added strncmp
benchmarks.
2018-09-13 16:06:01 -07:00