Lower the number of threads for some threading tests when testing on ARM to avoid...
authorsgjesse@chromium.org <sgjesse@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Mon, 11 Jul 2011 12:17:10 +0000 (12:17 +0000)
committersgjesse@chromium.org <sgjesse@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Mon, 11 Jul 2011 12:17:10 +0000 (12:17 +0000)
R=ricow@chromium.org

BUG=none
TEST=cctest/test-lockers/LockerUnlocker,cctest/test-lockers/LockTwiceAndUnlock,cctest/test-lockers/SeparateIsolatesLocksNonexclusive

Review URL: http://codereview.chromium.org//7334007

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8597 ce2b1a6d-e550-0410-aec6-3dcde31c8c00

test/cctest/test-lockers.cc

index 4579361..2b184e9 100644 (file)
@@ -314,7 +314,11 @@ class SeparateIsolatesLocksNonexclusiveThread : public JoinableThread {
 
 // Run parallel threads that lock and access different isolates in parallel
 TEST(SeparateIsolatesLocksNonexclusive) {
+#ifdef V8_TARGET_ARCH_ARM
+  const int kNThreads = 50;
+#else
   const int kNThreads = 100;
+#endif
   v8::Isolate* isolate1 = v8::Isolate::New();
   v8::Isolate* isolate2 = v8::Isolate::New();
   i::List<JoinableThread*> threads(kNThreads);
@@ -383,7 +387,11 @@ class LockerUnlockerThread : public JoinableThread {
 
 // Use unlocker inside of a Locker, multiple threads.
 TEST(LockerUnlocker) {
+#ifdef V8_TARGET_ARCH_ARM
+  const int kNThreads = 50;
+#else
   const int kNThreads = 100;
+#endif
   i::List<JoinableThread*> threads(kNThreads);
   v8::Isolate* isolate = v8::Isolate::New();
   for (int i = 0; i < kNThreads; i++) {
@@ -431,7 +439,11 @@ class LockTwiceAndUnlockThread : public JoinableThread {
 
 // Use Unlocker inside two Lockers.
 TEST(LockTwiceAndUnlock) {
+#ifdef V8_TARGET_ARCH_ARM
+  const int kNThreads = 50;
+#else
   const int kNThreads = 100;
+#endif
   i::List<JoinableThread*> threads(kNThreads);
   v8::Isolate* isolate = v8::Isolate::New();
   for (int i = 0; i < kNThreads; i++) {