Displaying 20 results from an estimated 2000 matches similar to: "[LLVMdev] ASM appears to be incorrect from llc"
2012 Feb 16
0
[LLVMdev] ASM appears to be incorrect from llc
On Wed, Feb 15, 2012 at 3:36 PM, Matthew Huck <matthew.huck at gmail.com> wrote:
> Hi,
> I'm trying to compile an intermediate representation file to ASM (intel
> style), and I believe that the resultant ASM is invalid. The IR is:
>
> ; ModuleID = 'test.u'
>
> %vec2 = type { float, float }
> @t = global %vec2 zeroinitializer
> @x = global i32 0
>
2012 Feb 16
3
[LLVMdev] ASM appears to be incorrect from llc
Hi,
It doesn't compile with yasm, or nasm (reports invalid combination of
opcode and operands), and
mov _x,EAX
is meaningless as _x is just a label (an numeric constant that happens to
be an address), so it would have to be dereferenced to get to the memory at
that address, otherwise it's like saying
mov 0x12341234, EAX
Now, my asm skills are not that great, so I'm prepared to be
2012 Apr 05
0
[LLVMdev] Difference between 2.9 and 3.0 in intel ASM printer
Hi,
I'm almost there with my Yasm printer, however, I've stumbled upon this.
Using this:
; ModuleID = 'data.u'
%window = type { %visobj, %vec2, %vec2, %vec2, %string, %color, i32, i32,
%string, %string, %string, i1, i1, i1, i1, i1, i1, i32, i8* }
%visobj = type { %object, i1, i1, i1, i1, %color, %vec4, %vec4, %vec4,
%vec4, i32, %mat4, %mat4, %mat4, %mat4, %material*,
2024 Jun 16
1
slowness when I use a list comprehension
This can be vectorized. Try
ix <- seq_along(vec2)
S_diff2 <- sapply(seq_len(N1-(N2-1)*ratio_sampling), \(j)
sum((vec1[(ix-1)*ratio_sampling+j] - vec2[ix])**2))
On Sun, Jun 16, 2024 at 11:27?AM Laurent Rhelp <laurentRHelp at free.fr> wrote:
>
> Dear RHelp-list,
>
> I try to use the package comprehenr to replace a for loop by a list
> comprehension.
>
> I
2024 Jun 16
1
slowness when I use a list comprehension
I would be more strong on this advice: learn to think in R, rather than thinking in Python, when programming in R. R has atomic vectors... Python does not (until you import a package that implements them). I find that while it is possible to import R thinking into Python, Python programmers seem to object for stylistic reasons even though such thinking speeds up Python also.
A key step in that
2024 Jun 16
1
slowness when I use a list comprehension
Laurent,
Thank you for introducing me to a package I did not know existed as I use features like list comprehension in python all the time and could see using it in R now that I know it is available.
As to why you see your example as slow, I see you used a fairly complex and nested expression and wonder if it was a better way to go. As you are dealing with an interpreter doing delayed
2009 Jul 27
1
how to use do.call together with cbind and get inside a function
Dear R-helpers:
I have a question related to using do.call to call cbind and get.
#the following works
vec1 <- c(1,2)
vec2 <- c(3,4)
ColNameVec <- c('vec1','vec2')
mat <- do.call("cbind",lapply(ColNameVec,get))
mat
#put code above into a function then it does not work
#before doing so, first remove vec1 and vec2 from global environment
rm(vec1,vec2)
test
2008 Dec 30
2
[LLVMdev] Folding vector instructions
Hello.
Sorry I am not sure this question should go to llvm or mesa3d-dev mailing
list, so I post it to both.
I am writing a llvm backend for a modern graphics processor which has a ISA
very similar to that of Direct 3D.
I am reading the code in Gallium-3D driver in a mesa3d branch, which
converts the shader programs (TGSI tokens) to LLVM IR.
For the shader instruction also found in LLVM IR,
2024 Jun 16
1
slowness when I use a list comprehension
I fully agree with Jeff that the best way to use ANY language is to evaluate
the language in terms of not just the capabilities it offers but also the
philosophy behind what it was created for and how people do things and just
grok it and use it mostly in the way intended. I do that with all the
languages I learn, whether for computers or humans.
Bringing in something you like from another
2010 Jul 12
2
findInterval and data resolution
Hello Wise Ones...
I need a clever way around a problem with findInterval. Consider:
vec1 <- 1:10
vec2 <- seq(1, 10, by = 0.1)
x1 <- c(2:3)
a1 <- findInterval(x1, vec1); a1 # example 1
a2 <- findInterval(x1, vec2); a2 # example 2
In the problem I'm working on, vec* may be either integer or numeric, like
vec1 and vec2. I need to remove one or more sections of this vector;
2013 Apr 18
1
vectors with equal values
Hi,
Try:
?vec1<-c(1,1,1,1,1,1,1,1,1)
if(all(vec1==1)) "xxxxxxxxx" else? "yyyyyyyyyyy"
#[1] "xxxxxxxxx"
?vec2<-c(rep(1,4),2)
?if(all(vec2==1)) "xxxxxxxxx" else? "yyyyyyyyyyy"
#[1] "yyyyyyyyyyy"
#or
if(length(unique(vec1))==1) "xxxxxxxxx" else? "yyyyyyyyyyy"
#[1] "xxxxxxxxx"
? if(length(unique(vec2))==1)
2004 Jul 09
3
Problem with bwplot
Try factor(vec2) in your bwplot() call.
-----Original Message-----
From: r-help-bounces at stat.math.ethz.ch
[mailto:r-help-bounces at stat.math.ethz.ch]On Behalf Of Ernesto Jardim
Sent: Friday, July 09, 2004 9:41 AM
To: Mailing List R
Subject: [R] Problem with bwplot
Hi,
I'm ploting some box-and-whisker plots with bwplot but I'm not getting
any box-and-whiskers ... just dots.
2008 May 12
1
lexicographic comparison of two vectors
Is there any built-in way to lexicographically compare two vectors of
the same length in R? The textbook algorithm could be coded as follows:
lex.cmp <- function (vec1,vec2) {
for (j in 1:length(vec1)) {
if (vec1[j] < vec2[j]) { return(-1) }
if (vec1[j] > vec2[j]) { return(1) }
}
return(0)
}
Thanks,
Gabriel
2001 Nov 01
1
Erratic behaviour of sammon()
I'm not sure this list is the right place for this thing.
I noticed some erratic behaviour in sammon(). Running sammon on
two nearly identical sets of data results in very different
results. Below is an example. I create an initial configuration
with cmdscale() and store it into 'vec1'. I write this to file,
and read it back in again to 'vec2'. According to cor() on the
three
2013 Feb 17
1
addition in the initial question
Dear Elisa,
Try this:
vec1<-c(33,18,13,47,30,10,6,21,39,25,40,29,14,16,44,1,41,4,15,20,46,32,38,5,31,12,48,27,36,24,34,2,35,11,42,9,8,7,26,22,43,17,19,28,23,3,49,37,50,45)
vec2<-vec1[1:26]
names(vec2)<-LETTERS[1:26]
label1<-unlist(lapply(mapply(c,lapply(seq(0,45,5),function(x) x),lapply(seq(5,50,5),function(x) x),SIMPLIFY=FALSE),function(i)
2008 Sep 20
1
lower and upper limits in integrate as vectors
Dear R useRs,
i try to integrate the following function for many values
"integrand" <- function(z)
{
return(z * z)
}
i do this with a for-loop
for(i in 2:4)
{
z <- integrate(integrand, i-1, i)$value
cat("z", z, "\n")
}
to speed up the computation for many values i tried vectors
in integrate to do this.
vec1<-1:3
vec2<-2:4
2010 Aug 24
3
multiple assignments ?
Simple one, have read and googled, still no luck!
I want to create several empty vectors all of the same length.
I would like multiple empty vectors (vec1, vec2, vec3) and want to create them all in one line.
I've tried
vec1,vec2,vec3 <- vector(length=5)
and
c(vec1,vec2,vec3) <- vector(length=5)
and several other attempts but nothing seems to work ... suggestions?
Thanks
Jim
2011 Jun 03
2
Arules: R Crashes when running eclat with tidLists=TRUE
Hello,
I'm using the eclat function of the arules package (1.0-6) for the
identification of frequent itemsets. I need the tidLists, but if I set
in the function tidLists=TRUE R crashes (Windows XP Professional SP3,
32 bit, R version 2.12.1 (2010-12-16), reproducible on two different
computers) with two different error messages or non at all. Minimum
examples are:
library(arules)
2015 May 04
2
[LLVMdev] Incorrect code generated for arm64
Hi all,
I’ve narrowed down a problem in my code to the following test case:
- - - -
typedef struct {float v[2];} vec2;
typedef struct {float v[3];} vec3;
vec2 getVec2();
vec3 getVec3()
{
vec2 myVec = getVec2();
vec3 res;
res.v[0] = myVec.v[0];
res.v[1] = myVec.v[1];
res.v[2] = 1;
return res;
}
- - - -
Compiling this with any level of optimization for arm64 gives incorrect code,
2015 May 04
2
[LLVMdev] Incorrect code generated for arm64
Thanks Bruce.
> On 4 May 2015, at 13:18, Bruce Hoult <bruce at hoult.org> wrote:
>
> I can confirm that, with Apple LLVM version 6.0 (clang-600.0.56) (based on LLVM 3.5svn)
>
> Very strange!
Yes, that’s what I thought. I’ve also checked the binary downloads for OS X from llvm.org <http://llvm.org/> and get the same broken code from both the 3.5.2 and 3.6.0 releases.