This is probably not exclusively Rcpp problem, but I could use some
debugging help from Rcpp experts.
When building V8 on windows with the new tool chain, the build succeeds and
the package can be loaded, but when trying to use it on i386, it crashes
(it works fine on x64). Other packages that link to external c++ libraries
(e.g. RQuantlib) might suffer from this as well.
To reproduce, install latest rtools and r-devel on windows and run:
install.packages("V8", type = "source")
library(V8)
ct <- new_context()
The R.exe process crashes without any error message or crashdump, which
makes this very difficult to debug. I suspect that the problem is that the
new Rtools has been built with some different settings resulting in
incompatible binaries, but I can't find the problem.
Any suggestions on where to start debugging this?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20150312/31bc0aaf/attachment.html>
[Rcpp-devel] V8 crashes on 32bit windows when built with new Rtools
6 messages · Jeroen Ooms, JJ Allaire, Duncan Murdoch +1 more
I had an issue like this in RcppParallel that was solved by rebuilding Rcpp from source using the very latest R-devel and Rtools 3.3. Have you tried that? J.J.
On Thu, Mar 12, 2015 at 5:25 PM, Jeroen Ooms <jeroen.ooms at stat.ucla.edu> wrote:
This is probably not exclusively Rcpp problem, but I could use some
debugging help from Rcpp experts.
When building V8 on windows with the new tool chain, the build succeeds and
the package can be loaded, but when trying to use it on i386, it crashes (it
works fine on x64). Other packages that link to external c++ libraries (e.g.
RQuantlib) might suffer from this as well.
To reproduce, install latest rtools and r-devel on windows and run:
install.packages("V8", type = "source")
library(V8)
ct <- new_context()
The R.exe process crashes without any error message or crashdump, which
makes this very difficult to debug. I suspect that the problem is that the
new Rtools has been built with some different settings resulting in
incompatible binaries, but I can't find the problem.
Any suggestions on where to start debugging this?
_______________________________________________ Rcpp-devel mailing list Rcpp-devel at lists.r-forge.r-project.org https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel
On Thu, Mar 12, 2015 at 2:40 PM, JJ Allaire <jj.allaire at gmail.com> wrote:
I had an issue like this in RcppParallel that was solved by rebuilding Rcpp from source using the very latest R-devel and Rtools 3.3. Have you tried that?
Yes, that doesn't seem to help. I have a suspicion now. I have seen this behavior before when linking libraries on windows that were built with different threading models. Based on gcc -v, the old rtools (and hence my v8 static libs) use win32 threading, whereas the new rtools has been built with --enable-threads=posix. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20150312/e489d09f/attachment.html>
On 12/03/2015 5:51 PM, Jeroen Ooms wrote:
On Thu, Mar 12, 2015 at 2:40 PM, JJ Allaire <jj.allaire at gmail.com
<mailto:jj.allaire at gmail.com>> wrote:
I had an issue like this in RcppParallel that was solved by rebuilding
Rcpp from source using the very latest R-devel and Rtools 3.3. Have
you tried that?
Yes, that doesn't seem to help.
I have a suspicion now. I have seen this behavior before when linking
libraries on windows that were built with different threading models.
Based on gcc -v, the old rtools (and hence my v8 static libs) use win32
threading, whereas the new rtools has been built with
--enable-threads=posix.
The scripts are on CRAN, if you want to try modifying them. However, if the scripts aren't satisfactory very soon, I'll just go back to the previous Rtools. Duncan
Why would posix be enabled for a Windows target? Avi On Thu, Mar 12, 2015 at 6:49 PM, Duncan Murdoch <murdoch.duncan at gmail.com> wrote:
On 12/03/2015 5:51 PM, Jeroen Ooms wrote:
On Thu, Mar 12, 2015 at 2:40 PM, JJ Allaire <jj.allaire at gmail.com
<mailto:jj.allaire at gmail.com>> wrote:
I had an issue like this in RcppParallel that was solved by
rebuilding
Rcpp from source using the very latest R-devel and Rtools 3.3. Have
you tried that?
Yes, that doesn't seem to help.
I have a suspicion now. I have seen this behavior before when linking
libraries on windows that were built with different threading models.
Based on gcc -v, the old rtools (and hence my v8 static libs) use win32
threading, whereas the new rtools has been built with
--enable-threads=posix.
The scripts are on CRAN, if you want to try modifying them. However, if the scripts aren't satisfactory very soon, I'll just go back to the previous Rtools. Duncan
_______________________________________________ Rcpp-devel mailing list Rcpp-devel at lists.r-forge.r-project.org https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel
-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20150312/eff56c32/attachment.html>
It's not posix per-se, it's "posix threads" (of which there is a win32 port available in mingw). This is done sometimes to ease porting of software from posix to windows. An update: Kevin submitted a patch to use win32 threads for Rtools (restoring the previous behavior) and Duncan is rebuilding Rtools now with this change. Once we have this update in hand we can test again.
On Thu, Mar 12, 2015 at 7:13 PM, Avraham Adler <avraham.adler at gmail.com> wrote:
Why would posix be enabled for a Windows target? Avi On Thu, Mar 12, 2015 at 6:49 PM, Duncan Murdoch <murdoch.duncan at gmail.com> wrote:
On 12/03/2015 5:51 PM, Jeroen Ooms wrote:
On Thu, Mar 12, 2015 at 2:40 PM, JJ Allaire <jj.allaire at gmail.com
<mailto:jj.allaire at gmail.com>> wrote:
I had an issue like this in RcppParallel that was solved by
rebuilding
Rcpp from source using the very latest R-devel and Rtools 3.3. Have
you tried that?
Yes, that doesn't seem to help.
I have a suspicion now. I have seen this behavior before when linking
libraries on windows that were built with different threading models.
Based on gcc -v, the old rtools (and hence my v8 static libs) use win32
threading, whereas the new rtools has been built with
--enable-threads=posix.
The scripts are on CRAN, if you want to try modifying them. However, if the scripts aren't satisfactory very soon, I'll just go back to the previous Rtools. Duncan
_______________________________________________ Rcpp-devel mailing list Rcpp-devel at lists.r-forge.r-project.org https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel