Skip to content

Conversation

@wonglkd
Copy link
Contributor

@wonglkd wonglkd commented Feb 28, 2023

XDCHECK (or XCHECK) fails here for gcc-8.x in a lambda, so we move it outside. This occurs in CacheBench's AsyncCacheStressor.h.

/__w/CacheLib/CacheLib/cachelib/../cachelib/cachebench/runner/AsyncCacheStressor.h:306:7:
internal compiler error: in cp_build_addr_expr_1, at cp/typeck.c:5965

This line compiled fine with 8.5 before Jan 2023 so I suspect a regression in folly or other external library. It still compiles fine with gcc-7.5, 9.4, and 11.3.1. Possibly related commits: facebook/folly@1aafad4 and facebook/folly@e6d09f6

Line of gcc-8.5 that it fails on: https://github.com/gcc-mirror/gcc/blob/releases/gcc-8.5.0/gcc/cp/typeck.c#L5965

The version that isn't in a lambda compiles just fine:

XDCHECK(req.sizeBegin + 1 != req.sizeEnd);

Test Plan: GitHub actions. Built fine on my fork with CentOS 8.5/gcc-8.5. This issue currently causes 3 builds that use gcc-8.5 to fail (2 CentOS and RockyLinux-8.6) and 1 build using gcc-8.3 (Debian).

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Feb 28, 2023
@wonglkd wonglkd mentioned this pull request Feb 28, 2023
4 tasks
@wonglkd
Copy link
Contributor Author

wonglkd commented Feb 28, 2023

All builds now pass, except for Debian, which should be fixed by #200. (Also excluding the rpm-builds.) Ready for review.

@wonglkd wonglkd changed the title Replace XDCHECK in lambda with assert for gcc-8.5 Replace XDCHECK in lambda with assert for gcc-8.x Feb 28, 2023
@wonglkd wonglkd changed the title Replace XDCHECK in lambda with assert for gcc-8.x Fix XDCHECK regression in lambda for gcc-8.x Mar 1, 2023
@facebook-github-bot
Copy link
Contributor

@jaesoo-fb has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

@facebook-github-bot
Copy link
Contributor

@jaesoo-fb merged this pull request in 293118b.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. Merged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants