OSDN Git Service
Dan Albert [Mon, 19 May 2014 23:48:06 +0000 (23:48 +0000)]
Merge "Revert "Removes bionic's dependence on stlport""
Dan Albert [Mon, 19 May 2014 23:46:51 +0000 (23:46 +0000)]
Revert "Removes bionic's dependence on stlport"
This reverts commit
4d35da1df8b74c1965b2201f6089e7d7bb352def.
Change-Id: Ie9a2620441edb55dbc5949e13a4b913ea4e66797
Dan Albert [Mon, 19 May 2014 23:31:34 +0000 (23:31 +0000)]
Merge "Removes bionic's dependence on stlport"
Dan Albert [Mon, 19 May 2014 23:21:46 +0000 (23:21 +0000)]
Merge "Removes RTTI support from libc"
Elliott Hughes [Mon, 19 May 2014 23:19:31 +0000 (23:19 +0000)]
Merge "Switch back to OpenBSD inet_ntop now they're FORTIFY clean."
Elliott Hughes [Mon, 19 May 2014 22:55:29 +0000 (15:55 -0700)]
Switch back to OpenBSD inet_ntop now they're FORTIFY clean.
Change-Id: I04798a4966c352a8a12feebdff9646e3bad5933f
Sreeram Ramachandran [Mon, 19 May 2014 22:39:05 +0000 (22:39 +0000)]
Merge "Mark sockets on creation (socket()) and accept4()."
Ben Cheng [Mon, 19 May 2014 22:28:10 +0000 (22:28 +0000)]
Merge "Address additional warnings found by GCC 4.9."
Sreeram Ramachandran [Mon, 19 May 2014 20:39:57 +0000 (13:39 -0700)]
Mark sockets on creation (socket()) and accept4().
Remove the separate syscall for accept() and implement it as accept4(..., 0).
Change-Id: Ib0b8f5d7c5013b91eae6bbc3847852eb355c7714
Sreeram Ramachandran [Mon, 19 May 2014 22:16:47 +0000 (22:16 +0000)]
Merge "Query libnetd_client for the appropriate netId for host resolution."
Ben Cheng [Mon, 19 May 2014 21:27:31 +0000 (14:27 -0700)]
Address additional warnings found by GCC 4.9.
Change-Id: If668a6eb98a6ce7b2872f528b8e3527638814f68
Paul Jensen [Thu, 15 May 2014 18:43:07 +0000 (14:43 -0400)]
Query libnetd_client for the appropriate netId for host resolution.
If libnetd_client can't be found, operate as before and use the default netId
potentially overriden by a more specific netId passed in to
android_get*fornet().
(cherry picked from commit
559c7842cc6862568d9b5799fc0bcf74d58b596b)
Change-Id: I42ef3293172651870fb46d2de22464c4f03e8e0b
Dan Albert [Mon, 19 May 2014 17:50:15 +0000 (10:50 -0700)]
Removes bionic's dependence on stlport
Only affects tests/benchmarks. Confirmed passing on arm.
Change-Id: If158e23e8cd06e7597ef6f3c9376f6799b467e62
Dan Albert [Mon, 19 May 2014 17:32:42 +0000 (10:32 -0700)]
Removes RTTI support from libc
Our type_info stub implementation is incompatible with the libc++ headers. Since
we don't need this support internally and anyone that wants RTTI support will
have to use libc++ anyway, this can be safely removed.
Change-Id: Ied8b67a0d86a4eb0e31191a50cceba0e39a16a6d
Sreeram Ramachandran [Mon, 19 May 2014 16:45:53 +0000 (16:45 +0000)]
Merge "Cosmetic changes to netd client files."
Christopher Ferris [Mon, 19 May 2014 02:19:58 +0000 (02:19 +0000)]
Merge "Accuracy tests for libm"
Sreeram Ramachandran [Sun, 18 May 2014 22:18:36 +0000 (15:18 -0700)]
Cosmetic changes to netd client files.
+ Name the dispatch header correctly (NetdClientDispatch.h).
+ Hide the global dispatch variable (__netdClientDispatch).
+ Explain why it's okay to read the variable without locking.
+ Use quotes instead of angle-brackets for non-system includes.
+ Add necessary declarations for C compiles (and not just C++).
Change-Id: Id0932165e71d81da5fce77a684f40c2263f58e61
Elliott Hughes [Sat, 17 May 2014 00:35:32 +0000 (00:35 +0000)]
Merge "Rethrow SIGTRAP too."
Elliott Hughes [Sat, 17 May 2014 00:34:13 +0000 (17:34 -0700)]
Rethrow SIGTRAP too.
Bug:
15024256
Change-Id: I0347da9698a6ccd317ce6e6f7916d710d66e0f8a
Elliott Hughes [Sat, 17 May 2014 00:16:04 +0000 (00:16 +0000)]
Merge "Fix the newly-introduced warning and turn on -Werror."
Elliott Hughes [Sat, 17 May 2014 00:14:45 +0000 (00:14 +0000)]
Merge "debugger.cpp should know the names of the signals it catches."
Elliott Hughes [Fri, 16 May 2014 23:59:54 +0000 (16:59 -0700)]
debugger.cpp should know the names of the signals it catches.
Change-Id: I37908b07739ad465652f143848c52bc1ef19e421
Elliott Hughes [Fri, 16 May 2014 23:50:34 +0000 (16:50 -0700)]
Fix the newly-introduced warning and turn on -Werror.
I cleaned up most of our warnings last week but forgot to turn on -Werror,
so of course we're getting new warnings already. I've left -Werror commented
out in those places where we still have warnings to deal with before we can
turn on -Werror.
Change-Id: Ia58ff8b8c1ada4bf81eec6f19ec1d34e133cf4b1
Elliott Hughes [Fri, 16 May 2014 23:30:52 +0000 (23:30 +0000)]
Merge "Export get_malloc_leak_info and free_malloc_leak_info, used by ddms."
Elliott Hughes [Fri, 16 May 2014 23:29:55 +0000 (16:29 -0700)]
Export get_malloc_leak_info and free_malloc_leak_info, used by ddms.
Bug:
11156955
Change-Id: I84043f7b2c0ea0e336f6e2af3b7adb2f8488bd53
Elliott Hughes [Fri, 16 May 2014 23:23:35 +0000 (23:23 +0000)]
Merge "Hide _exit_with_stack_teardown."
Elliott Hughes [Fri, 16 May 2014 23:17:44 +0000 (16:17 -0700)]
Hide _exit_with_stack_teardown.
Bug:
11156955
Change-Id: Ida3020343c9975177dc324918cd1f10c455eb173
Elliott Hughes [Fri, 16 May 2014 23:04:02 +0000 (23:04 +0000)]
Merge "Hide various debug malloc implementation details."
Elliott Hughes [Fri, 16 May 2014 22:52:41 +0000 (22:52 +0000)]
Merge "Remove dead code."
Elliott Hughes [Fri, 16 May 2014 22:51:28 +0000 (22:51 +0000)]
Merge "Hide __signalfd4, used to implement signalfd(3)."
Elliott Hughes [Fri, 16 May 2014 22:47:29 +0000 (15:47 -0700)]
Hide __signalfd4, used to implement signalfd(3).
Bug:
11156955
Change-Id: I50842279cb5b32ec8bd45193435574e415cd806e
Jingwei Zhang [Tue, 13 May 2014 23:17:24 +0000 (16:17 -0700)]
Accuracy tests for libm
This patch adds tests for 14 math functions to address coverage
issue of math functions discussed in:
https://android-review.googlesource.com/#/c/49653/
Change-Id: Ia7200b93d4f5c7928a3fb827ca6932226384a116
Signed-off-by: Jingwei Zhang <jingwei.zhang@intel.com>
Signed-off-by: Yong Yao <yong.yao@intel.com>
Elliott Hughes [Fri, 16 May 2014 22:23:54 +0000 (15:23 -0700)]
Hide various debug malloc implementation details.
Bug:
11156955
Change-Id: Ib9d69d49ecec8eff4f12392bde94d843ae53d442
Elliott Hughes [Fri, 16 May 2014 21:43:00 +0000 (14:43 -0700)]
Remove dead code.
This doesn't exist upstream.
Really we should upgrade to the current arc4random, but that's a bigger
job for another day.
Bug:
11156955
Change-Id: If6cd41b79139c64c17e81999e246cf4f00882ce8
Elliott Hughes [Fri, 16 May 2014 19:56:52 +0000 (19:56 +0000)]
Merge "Hide __futex_wake_ex and __futex_wait_ex."
Elliott Hughes [Fri, 16 May 2014 19:53:31 +0000 (12:53 -0700)]
Hide __futex_wake_ex and __futex_wait_ex.
Also remove some cruft that isn't needed now we're using uapi headers.
Bug:
11156955
Change-Id: I936b9c5b01d8bd6bfb2e5bc0e3f86cd86739cc04
Elliott Hughes [Fri, 16 May 2014 18:00:51 +0000 (18:00 +0000)]
Merge "With libstdc++ in libc, __futex_wait and __futex_wake can be hidden."
Elliott Hughes [Thu, 15 May 2014 01:22:58 +0000 (18:22 -0700)]
With libstdc++ in libc, __futex_wait and __futex_wake can be hidden.
This patch is conservative and just touches LP64. (But not because we
know of anyone using this in LP32.)
Bug:
13367666
Change-Id: Id45652debc4534584479b16b501401f6f23acea9
Elliott Hughes [Fri, 16 May 2014 16:37:20 +0000 (16:37 +0000)]
Merge "Move libstdc++ into libc."
Christopher Ferris [Fri, 16 May 2014 02:14:07 +0000 (02:14 +0000)]
Merge "Fix comment typo."
Christopher Ferris [Fri, 16 May 2014 01:12:11 +0000 (18:12 -0700)]
Fix comment typo.
Change-Id: I1909f724826b531daf14fec4853e40d578fc0f59
Dmitriy Ivanov [Fri, 16 May 2014 00:37:53 +0000 (00:37 +0000)]
Merge "Register _cleanup function with atexit"
Elliott Hughes [Thu, 15 May 2014 23:03:25 +0000 (23:03 +0000)]
Merge "Scrub uapi headers slightly harder."
Dmitriy Ivanov [Thu, 15 May 2014 21:55:23 +0000 (21:55 +0000)]
Merge "Improve detection of already loaded libraries"
Dmitriy Ivanov [Thu, 15 May 2014 06:11:05 +0000 (23:11 -0700)]
Register _cleanup function with atexit
* Register cleanup function with atexit
instead of calling it explicitly on
exit()
* abort() no longer calls _cleanup:
Flushing stdio buffers on abort is no
longer required by POSIX.
* dlmalloc no longer need to reset cleanup
(see above)
* Upstream findfp.c makebuf.c setvbuf.cexit.c
to openbsd versions.
Bug:
14415367
Change-Id: I277058852485a9d3dbb13e5c232db5f9948d78ac
Elliott Hughes [Thu, 15 May 2014 19:01:11 +0000 (12:01 -0700)]
Scrub uapi headers slightly harder.
There's no point having always-false tests. It just makes the headers
harder to read.
Bug:
11560081
Change-Id: I6187755e1514ca9ff5642b3c1b0489f22edddaf5
Calin Juravle [Thu, 15 May 2014 09:36:22 +0000 (09:36 +0000)]
Merge "Document a known test issue in stdio_test.cpp."
Calin Juravle [Thu, 15 May 2014 09:36:00 +0000 (09:36 +0000)]
Merge "Fill in missing bits in x86(_64) ucontext_t"
Calin Juravle [Wed, 14 May 2014 16:07:10 +0000 (17:07 +0100)]
Document a known test issue in stdio_test.cpp.
Bug:
13077905
Change-Id: Iab7fc7be0737c732e26cc07ecd7884b3087b51bb
Calin Juravle [Tue, 13 May 2014 19:29:01 +0000 (20:29 +0100)]
Fill in missing bits in x86(_64) ucontext_t
Bug:
12828904
Bug:
12875898
Change-Id: I0ec0dfe16af80bfb3153f3c3b1b3d180eff30f39
Andrew Hsieh [Thu, 15 May 2014 01:52:22 +0000 (01:52 +0000)]
Merge "Rename user_i387_struct -> user_fpregs_struct in sys/ucontext.h"
Elliott Hughes [Thu, 15 May 2014 01:18:55 +0000 (18:18 -0700)]
Move libstdc++ into libc.
The Android build system always links against libstdc++.so anyway. Having
operator new and operator delete in a separate library means we can't use
constructors and destructors on heap-allocated objects inside the C library,
which is quite an unfortunate limitation.
This will be cheaper too; on LP64 we can stop linking against the [now empty]
libstdc++.so giving the dynamic linker one less library to worry about for
every process.
There's precedent too --- we already have no libpthread or librt.
For now I'm leaving the include files where they are, and I'm generating a
dummy libstdc++.so and libstdc++.a. We can come back and clean that up later
if all goes well.
Bug:
13367666
Change-Id: I6f3e27ea7c30d03d6394965d0400c9dc87fa83db
Andrew Hsieh [Thu, 15 May 2014 01:11:11 +0000 (09:11 +0800)]
Rename user_i387_struct -> user_fpregs_struct in sys/ucontext.h
See
93e1907ae1794068c1018750603c9206cb700d1b
Change-Id: Icb207f4e17cfffdd6d37500656434adf1cc34427
Christopher Ferris [Thu, 15 May 2014 01:06:25 +0000 (01:06 +0000)]
Merge "Increase minimum thread size for 64 bit."
Christopher Ferris [Thu, 15 May 2014 00:58:29 +0000 (17:58 -0700)]
Increase minimum thread size for 64 bit.
Bug:
14468519
Change-Id: I642a5515acf5fbed46e77e176f6b5dd3b7c7bd45
Elliott Hughes [Thu, 15 May 2014 00:20:00 +0000 (00:20 +0000)]
Merge "Remove the unused __system_property_wait."
Elliott Hughes [Thu, 15 May 2014 00:02:09 +0000 (17:02 -0700)]
Remove the unused __system_property_wait.
This isn't declared in any header file.
Bug:
14970171
Change-Id: Ib9fce61343dfb6b6ccd7e1430e1a6e34e4e869df
Christopher Ferris [Thu, 15 May 2014 00:00:50 +0000 (00:00 +0000)]
Merge "Do not keep struct state on the stack."
Christopher Ferris [Wed, 14 May 2014 23:06:17 +0000 (16:06 -0700)]
Do not keep struct state on the stack.
This structure is huge (~18000 bytes on arm64) and can blow out
the stack very easily.
Modify the code to allocate these structures instead of leaving them
on the stack.
Bug:
14468519
Change-Id: I774f71235d896d32a14ab1af06f95ca9ef819f52
Elliott Hughes [Wed, 14 May 2014 23:35:30 +0000 (23:35 +0000)]
Merge "Add tests for fprintf behavior when the underlying fd is bad."
Dmitriy Ivanov [Fri, 9 May 2014 16:10:14 +0000 (09:10 -0700)]
Improve detection of already loaded libraries
Linker is now able to resolve symlinked libraries correctly.
soinfo is extended to save the graph of dependencies during
load/unload. Dependencies are used only in CallConstructor.
Bug:
9741592
Change-Id: Id9c48a74c46aa89bcdf3d54ec2f8ba3d398130b1
Dmitriy Ivanov [Wed, 14 May 2014 21:02:17 +0000 (21:02 +0000)]
Merge "Fix for linker allocator"
Elliott Hughes [Wed, 14 May 2014 20:31:35 +0000 (13:31 -0700)]
Add tests for fprintf behavior when the underlying fd is bad.
Bug:
7229520
Change-Id: Ie878e0c13fdcda7b9131fa56208b84ed88125be7
Elliott Hughes [Wed, 14 May 2014 20:11:22 +0000 (20:11 +0000)]
Merge "Add a unit test for already-fixed printf -0.0 formatting."
Dmitriy Ivanov [Wed, 14 May 2014 19:52:57 +0000 (12:52 -0700)]
Fix for linker allocator
Change-Id: I18a3f1a8515657f0deb69266184fb516a27f90e8
Sreeram Ramachandran [Wed, 14 May 2014 19:40:50 +0000 (19:40 +0000)]
Merge "Mark sockets on accept()."
Elliott Hughes [Wed, 14 May 2014 19:39:12 +0000 (12:39 -0700)]
Add a unit test for already-fixed printf -0.0 formatting.
This was fixed by the upgrade to upstream head.
Bug:
5084292
Change-Id: Ia3bda1c0bbe38f428e22213b8bdbdf1a16caccf2
Elliott Hughes [Wed, 14 May 2014 19:29:45 +0000 (19:29 +0000)]
Merge "Add a regression test for a long-fixed pthread_once bug."
Elliott Hughes [Wed, 14 May 2014 19:29:29 +0000 (19:29 +0000)]
Merge "Remove the broken pthread deadlock prediction."
Elliott Hughes [Wed, 14 May 2014 18:46:08 +0000 (11:46 -0700)]
Add a regression test for a long-fixed pthread_once bug.
Bug:
1934122
Change-Id: Iae09baedc2c6ed4036521e51718fe9d015bc56b9
Elliott Hughes [Wed, 14 May 2014 18:35:49 +0000 (11:35 -0700)]
Remove the broken pthread deadlock prediction.
This hasn't built in over one release cycle and no one even noticed.
art does this the right way and other projects should do the same.
Change-Id: I7d1fb84c4080e008f329ee73e209ce85a36e6d55
Sreeram Ramachandran [Tue, 13 May 2014 22:40:26 +0000 (15:40 -0700)]
Mark sockets on accept().
(cherry picked from commit
58b1f3f6a30a660ad81637c2b50382c3d279243b)
Change-Id: I5d09be413cf720fbed905f96313b007997ada76c
Elliott Hughes [Wed, 14 May 2014 17:59:52 +0000 (17:59 +0000)]
Merge "Fix a typo in the big g_ search/replace."
Elliott Hughes [Wed, 14 May 2014 17:58:58 +0000 (10:58 -0700)]
Fix a typo in the big g_ search/replace.
Change-Id: I79261de70d225236d0eadff288220258d697437f
Elliott Hughes [Wed, 14 May 2014 17:36:35 +0000 (17:36 +0000)]
Merge "Switch to g_ for globals."
Elliott Hughes [Wed, 14 May 2014 17:02:03 +0000 (10:02 -0700)]
Switch to g_ for globals.
That's what the Google style guide recommends, and we're starting
to get a mix.
Change-Id: Ib0c53a890bb5deed5c679e887541a715faea91fc
Ross McIlroy [Wed, 14 May 2014 14:27:40 +0000 (14:27 +0000)]
Merge "Fix x86_64 user_fpregs_struct to use the same name for the tag word as glibc."
Ross McIlroy [Wed, 14 May 2014 12:29:19 +0000 (13:29 +0100)]
Fix x86_64 user_fpregs_struct to use the same name for the tag word as glibc.
Glibc calls the tag pointer in user_fpregs_struct ftw instead of twd.
Change-Id: I4a8dab777fa889de0b9927035cd18557ae6f3263
Calin Juravle [Wed, 14 May 2014 10:33:46 +0000 (10:33 +0000)]
Merge "Change wctype_t from int to long."
Calin Juravle [Wed, 14 May 2014 10:33:34 +0000 (10:33 +0000)]
Merge "Change wctype_t from enum to int"
Elliott Hughes [Wed, 14 May 2014 02:21:20 +0000 (02:21 +0000)]
Merge "Use the NetBSD inet_ntop until the OpenBSD bug is fixed."
Elliott Hughes [Wed, 14 May 2014 02:17:46 +0000 (19:17 -0700)]
Use the NetBSD inet_ntop until the OpenBSD bug is fixed.
Stupidly I found this bug by accident when writing the existing
tests, but I didn't think any real code would hit it. It turns
out that libcore always uses an INET6_ADDRSTRLEN-sized buffer
even when working with AF_INET addresses.
Change-Id: Ieffc8e4bbe9b66b49b033e3e7101c896e097e6f8
Dmitriy Ivanov [Wed, 14 May 2014 01:45:50 +0000 (01:45 +0000)]
Merge "Remove page level mprotects"
Elliott Hughes [Wed, 14 May 2014 01:43:15 +0000 (01:43 +0000)]
Merge "Fix <sys/endian.h> uint32_t build failures."
Elliott Hughes [Wed, 14 May 2014 01:42:12 +0000 (18:42 -0700)]
Fix <sys/endian.h> uint32_t build failures.
Change-Id: I833b51318f0bf7749073859b7ffacc668c27558e
Dmitriy Ivanov [Wed, 14 May 2014 01:34:48 +0000 (18:34 -0700)]
Remove page level mprotects
Freeing block mprotects on the page which it turn
may lead to application crash if linker subsequently
tries to modify another block on the page.
Bug:
14895266
Change-Id: I8ff7f5df467d7be184242de652032b3c84e24b76
Elliott Hughes [Wed, 14 May 2014 01:09:00 +0000 (01:09 +0000)]
Merge "Flesh out <arpa/inet.h>."
Elliott Hughes [Tue, 13 May 2014 23:05:51 +0000 (16:05 -0700)]
Flesh out <arpa/inet.h>.
Use the upstream OpenBSD implementations of these functions.
Also ensure we have symbols for htonl, htons, ntohl, and ntohs.
gtest doesn't like us using the macro versions in ASSERT_EQ.
Bug:
14840760
Change-Id: I68720e9aca14838df457d2bb27b999d5818ac2b5
Elliott Hughes [Wed, 14 May 2014 01:06:11 +0000 (01:06 +0000)]
Merge "We don't need two copies of <nsswitch.h>."
Elliott Hughes [Wed, 14 May 2014 01:05:29 +0000 (18:05 -0700)]
We don't need two copies of <nsswitch.h>.
Change-Id: I3f874326d96f41249f5c9b1b3c2885f858589029
Sreeram Ramachandran [Wed, 14 May 2014 00:43:47 +0000 (00:43 +0000)]
Merge "Fix build (take two)."
Sreeram Ramachandran [Wed, 14 May 2014 00:24:03 +0000 (17:24 -0700)]
Fix build (take two).
Make sure __netdClientDispatch is defined in the same set of libraries that
refer to it (e.g.: with connect.cpp).
Change-Id: I86d7bf2df5bde09f75a35b204eac0e1361747e22
Sreeram Ramachandran [Tue, 13 May 2014 23:57:07 +0000 (23:57 +0000)]
Merge "Fix build."
Sreeram Ramachandran [Tue, 13 May 2014 23:30:12 +0000 (16:30 -0700)]
Fix build.
Change-Id: I33293d8bc62cbb22e23a704c4242e7e9d3fce7c5
Sreeram Ramachandran [Tue, 13 May 2014 22:07:25 +0000 (22:07 +0000)]
Merge "Introduce netd_client, a dynamic library that talks to netd."
Sreeram Ramachandran [Mon, 12 May 2014 18:19:16 +0000 (11:19 -0700)]
Introduce netd_client, a dynamic library that talks to netd.
The library exists outside bionic. It is dynamically loaded, to replace selected
standard socket syscalls with versions that talk to netd.
Change connect() to use the library if available.
(cherry picked from commit
3a6b627a14df8111b03e452f2df4b5f4938e0e49)
Change-Id: Ib6198e19dbc306521a26fcecfdf6e8424d163fc9
Elliott Hughes [Tue, 13 May 2014 18:27:30 +0000 (18:27 +0000)]
Merge "Upgrade to tzdata2014c."
Elliott Hughes [Tue, 13 May 2014 18:26:46 +0000 (18:26 +0000)]
Merge "Consistently use #if defined(__BIONIC__) in tests."
Elliott Hughes [Tue, 13 May 2014 18:23:18 +0000 (11:23 -0700)]
Upgrade to tzdata2014c.
From the release notes:
Changes affecting near-future time stamps
Egypt observes DST starting 2014-05-15 at 24:00.
(Thanks to Ahmad El-Dardiry and Gunther Vermier.)
Details have not been announced, except that DST will not be
observed during Ramadan. Guess that DST will stop during the same
Ramadan dates as Morocco, and that Egypt's future spring and fall
transitions will be the same as 2010 when it last observed DST,
namely April's last Friday at 00:00 to September's last Thursday at
23:00 standard time. Also, guess that Ramadan transitions will be
at 00:00 standard time.
Change-Id: I6a20cae02a314871acbd52cb90fcbebd37625810
Elliott Hughes [Tue, 13 May 2014 18:19:57 +0000 (11:19 -0700)]
Consistently use #if defined(__BIONIC__) in tests.
I've also switched some tests to be positive rather than negative,
because !defined is slightly harder to reason about and there are
only two cases: bionic and glibc.
Change-Id: I8d3ac40420ca5aead3e88c69cf293f267273c8ef