similar to: How to disable R's C stack checking

Displaying 20 results from an estimated 1100 matches similar to: "How to disable R's C stack checking"

2007 Jun 01
3
Question on the R's C stack limit
Dear r-devel members, I encountered a C stack limit issue, when I tried to embed R 2.5 into my application. In the R-exts document, it says:"Note that R's own front ends use a stack size of 10Mb". I desire to know: is it possible to decrease this stack size by modifying R's source code? If it's possible, which part of the source code is responsible for the issue? Thank
2007 Jun 28
1
How to set R_CStackLimit
Hi, I have tried to disable stack checking by set R_CStackLimit to -1. However, it always crashes my win32 multiple threads program. I am using R-2.5.0. My code looks like: #include <Rversion.h> #if (R_VERSION >= R_Version(2,3,0)) #define R_INTERFACE_PTRS 1 #define CSTACK_DEFNS 1 #include <Rinterface.h> #endif and then, add below line to my main function: R_CStackLimit =
2015 Aug 20
2
Child thread libR.so
So I'm working on a custom front end to R, in one mode of the front end I dynamically load libR.so into a child worker thread. I'm very careful to make sure it is loaded by a single thread and loaded only once, but since it is a child thread it violates assumptions made by the stack size checking inside of R and I get innumerable errors along the lines of Error: C stack usage
2009 May 19
2
About " Error: C stack usage is too close to the limit"
Hi everyone! I meet one problem when embedding R in C code, when I run the the R code in one child thread , it always print error info: Error: C stack usage is too close to the limit I also try to set R_CStackLimit = (uintptr_t)-1 to disable the C stack check as the R-exts doc say, but it still does not work, the error info still exist. Besides it is interesting that if i
2007 Aug 29
1
Modifying R_CheckStack for a speed increase
Greetings R developers, R will run a little faster when executing "pure R" code if the function R_CheckStack() is modified. With the modification, the following code for example runs 15% faster (compared to a virgin R-2.5.1 on my Windows XP machine): N = 1e7 foo <- function(x) { for (i in 1:N) x <- x + 1 x }
2009 May 21
1
"Error: C stack usage is too close to the limit" (can't understand explanations of how to fix this)
Apparently the way to deal with this error message is to set R_CStackLimit = (uintptr_t)-1 I tried typing this in the R console, but it says Error: object "R_CStackLimit" not found. So where do I type it? In one of the initialization files that R uses when it starts up? I can't find the answer anywhere. Please note that I don't understand words like "DLL" or
2015 Aug 25
0
Child thread libR.so
Simon, Ah, thank you! quiet right. For anyone searching for this in the future, I changed my init fuction to: ---------- SNIP ---------------- void init_r() { SEXP aperm_function; /* this is our version of Rf_initEmbeddedR where we disable stack checking */ const char *init_argv[] = {"MyFront", "--vanilla", "--slave"}; Rf_initialize_R(sizeof
2019 May 19
4
most robust way to call R API functions from a secondary thread
Hi, As the subject suggests, I am looking for the most robust way to call an (arbitrary) function from the R API from another but the main POSIX thread in a package's code. I know that, "[c]alling any of the R API from threaded code is ?for experts only? and strongly discouraged. Many functions in the R API modify internal R data structures and might corrupt these data structures if
2019 May 20
1
most robust way to call R API functions from a secondary thread
Stepan, Andreas gave a lot more thought into what you question in your reply. His question was how you can avoid what you where proposing and have proper threading under safe conditions. Having dealt with this before, I think Andreas' write up is pretty much the most complete analysis I have seen. I'd wait for Luke to chime in as the ultimate authority if he gets to it. The
2009 Jun 18
0
[LLVMdev] Configure problem of llvm2.5 in Mac OS X 10.4.11
I can configure it now. Thank You! --- On Wed, 6/17/09, Bill Wendling <isanbard at gmail.com> wrote: From: Bill Wendling <isanbard at gmail.com> Subject: Re: [LLVMdev] Configure problem of llvm2.5 in Mac OS X 10.4.11 To: "LLVM Developers Mailing List" <llvmdev at cs.uiuc.edu> Date: Wednesday, June 17, 2009, 6:26 PM Hi Murat, This looks suspicious:  
2016 Feb 01
1
Wrong config check for __libc_stack_end
>>>>> Simon Urbanek <simon.urbanek at r-project.org> >>>>> on Mon, 1 Feb 2016 08:36:56 -0500 writes: > On Feb 1, 2016, at 4:16 AM, Martin Maechler <maechler at stat.math.ethz.ch> wrote: [..............] >> Back to R: I'm not familiar with that part of the code, neither >> the configuration, nor the usage (in
2009 Jun 17
1
[LLVMdev] Configure problem of llvm2.5 in Mac OS X 10.4.11
Hi, I am trying to install llvm 2.5 in my PowerPC machine. I have already installed XCode Tools 2.4.1. I can compile programs using gcc run them. I try to configure llvm 2.5, the configuration aborts with following message: checking build system type... powerpc-apple-darwin8.11.0 checking host system type... powerpc-apple-darwin8.11.0 checking target system type... powerpc-apple-darwin8.11.0
2015 Aug 24
0
Child thread libR.so
I did some poking around with GDB and confirmed that the advice of setting R_CStackLimit after init, which is echoed in the "threading issues" section of the R-exts help document, isn't entirely useful because init apparently loads the main package which trips over the broken stack checking. Stack trace: #0 R_SignalCStackOverflow (usage=140732197147604) at errors.c:81 #1
2010 Apr 30
2
RInside & child threads
Hi Folks, I am creating a multi-threaded C++ application that initializes RInside in one of the child thread. I would also like to access support interfaces like Rcpp::Environment in the remaining child threads, so that I could access any "R" function associated with the environment initialized. When I run my program, I always get "C Stack limit too huge" errors. I looked
2005 Nov 24
8
A minor beef
CentOS is a really great product, and the package supporters do a bang up job, but the one deficiency I've found is the fact that one can never rely on being able to get updates at any particular time. Whether it's CentOS proper or the Dag additions, something is broke most every time I want to apply updates. I know this is whin[ge]ing, and I certainly don't have a solution to offer.
2007 Sep 17
0
Problems with compiling rimage on macOS
hello, i want to install the rimage package (0.5-7) into my R (2.5.1). i installed the "i686-apple-darwin8-g++-4.0.1 (GCC) 4.0.1 (Apple Computer, Inc. build 5367)" from the macOS cd and created symbolic links to gcc and g++. well if i try now to install the package in R the console says: g++ checking for C++ compiler default output... ** Removing '/Library/
2010 Aug 20
1
error heatmap and stack overflow
Hello, Im trying to create a heatmap with a dataset (38 x 15037) but get the error below: Error: protect(): protection stack overflow Execution halted or Error: C stack usage is too close to the limit Execution halted I tried to increase the stack size by changing: extern uintptr_t R_CStackLimit but my systems manager said that R by default uses all the memory available to it from the
2007 Apr 03
2
R callbacks
Hi, I'm trying to understand (mostly from the R-exts manual) how to use the callbacks declared in Rinterface.h. As a first attempt, I'm trying to redefine ptr_R_WriteConsole in a very trivial manner. Here's my code: --------------- $ cat altr.c int Rf_initialize_R(int ac, char **av); #define R_INTERFACE_PTRS 1 #include <Rinterface.h> extern int R_running_as_main_program;
2007 Nov 28
2
1.1beta9 'make' fails on osx/Tiger, but OK on osx/Leopard (multiple definitions of symbol _hash_create)
i'm building dovecot 1.1.beta9 on both osx 10.4.11 osx 10.5.1 using Using built-in specs. Target: powerpc-apple-darwin8 Configured with: /Builds/apple/gcc_42-5531/obj/src/configure --disable-checking -enable-werror --prefix=/usr --mandir=/usr/share/man --enable-languages=c,objc,c++,obj-c++ --program-transform-name=/^[cg][^.-]*$/s/$/-4.2/ --with-gxx-include-dir=/usr/include/c++/4.0.0
2006 Aug 28
0
"Bus Error" Under Mac OS X x86 with Wine 0.9.20
I'm trying to run Wine 0.9.20 under OS X x86 and I'm getting nothing but "Bus Error" when I run any win32 program via Wine. Here is some relevant environment info: OS: Mac OS X 10.4.7 Xcode: Xcode 2.4 X11: XFree86 Version 4.4.0 / X Window System (protocol Version 11, revision 0, vendor release 6600) gcc -v: Using built-in specs. Target: i686-apple-darwin8 Configured with: