search for: func

Displaying 20 results from an estimated 4510 matches for "func".

2020 Apr 24
1
[PATCH nbdkit] golang: Pass Plugin and Connection by reference not value.
...gin.pod +++ b/plugins/golang/nbdkit-golang-plugin.pod @@ -62,16 +62,16 @@ C<GetSize> and C<PRead>. What connects the two is the C<Open> callback which is called when the client has connected and where you should return a new instance of your connection struct. For example: - func (p MyPlugin) Load() { + func (p *MyPlugin) Load() { // global callback used for initializing the plugin } - func (p MyPlugin) Open(readonly bool) (nbdkit.ConnectionInterface, error) { + func (p *MyPlugin) Open(readonly bool) (nbdkit.ConnectionInterface, error) { // new clie...
2008 Nov 17
4
functional (?) programming in r
the following is a trivialized version of some functional code i tried to use in r: (funcs = lapply(1:5, function(i) function() i)) # a list of no-parameter functions, each with its own closure environment, # each supposed to return the corresponding index when applied to no arguments sapply(funcs, function(func) func()) # supposed to return c(1,2...
2007 Nov 15
0
4 commits - libswfdec/swfdec_asbroadcaster.c libswfdec/swfdec_as_frame.c libswfdec/swfdec_as_frame_internal.h libswfdec/swfdec_as_function.c libswfdec/swfdec_as_interpret.c test/trace
libswfdec/swfdec_as_frame.c | 14 ++ libswfdec/swfdec_as_frame_internal.h | 3 libswfdec/swfdec_as_function.c | 12 -- libswfdec/swfdec_as_interpret.c | 1 libswfdec/swfdec_asbroadcaster.c | 3 test/trace/arguments-5.swf |binary test/trace/arguments-5.swf.trace | 82 +++++++++-------- test/trace/arguments-6.swf |binary test/trace/arguments-6.swf.tr...
2018 Jun 08
2
XRay FDR mode doesn’t log main thread calls
Hello, I am initializing FDR mode and finalizing/flushing the buffers manually. XRay does not log calls from the main thread unless there is a function call after __xray_log_finalize(). This behavior is abnormal since one would expect the trace file to contain all function calls made up to the point when __xray_log_finalize() is called. To demonstrate this behavior, I have taken the test case from TestCases/Posix and modified it. I am runni...
2017 Apr 28
2
LLVMGetFirstFunction() / LLVMGetNextFunction( ) problem
Hi, I have a problem - looking for advice. I have a source code file with two functions which are compiled into a .bc file. When the bitcode file is loaded, I can dump the module and see the two functions: ... ; Materializable ; Function Attrs: noinline nounwind uwtable define void @matmul(double*, double*, double*, i32, i32, i32) #0 {} ; Materializable ; Function Attrs: noinli...
2004 Mar 27
3
a question about scoping functions
Hi, I've written some helper functions which are used by another function (called func()). When func() is sourced I dont want the helper function to be seen in the global namespace (as shown by ls()). Currently what I have done is: func <- function() { helper1 <- function() { ... } helper2 <- function() { ....
2006 Mar 31
2
Missing probes in libc.so.1
...quot;nm" on libc. Why? See below for details: %dtrace -w -qn ''BEGIN {system("dtrace -l -mlibc.so.1 > libc_dtrace");} pid$target:libc:_c??????:entry{}'' -c ''sleep 1'' % cat libc_dtrace ID PROVIDER MODULE FUNCTION NAME 42288 pid22010 libc.so.1 _cleanup entry 42289 pid22010 libc.so.1 _creat64 entry % /usr/ccs/bin/nm -n /lib/libc.so.1 | grep ''\|_c......$'' | grep FUNC [8747] | 260828| 500|FUNC |GLOB |0 |9...
2007 Apr 18
2
[PATCH] Simplify smp_call_function*() by using common implementation
smp_call_function and smp_call_function_single are almost complete duplicates of the same logic. This patch combines them by implementing them in terms of the more general smp_call_function_mask(). [ Jan, Andi: This only changes arch/i386; can x86_64 be changed in the same way? ] [ Rebased onto Jan's x8...
2007 Apr 18
2
[PATCH] Simplify smp_call_function*() by using common implementation
smp_call_function and smp_call_function_single are almost complete duplicates of the same logic. This patch combines them by implementing them in terms of the more general smp_call_function_mask(). [ Jan, Andi: This only changes arch/i386; can x86_64 be changed in the same way? ] [ Rebased onto Jan's x8...
2010 Oct 05
2
How to convert a list to a ... argument for a function
Hi, I have a function f <- function(..., func){ something }, where func is a function of the form function(...). ?I would like to pass func all the arguments passed to f except the last. ?I know that I can manipulate the variable number of arguments passed to f by converting ... to a list, i.e., arglist <- lis...
2005 Jun 07
5
Functions within functions in R and S-Plus
..." some code from R to S-Plus (I have colleague that insists on using S-Plus. And yes, I have tried to make him change to R...) The following code works out fine in R, but in S-Plus (S-PLUS 6.2 for Windows Professional Ed.) I get the error message "Problem in est.theta(x): Object "func" not found ". I have tried to keep most of the structure in my original problem (but simplified it!), so the code could seem a bit strange. I suspect that this has something to do with different scoping rules in R and S-Plus, but still I have not found a workable solution in S-Plus. ma...
2013 Mar 14
2
Grep with wildcards across multiple columns
...set up like the following dummy: # Create fake data df <- data.frame(code = c(rep(1001, 8), rep(1002, 8)), year = rep(c(rep(2011, 4), rep(2012, 4)), 2), fund = rep(c("10E", "10E", "10E", "27E"), 4), func = rep(c("110000", "122000", "214000", "158000"), 4), obj = rep("100", 16), amount = round(rnorm(16, 50000, 10000))) What I would like to do is sum the amount variable by code and year, filtering rows using dif...
2008 Mar 23
1
Wine 0.9.58 regression
...747-11d0-9fea-00aa003f8646} could be created for context 0x3 fixme:bitblt:X11DRV_ClientSideDIBCopy potential optimization: client-side complex region clipping fixme:wtsapi:WTSRegisterSessionNotification Stub 0x400bc 0x00000000 fixme:ntdll:server_ioctl_file Unsupported ioctl 70c00 (device=7 access=0 func=300 method=0) fixme:ntdll:server_ioctl_file Unsupported ioctl 70c00 (device=7 access=0 func=300 method=0) fixme:ntdll:server_ioctl_file Unsupported ioctl 70c00 (device=7 access=0 func=300 method=0) fixme:ntdll:server_ioctl_file Unsupported ioctl 70c00 (device=7 access=0 func=300 method=0) fixme:ntd...
2011 Aug 15
1
ggplot in a function confusion!
...x=1:10,y=1:10) ggplot()+geom_point(data=df,aes(x=x,y=y)) ## this is the normal usage right? ggplot()+geom_point(data=df,aes(x=df[,1],y=df[,2])) ## but I can also feed it column indices ggplot()+geom_point(aes(x=df[,'x'],y=df[,'y'])) ## or column names. ## but if i wrap it in a function... plot.func.one<-function(dff,x.var,y.var){ print(ggplot() + geom_point(aes(x=dff[,x.var],y=dff[,y.var]))) } plot.func.two<-function(dff,x.var,y.var){ print(ggplot() + geom_point(data=dff,aes(x=dff[,x.var],y=dff[,y.var]))) } plot.func.three<-function(dff,x.var,y.var){ p...
2020 Aug 13
1
[PATCH 20/20] drm: Remove obsolete GEM and PRIME callbacks from struct drm_driver
Hi Thomas. On Thu, Aug 13, 2020 at 10:36:44AM +0200, Thomas Zimmermann wrote: > Several GEM and PRIME callbacks have been deprecated in favor of > per-instance GEM object functions. Remove the callbacks as they are > now unused. The only exception is .gem_prime_mmap, which is still > in use by several drivers. > > What is also gone is gem_vm_ops in struct drm_driver. All drivers now > use struct drm_gem_object_funcs.vm_ops instead. > > While at it,...
2009 Apr 08
2
Strange behavior of header_filter_callback
...9 Info: auth input: uid=1002 deliver(pitman at virtualworld.com): Apr 08 13:52:39 Info: auth input: gid=1002 deliver(pitman at virtualworld.com): Apr 08 13:52:39 Info: auth input: home=/var/spool/mail/pitman at virtualworld.com deliver(pitman at virtualworld.com): Apr 08 13:52:39 Info: example: func example_plugin_init is called deliver(pitman at virtualworld.com): Apr 08 13:52:39 Info: mbox: data=/var/spool/mail/pitman at virtualworld.com :INDEX=/var/indexes/pitman at virtualworld.com deliver(pitman at virtualworld.com): Apr 08 13:52:39 Info: mbox: INBOX defaulted to /var/spool/mail/pitm...
2011 Jan 20
1
Calling C++ from R
Hi All, I am new to this area and use Rcpp to call C++ from R and try to build the package under Windows 7. I use Rtools and R 2.10.1 32bit. Everything works fine with me, except using R functions like "rnorm" or "runif" in the C++ code. When I use "R CMD check" the package, it always return error ** libs making DLL ... g++ -I"c:/PROGRA~2/R/R-210~1.1/include" -I"c:/PROGRA~2/R/R-210~1.1/library/Rcpp/include" -O2 -Wall -c func.c...
2017 Jul 26
3
[RFC] Add IR level interprocedural outliner for code size.
...terms of enabling other optimizations in the pipeline like > vectorizer. Outliner does not expose any of that. I have not made a lot of effort to understand the full discussion here (so what I say below may be off-base), but I think there are some cases where outlining (especially working with function-attrs) can make optimization easier. It can help transforms that duplicate code (like loop unrolling and inlining) be more profitable -- I'm thinking of cases where unrolling/inlining would have to duplicate a lot of code, but after outlining would require duplicating only a few call instr...
2009 Jul 29
1
Strange Interaction Between Promises and Closures (PR#13861)
Full_Name: Keith Bare Version: 2.7.1 OS: Linux Submission from: (NULL) (128.2.134.48) I observed unexpected behavior attempting to use lapply to vary parameters in generated closures. All the generated closures ran with the last parameter value in the list. Here's a simple example: > funcs <- lapply(c("alpha", "beta", "gamma", "delta"), function(x) function() print(x)) > funcs[[1]]() [1] "delta" > funcs[[2]]() [1] "delta" > funcs[[3]]() [1] "delta" > funcs[[4]]() [1] "delta" What appears...
2010 Aug 08
2
Importing arguments for use by functions in a script
QUESTION: Is there a way of passing arguments from an external file to a script so that they can be used directly by functions within the script? I have a series of interdependent functions. I wish to test the time for processing various datasets. I was initially doing something along the lines of the following (yes, I am new to R): rm(list= ls()) systime1<-system.time(source("seq_imp_fct.R")) systime2&...