Compare commits

...

34 Commits

Author SHA1 Message Date
The Android Automerger
7ed993ad49 merge in mnc-dr-release history after reset to mnc-dr-dev 2015-10-02 05:51:20 -07:00
Christopher Ferris
4f3e3591ac am 93a91f0c: Force cts to only run one test at a time.
* commit '93a91f0cf4f015762ac1ed57395c4c0de8ba7db3':
  Force cts to only run one test at a time.
2015-09-29 15:11:45 +00:00
Christopher Ferris
93a91f0cf4 Force cts to only run one test at a time.
Also, slightly increase the timeout for each test run.

Bug: 24198050

(cherry picked from commit daaaed18ce)

Change-Id: I29e169e962da803a89abf0a28e071abcafa315b7
2015-09-25 15:33:20 -07:00
The Android Automerger
984ffc98f3 merge in mnc-dr-release history after reset to mnc-dr-dev 2015-09-24 01:01:51 -07:00
Yabin Cui
01030c24b0 Increase alternative signal stack size on 64-bit devices.
Bug: 23041777
Bug: 24187462
Change-Id: I7d84c0cc775a74753a3e8e101169c0fb5dbf7437
2015-09-23 16:36:20 -07:00
The Android Automerger
22af16f113 merge in mnc-dr-release history after reset to mnc-dr-dev 2015-08-26 01:01:31 -07:00
The Android Automerger
0aa018ccc0 merge in mnc-dr-release history after reset to mnc-dr-dev 2015-08-12 01:00:55 -07:00
The Android Automerger
b97c8b4024 merge in mnc-dr-release history after reset to mnc-dr-dev 2015-07-28 01:01:08 -07:00
The Android Automerger
2e8ac0b72c merge in mnc-dr-release history after reset to mnc-dr-dev 2015-07-25 01:01:52 -07:00
The Android Automerger
b6b6fcfa31 merge in mnc-dr-release history after reset to mnc-dr-dev 2015-07-23 01:00:43 -07:00
The Android Automerger
f117eb873b merge in mnc-dr-release history after reset to mnc-dr-dev 2015-07-22 01:01:18 -07:00
The Android Automerger
89fddb56ed merge in mnc-dr-release history after reset to mnc-dr-dev 2015-07-14 01:00:58 -07:00
The Android Automerger
b530200ef3 merge in mnc-dr-release history after reset to mnc-dr-dev 2015-07-11 01:00:59 -07:00
The Android Automerger
d5887751b2 merge in mnc-dr-release history after reset to mnc-dr-dev 2015-07-06 16:02:04 -07:00
The Android Automerger
2cddffe900 merge in mnc-release history after reset to mnc-dev 2015-06-18 01:00:43 -07:00
The Android Automerger
04363e4437 merge in mnc-release history after reset to mnc-dev 2015-06-17 01:00:50 -07:00
The Android Automerger
01c72f8c1c merge in mnc-release history after reset to mnc-dev 2015-06-16 01:00:37 -07:00
The Android Automerger
0e7aca1dff merge in mnc-release history after reset to mnc-dev 2015-06-15 11:57:26 -07:00
The Android Automerger
1a78032e30 merge in mnc-release history after reset to mnc-dev 2015-06-13 01:00:53 -07:00
The Android Automerger
64eb843f74 merge in mnc-release history after reset to mnc-dev 2015-06-11 01:00:38 -07:00
The Android Automerger
8b18a3c922 merge in mnc-release history after reset to mnc-dev 2015-06-09 01:00:42 -07:00
The Android Automerger
741df2881b merge in mnc-release history after reset to mnc-dev 2015-06-07 01:00:29 -07:00
The Android Automerger
9660d32e74 merge in mnc-release history after reset to mnc-dev 2015-06-06 01:01:01 -07:00
The Android Automerger
2ff7422771 merge in mnc-release history after reset to mnc-dev 2015-06-03 01:01:03 -07:00
The Android Automerger
3619d6b922 merge in mnc-release history after reset to mnc-dev 2015-06-02 01:00:48 -07:00
The Android Automerger
2783166c35 merge in mnc-release history after reset to mnc-dev 2015-05-30 01:01:05 -07:00
Dmitriy Ivanov
c3351ea94d Work around incorrect dt_needed entries
This applies for apps targeting sdk<=22 and
  only for lp32 platforms.

Bug: http://b/21364029
Change-Id: I903e81c9ccda2a8beaba1d132d68c77d30a4cdb2
(cherry picked from commit d974e88046)
2015-05-28 17:42:27 -07:00
The Android Automerger
730c0a475c merge in mnc-release history after reset to mnc-dev 2015-05-28 01:00:47 -07:00
The Android Automerger
c8e23a4c1a merge in mnc-release history after reset to mnc-dev 2015-05-23 01:00:56 -07:00
The Android Automerger
4d49212a5f merge in mnc-release history after reset to mnc-dev 2015-05-21 01:00:54 -07:00
The Android Automerger
aa3ef00a43 merge in mnc-release history after reset to mnc-dev 2015-05-19 01:01:19 -07:00
The Android Automerger
304307243f merge in mnc-release history after reset to mnc-dev 2015-05-17 01:00:23 -07:00
The Android Automerger
51d3926d8a merge in mnc-release history after reset to mnc-dev 2015-05-16 01:00:43 -07:00
John Reck
4cb434df9b Fix regression in crash reporting
Bug: 19532651

Partial revert of be0e43b776

Change-Id: I99e220328aff985facb920ebcd84ac1a016759b5
2015-05-15 15:12:36 -07:00
5 changed files with 44 additions and 6 deletions

View File

@@ -130,8 +130,13 @@ __LIBC_HIDDEN__ void pthread_key_clean_all(void);
*/
#define PTHREAD_STACK_SIZE_DEFAULT ((1 * 1024 * 1024) - SIGSTKSZ)
/* Leave room for a guard page in the internally created signal stacks. */
// Leave room for a guard page in the internally created signal stacks.
#if defined(__LP64__)
// SIGSTKSZ is not big enough for 64-bit arch. See http://b/23041777.
#define SIGNAL_STACK_SIZE (16 * 1024 + PAGE_SIZE)
#else
#define SIGNAL_STACK_SIZE (SIGSTKSZ + PAGE_SIZE)
#endif
/* Needed by fork. */
__LIBC_HIDDEN__ extern void __bionic_atfork_run_prepare();

View File

@@ -241,7 +241,12 @@ libBionicCtsGtestMain_src_files := gtest_main.cpp
libBionicCtsGtestMain_cflags := $(test_cflags)
libBionicCtsGtestMain_cppflags := $(test_cppflags) -DUSING_GTEST_OUTPUT_FORMAT
libBionicCtsGtestMain_cppflags := $(test_cppflags) -DUSING_GTEST_OUTPUT_FORMAT \
# Temporarily fix the job count to 1 for CTS since on some devices the
# number of online cores is incorrectly read as the total number of cores
# in the system. When b/24376925 is fixed, this should be removed.
libBionicCtsGtestMain_cppflags += -DJOB_COUNT_FIXED=1
module := libBionicCtsGtestMain
module_tag := optional

View File

@@ -59,7 +59,7 @@ using testing::internal::COLOR_GREEN;
using testing::internal::COLOR_YELLOW;
using testing::internal::ColoredPrintf;
constexpr int DEFAULT_GLOBAL_TEST_RUN_DEADLINE_MS = 60000;
constexpr int DEFAULT_GLOBAL_TEST_RUN_DEADLINE_MS = 90000;
constexpr int DEFAULT_GLOBAL_TEST_RUN_WARNLINE_MS = 2000;
// The time each test can run before killed for the reason of timeout.
@@ -839,8 +839,12 @@ static bool RunTestInSeparateProc(int argc, char** argv, std::vector<TestCase>&
return all_tests_passed;
}
static size_t GetProcessorCount() {
static size_t GetDefaultJobCount() {
#if defined(JOB_COUNT_FIXED)
return JOB_COUNT_FIXED;
#else
return static_cast<size_t>(sysconf(_SC_NPROCESSORS_ONLN));
#endif
}
static void AddPathSeparatorInTestProgramPath(std::vector<char*>& args) {
@@ -950,7 +954,7 @@ static bool PickOptions(std::vector<char*>& args, IsolationTestOptions& options)
}
// Init default isolation test options.
options.job_count = GetProcessorCount();
options.job_count = GetDefaultJobCount();
options.test_deadline_ms = DEFAULT_GLOBAL_TEST_RUN_DEADLINE_MS;
options.test_warnline_ms = DEFAULT_GLOBAL_TEST_RUN_WARNLINE_MS;
options.gtest_color = testing::GTEST_FLAG(color);

View File

@@ -27,6 +27,7 @@
#include <sys/syscall.h>
#include <time.h>
#include <unistd.h>
#include <unwind.h>
#include <atomic>
#include <regex>
@@ -1571,3 +1572,26 @@ TEST_F(pthread_DeathTest, pthread_mutex_unlock_null_64) {
GTEST_LOG_(INFO) << "This test tests bionic implementation details on 64 bit devices.";
#endif
}
extern _Unwind_Reason_Code FrameCounter(_Unwind_Context* ctx, void* arg);
static volatile bool signal_handler_on_altstack_done;
static void SignalHandlerOnAltStack(int signo, siginfo_t*, void*) {
ASSERT_EQ(SIGUSR1, signo);
// Check if we have enough stack space for unwinding.
int count = 0;
_Unwind_Backtrace(FrameCounter, &count);
ASSERT_GT(count, 0);
// Check if we have enough stack space for logging.
std::string s(2048, '*');
GTEST_LOG_(INFO) << s;
signal_handler_on_altstack_done = true;
}
TEST(pthread, big_enough_signal_stack_for_64bit_arch) {
signal_handler_on_altstack_done = false;
ScopedSignalHandler handler(SIGUSR1, SignalHandlerOnAltStack, SA_SIGINFO | SA_ONSTACK);
kill(getpid(), SIGUSR1);
ASSERT_TRUE(signal_handler_on_altstack_done);
}

View File

@@ -34,7 +34,7 @@
#define noinline __attribute__((__noinline__))
#define __unused __attribute__((__unused__))
static _Unwind_Reason_Code FrameCounter(_Unwind_Context* ctx __unused, void* arg) {
_Unwind_Reason_Code FrameCounter(_Unwind_Context* ctx __unused, void* arg) {
int* count_ptr = reinterpret_cast<int*>(arg);
#if SHOW_FRAME_LOCATIONS