search for: truthy

Displaying 11 results from an estimated 11 matches for "truthy".

Did you mean: truth
2019 Aug 19
2
Check length of logical vector also for operands of || and &&?
Hi everyone The following behavior (in R 3.6.1 and R-devel r77040) caught me by surprise today: truthy <- c(TRUE, FALSE) falsy <- c(FALSE, TRUE, FALSE) if (truthy) "check" #> Warning in if (truthy) "check": the condition has length > 1 and only the #> first element will be used #> [1] "check" if (falsy) "check" #> Warning in if (falsy) &q...
2014 Sep 30
2
Intel Fortran compiler returns a -1 TRUE value
...ad("truth.so") > z = .Fortran("truth",as.logical(TRUE)) > z[[1]] [1] TRUE > as.numeric(z[[1]]) [1] -1 > z[[1]] == TRUE [1] FALSE > all(z[[1]]) [1] TRUE > identical(z[[1]],TRUE) [1] FALSE The value generated by Fortran's .TRUE. evaluates as "truthy" -- as in all(z[[1]]) -- but is neither equal to nor identical to TRUE. Its numeric conversion to -1 is most unusual, every other system I've tried converts to +1. So.... wrong compiler flag on build? User error - never try comparing truthy values, as with the various flavours of NA? Or s...
2020 Apr 09
2
[RFC] Usage of NDEBUG as a guard for non-assert debug code
...dropdown break. > > > > Since we C’s assert, it is intrinsically tied to NDEBUG. What we need > is proper custom asserts. In codebases I’ve seen in my travels that have > this it usually looks like: > > > > // If asserts are enabled, evaluate and assert that expr is truthy. If it > is not, complain with msg. > > LLVM_ASSERT(expr, msg) > > > > // If asserts are enabled, evaluate and assert that expr is truthy. If it > is not, complain with msg. > > // If asserts are disabled, evaluate expr, do not assert. > > // either way, return e...
2020 Apr 09
7
[RFC] Usage of NDEBUG as a guard for non-assert debug code
Hi all, During discussions about assertions in the Flang project, we noticed that there are a lot of cases in LLVM that #ifndef NDEBUG is used as a guard for non-assert code that we want enabled in debug builds. This works fine on its own, however it affects the behaviour of LLVM_ENABLE_ASSERTIONS; since NDEBUG controls whether assertions are enabled or not, a lot of debug code gets enabled in
2007 Mar 22
2
quick legend() question
Hi I have a scatterplot of points with pch=1 and a single point with pch=3, lwd=3. It has a high line width to attract attention to it. The following script plot(rnorm(10),rnorm(10),col="black") points(rnorm(10),rnorm(10),col="red") points(0,0,pch=3,lwd=3) if(TRUE){ legend("bottomleft",c("a","b","Truth"),pch=c(1,1,3),col=c
2024 Dec 13
2
Weird Behavior of mean
Is the following a strange behavior for `mean` vs. `sd` ? ``` $ R --vanilla. ## 4.4.2 > x=c(NA,1,2,3) > c( mean(x,na.rm=T), sd(x,na.rm=T) ) [1] 2 1 > T=20 ## bad idea for a parameter. T is also used for TRUE > c( mean(x,na.rm=T), sd(x,na.rm=T) ) [1] NA 1 > ``` This one was a baffler for me to track down for a few hours...
2012 Jul 20
7
Oracle tries to capture CentOS users
Hello CentOS Guys :-) Oracle has created a new Website to capture CentOS Users :o http://linux.oracle.com/switch/centos/ -- Chris
2024 Dec 13
1
Weird Behavior of mean
Sounds reasonable, but I leave it to wiser heads than me to decide. My only point is that whatever is done be accurately documented. At present, that does not appear to be the case. ... and yes, "accurate" documentation is not easy either. -- Bert On Fri, Dec 13, 2024 at 3:20?PM Ben Bolker <bbolker at gmail.com> wrote: > > Thanks, I had missed/forgotten the fact that
2018 Nov 10
3
[RFC] Tablegen-erated GlobalISel Combine Rules
Thanks Nicolai! > On Nov 9, 2018, at 02:55, Nicolai Hähnle <nhaehnle at gmail.com> wrote: > > Hi Daniel, > > Lots of good stuff in there! I especially like the design for specifying out-of-line predicates. I have a couple of small comments and one major one below. > > > On 09.11.18 02:42, Daniel Sanders via llvm-dev wrote: >> _Passing arbitrary data from
2018 Nov 09
5
[RFC] Tablegen-erated GlobalISel Combine Rules
Hi All, I've been working on the GlobalISel combiner recently and I'd like to share the plan for how Combine Rules will be defined in GlobalISel and solicit feedback on it. This email ended up rather long so: TL;DR: We're planning to define GlobalISel Combine Rules using MIR syntax with a few bits glued on to interface with the algorithm and escape into C++ when we need to.
2018 Nov 12
3
[RFC] Tablegen-erated GlobalISel Combine Rules
> On Nov 10, 2018, at 03:28, Nicolai Hähnle <nhaehnle at gmail.com> wrote: > > Thank you for the detailed reply! There's a lot to digest :) Let me try to address most of it. > > > [snip] >>> I also think you should have 'ins' and 'outs' separately; after all, a predicate may have to do a combined check on two matched registers / operands,