| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 478 int IntWrapper::s_destructorCalls = 0; | 478 int IntWrapper::s_destructorCalls = 0; |
| 479 int OffHeapInt::s_destructorCalls = 0; | 479 int OffHeapInt::s_destructorCalls = 0; |
| 480 | 480 |
| 481 class ThreadedTesterBase { | 481 class ThreadedTesterBase { |
| 482 protected: | 482 protected: |
| 483 static void test(ThreadedTesterBase* tester) { | 483 static void test(ThreadedTesterBase* tester) { |
| 484 Vector<std::unique_ptr<WebThread>, numberOfThreads> m_threads; | 484 Vector<std::unique_ptr<WebThread>, numberOfThreads> m_threads; |
| 485 for (int i = 0; i < numberOfThreads; i++) { | 485 for (int i = 0; i < numberOfThreads; i++) { |
| 486 m_threads.append(wrapUnique( | 486 m_threads.append(wrapUnique( |
| 487 Platform::current()->createThread("blink gc testing thread"))); | 487 Platform::current()->createThread("blink gc testing thread"))); |
| 488 m_threads.last()->getWebTaskRunner()->postTask( | 488 m_threads.back()->getWebTaskRunner()->postTask( |
| 489 BLINK_FROM_HERE, | 489 BLINK_FROM_HERE, |
| 490 crossThreadBind(threadFunc, crossThreadUnretained(tester))); | 490 crossThreadBind(threadFunc, crossThreadUnretained(tester))); |
| 491 } | 491 } |
| 492 while (tester->m_threadsToFinish) { | 492 while (tester->m_threadsToFinish) { |
| 493 SafePointScope scope(BlinkGC::NoHeapPointersOnStack); | 493 SafePointScope scope(BlinkGC::NoHeapPointersOnStack); |
| 494 testing::yieldCurrentThread(); | 494 testing::yieldCurrentThread(); |
| 495 } | 495 } |
| 496 delete tester; | 496 delete tester; |
| 497 } | 497 } |
| 498 | 498 |
| (...skipping 6308 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6807 "HeapVector"); | 6807 "HeapVector"); |
| 6808 static_assert( | 6808 static_assert( |
| 6809 WTF::IsGarbageCollectedType<HeapDeque<Member<IntWrapper>>>::value, | 6809 WTF::IsGarbageCollectedType<HeapDeque<Member<IntWrapper>>>::value, |
| 6810 "HeapDeque"); | 6810 "HeapDeque"); |
| 6811 static_assert(WTF::IsGarbageCollectedType< | 6811 static_assert(WTF::IsGarbageCollectedType< |
| 6812 HeapTerminatedArray<Member<IntWrapper>>>::value, | 6812 HeapTerminatedArray<Member<IntWrapper>>>::value, |
| 6813 "HeapTerminatedArray"); | 6813 "HeapTerminatedArray"); |
| 6814 } | 6814 } |
| 6815 | 6815 |
| 6816 } // namespace blink | 6816 } // namespace blink |
| OLD | NEW |