forked from facebook/folly
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Further improve
AsyncGenerator
symmetric transfer test
Summary: (1) ispeters suggested directly comparing stack pointers between generator iterations, which gives a cleaner / faster failure. (2) Per yfeldblum, let's use folly's pthread compatibility shim to explicitly set the stack size, instead of relying on whatever the ambient environment is. Specifically, the primary thread on Mac can have 8MiB of stack as opposed to 512KIB, which suggests that the previous iteration of D61926452 "worked" to detect broken symmetric transfer by a mechanism other than stack overflow. Given a bad complier + code combination, this fails faster and cleaner now, even with the check from (1) commented out. Using `CHECK_EQ` instead of `EXPECT_EQ` in the thread because on an older Mac toolchain, letting an exception fly doesn't promptly terminate the test process. Reviewed By: yfeldblum Differential Revision: D61930597 fbshipit-source-id: d8ddd2091fc8d8a2b4d023459fd89145d07df597
- Loading branch information
1 parent
4663a80
commit a2be2eb
Showing
2 changed files
with
42 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters