Commit graph

16917 commits

Author SHA1 Message Date
Chih-Hung Hsieh
1a5fd9c155 Fix misc-macro-parentheses warnings in bionic.
Add parentheses around macro arguments used beside operators,
or use constexpr for simple constants.
Bug: 28705665

Change-Id: I378c8aad92d3ec8e8c4b0440b5c2c99dfe01ce79
2016-06-10 15:25:49 -07:00
Treehugger Robot
74669e99ce Merge "Add /vendor/xbin to root's path." 2016-06-08 01:06:49 +00:00
Elliott Hughes
30ad0dd6ad Merge "Preliminary cleanup of <sys/cdefs.h>." 2016-06-07 20:16:26 +00:00
Elliott Hughes
f4840507b5 Preliminary cleanup of <sys/cdefs.h>.
We don't support anything other than Clang and GCC, and we don't support
GCC earlier than 4.9.

Move the various synonyms for __attribute__(__whatever__) together.

Fix a __STDC__VERSION__ (for __STDC_VERSION__) typo.

Drop support for BSD _ANSI_SOURCE and _C99_SOURCE; there's enough confusing
nonsense here already, and plenty of other ways to ask for obsolete standards.

There are plenty more problems here -- what I really want to do is rationalize
our treatment of __STDC_VERSION__ -- but let's get some of this easy stuff
out of the way first.

Bug: https://code.google.com/p/android/issues/detail?id=194631
Change-Id: I7526b9770fdc01f8a4667781b65e2fb08287b20b
2016-06-06 17:35:53 -07:00
Treehugger Robot
d80d42740d Merge "Fix infinite loop if semaphore test is not run." 2016-06-06 22:26:55 +00:00
Christopher Ferris
1783941f23 Fix infinite loop if semaphore test is not run.
When using the --benchmark_filter option, all of the test objects
get created, but not all are run. Previously, if this test didn't run
it would get into an infinite loop waiting for the test to complete.
This change only waits for the test to complete if it was actually
executed.

Change-Id: I5151a0b4b3d5349b978e716ec4a02ebd8b4eae00
2016-06-06 14:13:17 -07:00
Treehugger Robot
901cc14822 Merge "Just use libstdc++ for the cxa stuff inside bionic." 2016-06-06 18:04:54 +00:00
Josh Gao
c5799dd13c Merge changes I32e726c7,I1dc9a708,I09cc335b,Ifb8a66ab,I0e2c25bc, ...
* changes:
  versioner: whitelist atexit, turn on symbol checking by default.
  versioner: add missing test.
  versioner: fix false positive with functions only available as inlines.
  versioner: improve error output slightly.
  versioner: merge stdout and stderr in the test runner.
  versioner: clean up tests, test runner.
  versioner: ignore functions that are __INTRODUCED_IN_FUTURE.
  versioner: autodetect paths when no specified.
  versioner: improve usage messages.
  Remove __cachectl.
2016-06-04 06:06:02 +00:00
Josh Gao
d8c77257ea versioner: whitelist atexit, turn on symbol checking by default.
Change-Id: I32e726c74ee618ace3a4329d46408a42732a8d9d
2016-06-03 15:01:19 -07:00
Josh Gao
4af829acb7 versioner: add missing test.
Change-Id: I1dc9a708b53dbb46af9e4b8ab69bf8ed46ab045f
2016-06-03 15:01:19 -07:00
Josh Gao
958f3b31c4 versioner: fix false positive with functions only available as inlines.
Change-Id: I09cc335b4006c6ceafcbd1bec9e50161f8262942
2016-06-03 15:01:19 -07:00
Josh Gao
173e7c0753 versioner: improve error output slightly.
Print [introduced = 9, deprecated = 10, obsoleted = 11] instead of
[9,10,11].

Change-Id: Ifb8a66abbcec92aa13086d220af7ee6fa17b0897
2016-06-03 15:01:19 -07:00
Josh Gao
658dbd920d versioner: merge stdout and stderr in the test runner.
Some of the error messages emitted by versioner (the ones where it was
invoked incorrectly) go to stderr, which meant that the test runner
ignored them. Merge stdout and stderr, and switch from testing for
exact equality to endswith, because of the compilation errors test.

Change-Id: I0e2c25bcc9dea4c12ea82a6a05b29e561a61a902
2016-06-03 15:01:18 -07:00
Josh Gao
80d909bbfb versioner: clean up tests, test runner.
Git doesn't track empty directories, so most of the tests would fail on
a fresh checkout because of dependencies/common being missing. Remove
the use of dependencies from all of the non-dependency related tests.

Change-Id: I09cc5765aae1576914c1c5d7dfa3fb666eab4a3f
2016-06-03 15:01:18 -07:00
Josh Gao
d67dbf003e versioner: ignore functions that are __INTRODUCED_IN_FUTURE.
Bug: http://b/28178111
Change-Id: I8026181e08ed8f2d59b31a37adcf8b469fb6bdaf
2016-06-03 15:01:18 -07:00
Josh Gao
9b5af7ad5e versioner: autodetect paths when no specified.
Search for the header/dependency/platform directories in a hard-coded
path relative to $ANDROID_BUILD_TOP when they're not specified.

Change-Id: I476385cfc0247e3b2009348ec37c1810a0e9a7f7
2016-06-03 15:01:18 -07:00
Josh Gao
62aaf8f8fe versioner: improve usage messages.
Don't spew all of usage when called improperly, and add a -h option
that exits cleanly.

Change-Id: I1a4517edce75afe0f9a80bc8d6c81353d6c12e99
2016-06-03 15:01:18 -07:00
Josh Gao
99a84c8316 Remove __cachectl.
bionic doesn't have an implementation for this function, but neither
does the kernel. cachectl has existed in the kernel as a stub that
returns ENOSYS for over a decade.

Bug: http://b/28178111
Change-Id: Id35f85fd143c5ea0d45d04b1021893cf5c0c749d
2016-06-03 15:01:18 -07:00
Treehugger Robot
f21ca653b7 Merge "Fix __errordecl on clang." 2016-06-03 19:29:12 +00:00
Chih-hung Hsieh
e7d75a5d43 Merge "Fix misc-macro-parentheses warnings in bionic/tests." 2016-06-03 18:46:42 +00:00
Treehugger Robot
c42811e5bc Merge "Remove __brk" 2016-06-03 18:27:45 +00:00
Josh Gao
8ba4424a41 Fix __errordecl on clang.
__attribute__((__error__)) doesn't exist on clang.

Bug: http://b/28381737
Change-Id: I75f39308ecfd60164811958fa40c9b96c92fd329
2016-06-03 10:36:37 -07:00
Chih-Hung Hsieh
d61ca37d35 Fix misc-macro-parentheses warnings in bionic/tests.
Bug: 28705665
Change-Id: I532205b94e30acbdc97f3f4db0660c9a16a7de89
2016-06-03 10:18:07 -07:00
Dimitry Ivanov
71e783d8a4 Remove __brk
The symbol is unused and deprecated

Bug: http://b/29005114
Change-Id: I5e99c8b029514e8b2405a1eec23ac8941374a8a4
2016-06-03 08:33:51 -07:00
Treehugger Robot
a24cc2639f Merge "Do not return with stack address in global variable." 2016-06-02 22:57:51 +00:00
Chih-Hung Hsieh
9af13d24b1 Do not return with stack address in global variable.
Clang static analyzer gives warning when address of
local variable 'attr' is saved in a global variable.
This change passes required values down to signal handler
instead of saving local variable address in a signal handler.

Change-Id: I7955939487a5afdf7b1f47eb74a92eb5aa76cfc9
2016-06-02 15:02:25 -07:00
Treehugger Robot
d23c37bc3f Merge changes I1bb1925a,Icd638673
* changes:
  versioner: introduce.
  Update header versions for NDK platform fixes.
2016-06-02 21:29:48 +00:00
Josh Gao
bf8a285e64 versioner: introduce.
Add a clang-based tool to inspect header availability attributes and
verify them against the NDK platform definitions.

Bug: http://b/28178111
Change-Id: I1bb1925a620e98cc9606cb5a3360b1224c700bd0
2016-06-02 13:40:36 -07:00
Josh Gao
46b44160e9 Update header versions for NDK platform fixes.
Bug: http://b/28178111
Change-Id: Icd638673b409aa43a91490f77c6b4d79c9ea20d9
2016-06-02 13:40:35 -07:00
Colin Cross
8428fb03c8 Merge "Remove deprecated Android.mk files" 2016-06-02 16:31:40 +00:00
Treehugger Robot
e20730ca0b Merge "Remove declaration for __brk." 2016-06-02 02:25:59 +00:00
Josh Gao
8a48d9d63b Merge "Fix .clang-format ContinuationIndentWidth." 2016-06-02 01:21:42 +00:00
Josh Gao
6e9c1f61d8 Remove declaration for __brk.
Bug: http://b/28178111
Change-Id: I972789cd5da552000c32fd107b9df98330323d89
2016-06-01 18:21:06 -07:00
Josh Gao
5a9d5691a4 Fix .clang-format ContinuationIndentWidth.
Change-Id: If41900122accb2c1ebf012bfa07de9b0fa9690fc
2016-06-01 18:20:15 -07:00
Erik Kline
9a29c3f241 Add /vendor/xbin to root's path.
Bug: 28850734
Change-Id: Ibfc5ae019bec2efe6d188bacdd7fb009178fc837
2016-05-30 12:06:11 +09:00
Elliott Hughes
816fab9538 Just use libstdc++ for the cxa stuff inside bionic.
We have an explicit link map now, so we don't need a separate copy of libstdc++
that's built with -fvisibility=hidden.

Bug: http://b/29009180
Change-Id: I2d794d62f52621e6ad258ca6d455f9bd3830d829
2016-05-27 17:57:46 -07:00
Treehugger Robot
676f6e3c7f Merge "Remove libstdc++ include files." 2016-05-27 23:36:18 +00:00
Elliott Hughes
f44b232d85 Remove libstdc++ include files.
We still need <new> for bionic, and to build libstdc++.

Change-Id: Ic7b26340576a5355007a06db9c1bec395be49ae1
2016-05-27 15:49:31 -07:00
Elliott Hughes
2f82dc50ed Merge "Improve diagnostics from the assembler __strcpy_chk routines." 2016-05-27 15:19:09 +00:00
Colin Cross
7510c33b61 Remove deprecated Android.mk files
These directories all have Android.bp files that are always used now,
delete the Android.mk files.

Change-Id: Ib0ba2d28bff88483b505426ba61606da314e03ab
2016-05-26 16:41:57 -07:00
Elliott Hughes
bdd8f896dd Improve diagnostics from the assembler __strcpy_chk routines.
Change-Id: Ib95b598f7f8338cc1a618c00232a4259dc4a6319
2016-05-26 16:38:34 -07:00
Treehugger Robot
a3c2df9378 Merge "Improve diagnostics from the assembler __strcat_chk routines." 2016-05-26 23:01:25 +00:00
Elliott Hughes
c75da09f4f Improve diagnostics from the assembler __strcat_chk routines.
Change-Id: I44cbe5389c66de6618e581a6e302eea22c39d6fb
2016-05-26 14:55:00 -07:00
Treehugger Robot
fdedd86070 Merge "Update the "adding a syscall" docs." 2016-05-26 21:41:21 +00:00
Elliott Hughes
e2bfe2afaf Update the "adding a syscall" docs.
Change-Id: I78adafb1c1c491f641a82a02ad7f03cd3f8c7d1e
2016-05-26 13:55:37 -07:00
Treehugger Robot
8c2467ae07 Merge "Don't use __u64/__u32 in <sys/user.h>." 2016-05-26 00:19:14 +00:00
Josh Gao
bb129214ad Don't use __u64/__u32 in <sys/user.h>.
The typedefs for __u64 and __u32 aren't in scope in this file, so
switch fields declared with these to use the matching underlying type.

Bug: http://b/28178111
Change-Id: Id4eec1f7dc81d77e78043227c15e621debe3a48a
2016-05-25 15:25:13 -07:00
Christopher Ferris
e85de5b103 Merge "Update documentation for malloc debug." 2016-05-25 20:37:46 +00:00
Christopher Ferris
eab4803290 Update documentation for malloc debug.
Add a new document that describes the previous version of malloc debug.

Add a small update to the current documentation to indicate it only
applies to N and later.

Change-Id: Ief74c253ba79018777aa688bde7f5b35319fa4d4
2016-05-25 13:34:54 -07:00
Dimitry Ivanov
5fa5717674 Merge "Correctly handle the case of empty LD_PRELOAD entries" 2016-05-24 23:13:06 +00:00