[R-package] fix MM_PREFETCH and MM_MALLOC checks in configure.ac #3510
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR fixes two bugs in the CRAN package
MM_PREFETCH
andMM_MALLOC
checksint main(...)
scaffolding inMM_PREFETCH
andMM_MALLOC
checks, which was causing them to failMore explanation
Look at the diff for
R-package/configure
and the autoconf documentation on AC_LANG_CONFTEST...autoconf adds that scaffolding for you! So this check wasalways failing for the CRAN package on Mac and Linuxfailing for the CRAN on Mac, because the conftest code has an extraint main(...)
!!NOTE: Once CI runs, I'm going to update this and a table here comparing theMM_MALLOC
andMM_PREFETCH
check results for CRAN vs. CMake builds...I think they'll match now.Comparison of R 4.0 builds
✅ below means
❌ means
Latest commit on
master
: https://github.com/microsoft/LightGBM/actions/runs/338789296MM_PREFETCH ❌
MM_PREFETCH ✅
MM_PREFETCH ✅
MM_PREFETCH ✅
MM_PREFETCH ✅
MM_PREFETCH ✅
this PR: https://github.com/microsoft/LightGBM/actions/runs/338808198
MM_PREFETCH ✅
MM_PREFETCH ✅
MM_PREFETCH ✅
MM_PREFETCH ✅
MM_PREFETCH ✅
MM_PREFETCH ✅
Notes for Reviewers
@StrikerRUS I am really glad you asked me about the compiler used in
R-package/configure.ac
in #3509 (review). I think I misunderstood your question the first time I read it, but that misunderstanding led me to an investigation that resulted in fixing a bug 😀@guolinke I think we should try to get this into 3.1.0 (#3484)