Lines Matching full:thread

15 #include "base/threading/thread.h"
31 Thread creator_thread("creator_thread"); in NewObject()
36 DCHECK(result); // We synchronized on thread destruction above. in NewObject()
64 // and delete objects on a background thread.
65 class BackgroundThread : public Thread {
67 BackgroundThread() : Thread("owner_thread") {} in BackgroundThread()
366 // Test that it is OK to create an object that supports WeakPtr on one thread, in TEST()
376 // thread, but use it on another. This tests that we do not trip runtime in TEST()
385 // Move object ownership to another thread by releasing all weak pointers in TEST()
386 // on the original thread first, and then establish WeakPtr on a different in TEST()
387 // thread. in TEST()
394 // Main thread deletes the WeakPtr, then the thread ownership of the in TEST()
399 // Background thread creates WeakPtr(and implicitly owns the object). in TEST()
404 // Main thread creates another WeakPtr, but this does not trigger implicitly in TEST()
405 // thread ownership move. in TEST()
409 // The new WeakPtr is owned by background thread. in TEST()
413 // Target can only be deleted on background thread. in TEST()
425 // Background thread creates WeakPtr. in TEST()
428 // Bind to background thread. in TEST()
434 // Now we should be able to create a new reference from this thread. in TEST()
437 // Re-bind to main thread. in TEST()
440 // And the main thread can now delete the target. in TEST()
453 // Bind to main thread. in TEST()
461 // Re-bind to background thread. in TEST()
464 // And the background thread can now delete the target. in TEST()
469 // Originating thread has a WeakPtr that outlives others. in TEST()
470 // - Main thread creates a WeakPtr in TEST()
471 // - Background thread creates a WeakPtr copy from the one in main thread in TEST()
472 // - Destruct the WeakPtr on background thread in TEST()
473 // - Destruct the WeakPtr on main thread in TEST()
488 // Originating thread drops all references before another thread. in TEST()
489 // - Main thread creates a WeakPtr and passes copy to background thread in TEST()
490 // - Destruct the pointer on main thread in TEST()
491 // - Destruct the pointer on background thread in TEST()
507 // Originating thread invalidates WeakPtrs while its held by other thread. in TEST()
508 // - Main thread creates WeakPtr and passes Copy to background thread in TEST()
509 // - Object gets destroyed on main thread in TEST()
510 // (invalidates WeakPtr on background thread) in TEST()
511 // - WeakPtr gets destroyed on Thread B in TEST()
526 // Main thread creates a Target object. in TEST()
528 // Main thread creates an arrow referencing the Target. in TEST()
540 // Main thread creates a Target object. in TEST()
542 // Main thread creates an arrow referencing the Target. in TEST()
554 // Main thread creates a Target object. in TEST()
556 // Main thread creates an arrow referencing the Target. in TEST()
576 // Main thread creates a Target object. in TEST()
578 // Main thread creates an arrow referencing the Target. in TEST()
586 // The copy is still bound to main thread so I can deref. in TEST()
589 // Although background thread created the copy, it can not deref the copied in TEST()
601 // Main thread creates a Target object. in TEST()
604 // Main thread creates an arrow referencing the Target (so target's in TEST()
605 // thread ownership can not be implicitly moved). in TEST()
610 // Background thread tries to deref target, which violates thread ownership. in TEST()
623 // Main thread creates an arrow referencing the Target. in TEST()
627 // Background thread tries to deref target, binding it to the thread. in TEST()
632 // Main thread deletes Target, violating thread binding. in TEST()
636 // must pass it to the background thread to teardown. in TEST()
647 // Main thread creates an arrow referencing the Target, and references it, so in TEST()
648 // that it becomes bound to the thread. in TEST()
653 // Background thread tries to delete target, volating thread binding. in TEST()
666 // Main thread creates an arrow referencing the Target. in TEST()
670 // Background thread tries to delete target, binding the object to the thread. in TEST()
675 // Main thread attempts to dereference the target, violating thread binding. in TEST()