Commit Graph

5181 Commits

Author SHA1 Message Date
Elliott Hughes
5995bf880e Merge "don't hardcode register r0/v1 when reading the TLS" 2013-06-17 21:51:50 +00:00
Mathias Agopian
b6e340080a don't hardcode register r0/v1 when reading the TLS
this leads to much improved code when calling __get_tls()

Change-Id: I21d870fb33c33a921ca55c4e100772e0f7a8d1e4
2013-06-17 14:50:30 -07:00
Colin Cross
37d9f75dde bionic: add tests for properties
Change-Id: I09b212966f1c9624631653ef2c7a71de78bbbec1
2013-06-17 12:58:18 -07:00
Colin Cross
dc1038b790 bionic: move system property writing from init to bionic
Move the implementation of writing to the system property area
from init to bionic, next to the reader implementation.  This
will allow full property testing to be added to bionic tests.

Add new accessor and waiting functions to hide the implementation
from watchprops and various bionic users.

Also hide some of the implementation details of the property area
from init by moving them into _system_properties.h, and other details
from everybody by moving them into system_properties.h.

Change-Id: I9026e604109e30546b2849b60cab2e7e5ff00ba5
2013-06-17 12:44:34 -07:00
Elliott Hughes
a658ed09e5 am afd4e299: am 657d0da7: Merge "Slight script cleanup; make gensyscalls work from any directory."
* commit 'afd4e2999c3e726498c407fcaf9cccdcd4d24637':
  Slight script cleanup; make gensyscalls work from any directory.
2013-06-17 11:22:01 -07:00
Elliott Hughes
afd4e2999c am 657d0da7: Merge "Slight script cleanup; make gensyscalls work from any directory."
* commit '657d0da7513e01b0eb104c8a8a522c28fdbc807d':
  Slight script cleanup; make gensyscalls work from any directory.
2013-06-17 11:18:58 -07:00
Elliott Hughes
657d0da751 Merge "Slight script cleanup; make gensyscalls work from any directory." 2013-06-17 18:16:36 +00:00
Elliott Hughes
18bc975bfe Slight script cleanup; make gensyscalls work from any directory.
Also remove a ton of dead code.

Change-Id: I1315623695a004f643b155f121cbafe24b715b8a
2013-06-17 10:39:33 -07:00
Chad Brubaker
638503b515 Fix remove_uidiface_info failing on first entry
Change-Id: Ic23506581ff835a6b679e1593eab550a84548056
2013-06-14 15:25:42 -07:00
Elliott Hughes
8f5440c486 am c1e4183c: am 560e9f7e: Merge "Ensure that <stdint.h> defines SIZE_MAX and friends."
* commit 'c1e4183c7ad6943f9cc44fe0b769884370a739cd':
  Ensure that <stdint.h> defines SIZE_MAX and friends.
2013-06-13 18:04:19 -07:00
Elliott Hughes
c1e4183c7a am 560e9f7e: Merge "Ensure that <stdint.h> defines SIZE_MAX and friends."
* commit '560e9f7e7a39e02aca96709043ca06f562f75d58':
  Ensure that <stdint.h> defines SIZE_MAX and friends.
2013-06-13 16:21:55 -07:00
Elliott Hughes
560e9f7e7a Merge "Ensure that <stdint.h> defines SIZE_MAX and friends." 2013-06-13 23:19:09 +00:00
Elliott Hughes
7c89506e3a Ensure that <stdint.h> defines SIZE_MAX and friends.
We were missing SIG_ATOMIC_MAX, SIG_ATOMIC_MIN, SIZE_MAX,
WCHAR_MAX, WCHAR_MIN, WINT_MAX, and WINT_MIN.

Change-Id: I2535f36bc220fbaea009b483599b7af811c4cb5c
2013-06-13 16:02:53 -07:00
Elliott Hughes
fa3af2dd67 am af975b07: am c843a3e7: Merge "Fix the qsort copyright notice (fixed upstream this afternoon)."
* commit 'af975b076f79b35cb115c0f77fc8fc0e5d3dba67':
  Fix the qsort copyright notice (fixed upstream this afternoon).
2013-06-12 17:51:25 -07:00
Elliott Hughes
af975b076f am c843a3e7: Merge "Fix the qsort copyright notice (fixed upstream this afternoon)."
* commit 'c843a3e7b215bca5e896e1d56c2fa6332770ea83':
  Fix the qsort copyright notice (fixed upstream this afternoon).
2013-06-12 17:46:57 -07:00
Elliott Hughes
c843a3e7b2 Merge "Fix the qsort copyright notice (fixed upstream this afternoon)." 2013-06-13 00:44:05 +00:00
Elliott Hughes
4eeec44e29 Fix the qsort copyright notice (fixed upstream this afternoon).
Change-Id: I786feb42719bceaa7da91565e350c1333b0d301f
2013-06-12 17:42:43 -07:00
Elliott Hughes
050374836f am ddbf561e: am c843d766: Merge "Handles spurious wake-ups in pthread_join()"
* commit 'ddbf561e5ee8f16fc15d26b085d19ce6abf7e4e0':
  Handles spurious wake-ups in pthread_join()
2013-06-12 17:38:26 -07:00
Elliott Hughes
de1b73dd70 am 7ae23868: am 92e841d0: Merge "Take upstream libm changes."
* commit '7ae23868b4741f9b1af874ebbb13ec3ba930d679':
  Take upstream libm changes.
2013-06-12 17:35:02 -07:00
Elliott Hughes
ddbf561e5e am c843d766: Merge "Handles spurious wake-ups in pthread_join()"
* commit 'c843d7667ada205ecbaf773531067076ed4ad271':
  Handles spurious wake-ups in pthread_join()
2013-06-12 17:34:17 -07:00
Elliott Hughes
c843d7667a Merge "Handles spurious wake-ups in pthread_join()" 2013-06-13 00:31:50 +00:00
Elliott Hughes
7ae23868b4 am 92e841d0: Merge "Take upstream libm changes."
* commit '92e841d0aa8d118882a74e3c3fc4b6a6062dcc09':
  Take upstream libm changes.
2013-06-12 17:30:59 -07:00
msg555
0f020d18b1 Handles spurious wake-ups in pthread_join()
Removed 'join_count' from pthread_internal_t and switched to using the flag
PTHREAD_ATTR_FLAG_JOINED to indicate if a thread is being joined. Combined with
a switch to a while loop in pthread_join, this fixes spurious wake-ups but
prevents a thread from being joined multiple times. This is fine for
two reasons:

1) The pthread_join specification allows for undefined behavior when multiple
   threads try to join a single thread.

2) There is no thread safe way to allow multiple threads to join a single
   thread with the pthread interface.  The second thread calling pthread_join
   could be pre-empted until the thread is destroyed and its handle reused for
   a different thread.  Therefore multi-join is always an error.

Bug: https://code.google.com/p/android/issues/detail?id=52255
Change-Id: I8b6784d47620ffdcdbfb14524e7402e21d46c5f7
2013-06-12 17:30:58 -07:00
Elliott Hughes
92e841d0aa Merge "Take upstream libm changes." 2013-06-13 00:29:21 +00:00
Elliott Hughes
78419467a2 Take upstream libm changes.
Mostly workarounds for GCC and Clang bugs.

Change-Id: I4ef428a42d4ac6d622659053711a8cc416925727
2013-06-12 16:37:58 -07:00
Elliott Hughes
b0cd876974 am 5065eef8: am 6a44d227: Merge "Take some fixed upstream copyright headers and regenerate NOTICE."
* commit '5065eef801aa78a8a64a016fcf644a6ca91a8133':
  Take some fixed upstream copyright headers and regenerate NOTICE.
2013-06-12 16:23:33 -07:00
Elliott Hughes
5065eef801 am 6a44d227: Merge "Take some fixed upstream copyright headers and regenerate NOTICE."
* commit '6a44d2271f372d0c65b05a5d3377bd00ce92824e':
  Take some fixed upstream copyright headers and regenerate NOTICE.
2013-06-12 16:16:09 -07:00
Elliott Hughes
6a44d2271f Merge "Take some fixed upstream copyright headers and regenerate NOTICE." 2013-06-12 23:13:34 +00:00
Elliott Hughes
3267163200 am 5f4d2df2: am 55189a0f: Merge "Switch to current upstream stdio makebuf.c and setvbuf.c."
* commit '5f4d2df2fcddfe62f9e08d1607a8c4e029f01b3d':
  Switch to current upstream stdio makebuf.c and setvbuf.c.
2013-06-12 16:03:49 -07:00
Elliott Hughes
2815b1dd45 Take some fixed upstream copyright headers and regenerate NOTICE.
Change-Id: Ifff41d69c13322dbc6f928ce7d4c65f76fe36772
2013-06-12 16:00:41 -07:00
Elliott Hughes
5f4d2df2fc am 55189a0f: Merge "Switch to current upstream stdio makebuf.c and setvbuf.c."
* commit '55189a0fbd26cfd84939d9d3a42a1800a63bd2c5':
  Switch to current upstream stdio makebuf.c and setvbuf.c.
2013-06-12 15:58:41 -07:00
Elliott Hughes
55189a0fbd Merge "Switch to current upstream stdio makebuf.c and setvbuf.c." 2013-06-12 22:56:20 +00:00
Elliott Hughes
460b70d063 am dc5f5f85: am f1867d47: Merge "Revert "Add SIZE_MAX to <stdint.h> in a way that might actually work.""
* commit 'dc5f5f857c7bf218d33212044539eb73b3fab5f1':
  Revert "Add SIZE_MAX to <stdint.h> in a way that might actually work."
2013-06-12 15:26:46 -07:00
Elliott Hughes
677ee56477 Switch to current upstream stdio makebuf.c and setvbuf.c.
Change-Id: I4761b5e94459815520f01062eef39abf62af621f
2013-06-12 15:24:15 -07:00
Elliott Hughes
dc5f5f857c am f1867d47: Merge "Revert "Add SIZE_MAX to <stdint.h> in a way that might actually work.""
* commit 'f1867d47cbce4225d712a2684da67031f7350909':
  Revert "Add SIZE_MAX to <stdint.h> in a way that might actually work."
2013-06-12 15:22:04 -07:00
Elliott Hughes
f1867d47cb Merge "Revert "Add SIZE_MAX to <stdint.h> in a way that might actually work."" 2013-06-12 22:19:03 +00:00
Elliott Hughes
9248d3a58c Revert "Add SIZE_MAX to <stdint.h> in a way that might actually work."
This reverts commit d8627af159 which caused build breakage:

In file included from bionic/libc/include/limits.h:86:0,
                 from bionic/libc/include/stdint.h:33,
                 from bionic/libc/arch-arm/bionic/crtbegin.c:31:
bionic/libc/include/sys/limits.h:30:26: fatal error: linux/limits.h: No such file or directory
compilation terminated.
make: *** [out/target/product/generic/obj/lib/crtbegin_dynamic1.o] Error 1

Change-Id: I128095ecb99df92626e1f57e34c61e08c98a4078
2013-06-12 22:18:47 +00:00
Elliott Hughes
7e06ab5655 am b0a2262c: am 55c5ec64: Merge "Add SIZE_MAX to <stdint.h> in a way that might actually work."
* commit 'b0a2262c3f91085e79c3fd491379e45821254427':
  Add SIZE_MAX to <stdint.h> in a way that might actually work.
2013-06-12 15:11:12 -07:00
Elliott Hughes
b0a2262c3f am 55c5ec64: Merge "Add SIZE_MAX to <stdint.h> in a way that might actually work."
* commit '55c5ec64bd26d92bd1882a9a4c91445de73ebfa2':
  Add SIZE_MAX to <stdint.h> in a way that might actually work.
2013-06-12 15:06:51 -07:00
Elliott Hughes
55c5ec64bd Merge "Add SIZE_MAX to <stdint.h> in a way that might actually work." 2013-06-12 22:05:10 +00:00
Elliott Hughes
7ac852fb05 am 3da47942: am 944ea1a3: Merge "Clean up abort."
* commit '3da47942d3fdeb6f39cf84b03c75cfeb69f91449':
  Clean up abort.
2013-06-12 15:02:34 -07:00
Elliott Hughes
3da47942d3 am 944ea1a3: Merge "Clean up abort."
* commit '944ea1a32018c44d6cb55c9454e670b0e152da6d':
  Clean up abort.
2013-06-12 14:58:32 -07:00
Elliott Hughes
d8627af159 Add SIZE_MAX to <stdint.h> in a way that might actually work.
Take two.

Change-Id: I7d08b6d14c82a171312a7f5898270b4441d5cfa2
2013-06-12 14:54:16 -07:00
Elliott Hughes
944ea1a320 Merge "Clean up abort." 2013-06-12 21:53:58 +00:00
Elliott Hughes
61e699a133 Clean up abort.
* A dlmalloc usage error shouldn't call abort(3) because we want to
  cause a SIGSEGV by writing the address dlmalloc didn't like to an
  address the kernel won't like, so that debuggerd will dump the
  memory around the address that upset dlmalloc.

* Switch to the simpler FreeBSD/NetBSD style of registering stdio
  cleanup. Hopefully this will let us simplify more of the stdio
  implementation.

* Clear the stdio cleanup handler before we abort because of a dlmalloc
  corruption error. This fixes the reported bug, where we'd hang inside
  dlmalloc because the stdio cleanup reentered dlmalloc.

Bug: 9301265
Change-Id: Ief31b389455d6876e5a68f0f5429567d37277dbc
2013-06-12 14:14:53 -07:00
Elliott Hughes
1e88a7abca am 834f83de: am 5cde15eb: Merge "<stdint.h> should expose SIZE_MAX."
* commit '834f83de3f3363090385963eef1cd9a053a51a71':
  <stdint.h> should expose SIZE_MAX.
2013-06-12 11:05:18 -07:00
Elliott Hughes
834f83de3f am 5cde15eb: Merge "<stdint.h> should expose SIZE_MAX."
* commit '5cde15eb17f4ddc0949c0cbd38a46e6c0bad7019':
  <stdint.h> should expose SIZE_MAX.
2013-06-12 10:58:23 -07:00
Elliott Hughes
5cde15eb17 Merge "<stdint.h> should expose SIZE_MAX." 2013-06-12 17:56:24 +00:00
Elliott Hughes
2c157aec9b <stdint.h> should expose SIZE_MAX.
Change-Id: Id27222c24955c83f29ad953933cbdc48b6f1e900
2013-06-12 10:28:26 -07:00
Nick Kralevich
6d88e4e96b am 26cc1d68: am b6e88020: Merge "fix unittests."
* commit '26cc1d6838c0c4fd18abbf6ea5a38d24aea93893':
  fix unittests.
2013-06-11 16:03:32 -07:00