-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ARROW-13507: [R] LTO job on CRAN fails #10849
Conversation
git clone https://github.com/nealrichardson/r-debug.git | ||
git checkout lto | ||
cd r-debug | ||
./buildall.sh |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A possibly faster way to do this is to add a new job like for the r-sanitizer, and add dockerfile like https://github.com/nealrichardson/r-debug/blob/lto/r-debug-5/Dockerfile:
FROM wch1/r-debug
# RDlto: R built with --enable-lto
RUN wget https://raw.githubusercontent.com/nealrichardson/r-debug/lto/r-devel/buildR.sh
RUN buildR.sh lto
RUN RDlto -q -e 'install.packages("pak", repos = "https://r-lib.github.io/p/pak/dev")'
RUN RDlto -q -e 'pak::pkg_install(c("devtools", "Rcpp", "roxygen2", "testthat", "memoise", "rmarkdown"))'
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, turns out R-hub has a docker image already: https://github.com/r-hub/rhub-linux-builders/blob/master/debian-gcc-devel-lto/Dockerfile
@github-actions crossbow submit test-r-r_hub-debian-gcc-devel-lto-latest |
@github-actions crossbow submit test-r-rhub-debian-gcc-devel-lto-latest This should fail with the CRAN error at https://www.stats.ox.ac.uk/pub/bdr/LTO/arrow.out |
Revision: e278e8a Submitted crossbow builds: ursacomputing/crossbow @ actions-693
|
@github-actions crossbow submit test-r-rhub-debian-gcc-devel-lto-latest |
Revision: d27fd38 Submitted crossbow builds: ursacomputing/crossbow @ actions-703
|
I also ran this locally removing all of the
So it looks like we need to do something more to be able to build/link on the CRAN LTO check. |
r/inst/build_arrow_static.sh
Outdated
@@ -75,6 +79,7 @@ ${CMAKE} -DARROW_BOOST_USE_SHARED=OFF \ | |||
-DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON \ | |||
-DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON \ | |||
-DCMAKE_UNITY_BUILD=${CMAKE_UNITY_BUILD:-ON} \ | |||
-DCMAKE_INTERPROCEDURAL_OPTIMIZATION=${ARROW_LTO:-ON} \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be ${ARROW_LTO:-$ARROW_DEFAULT_PARAM}
? As it currently is, it looks like LTO will always be turned on.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've changed this to -DCMAKE_INTERPROCEDURAL_OPTIMIZATION=${ARROW_LTO:-OFF}
Confusingly, $ARROW_DEFAULT_PARAM
here is about adding extra features like compression libraries (based on $LIBARROW_MINIMAL
above).
r/inst/build_arrow_static.sh
Outdated
@@ -45,6 +45,10 @@ else | |||
ARROW_DEFAULT_PARAM="OFF" | |||
fi | |||
|
|||
if echo "$ARROW_R_CXXFLAGS" | grep -q "flto"; then | |||
ARROW_LTO="ON" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this have an else
clause setting ARROW_LTO
to "OFF"
?
@github-actions crossbow submit test-r-rhub-debian-gcc-devel-lto-latest |
Revision: 02bd56a Submitted crossbow builds: ursacomputing/crossbow @ actions-707
|
@github-actions crossbow submit test-r-rhub-debian-gcc-devel-lto-latest |
Revision: 6f2f0f7 Submitted crossbow builds: ursacomputing/crossbow @ actions-709
|
@github-actions crossbow submit test-r-rhub-debian-gcc-devel-lto-latest |
Revision: 6f2f0f7 Submitted crossbow builds: ursacomputing/crossbow @ actions-711
|
6f2f0f7
to
2a8fc19
Compare
@github-actions crossbow submit test-r-rhub-debian-gcc-devel-lto-latest |
Revision: 2a8fc19 Submitted crossbow builds: ursacomputing/crossbow @ actions-713
|
A test to see if we can (for now) build r-debug before using it Closes apache#10849 from jonkeane/ARROW-13507-r-lto Authored-by: Jonathan Keane <jkeane@gmail.com> Signed-off-by: Neal Richardson <neal.p.richardson@gmail.com>
A test to see if we can (for now) build r-debug before using it Closes apache#10849 from jonkeane/ARROW-13507-r-lto Authored-by: Jonathan Keane <jkeane@gmail.com> Signed-off-by: Neal Richardson <neal.p.richardson@gmail.com>
A test to see if we can (for now) build r-debug before using it