search for: getcol

Displaying 10 results from an estimated 10 matches for "getcol".

Did you mean: getcon
2012 Mar 02
2
Correlation of huge matrix saved as binary file
...correlation matrix. Right now my approach is to do something similar to this (toy code): corr.matrix<-matrix('numeric',ncol=9000,nrow=9000) for (i in 1:9000) { for (j in (i+1):9000) { # i1=... getting the index of item (i) in a second file # i2=....getting the index of item (j) g1=api$getCol(i1) g2=api$getCol(i2) cor.matrix[i,j]=cor(g1,g2) }} This will work, but will take forever. Any advice for how this can be done more efficiently? I'm running on a 2.6.18 linux system, with R version R-2.11.1. Thanks! -- View this message in context: http://r.789695.n4.nabble.com/Correlation-...
2011 Nov 09
0
[LLVMdev] Start column from DebugLoc of MachineInstr
Hi,   1. Below code gives me end column number of the machine instruction.    How can I get the start column number ?   const MachineInstr *First; ..... //First is assigned. DebugLoc MIDB = First->getDebugLoc(); col_begin  = MIDB.getCol();   2. -----------------   If my C block is     {         int t = 10;      }   This gives me value 20, instead of 9. -----------------   3. In DebugLoc the getCol() method is defined as: unsigned getCol()const {        return LineCol >> 24; } Is the some other shifting required to get the...
2011 Nov 01
2
[LLVMdev] Adding a custom GC safe point creation phase
...= BBE; ++BBI) { for (MachineBasicBlock::iterator MI = BBI->begin(), ME = BBI->end(); MI != ME; ++MI) { if (MI->getDesc().isCall()) { /// Standard code need for adding a post call safe point; } else if (MI->getDebucLoc().getCol() == 1) { /// Standard code need for adding a post call safe point; } } } So it really looks like what we already have, except this special trick about checking the debug location. Piggy backing on the debug location is easy and works for me because: 1) Debug locations are pa...
2011 Nov 01
0
[LLVMdev] Adding a custom GC safe point creation phase
...for (MachineBasicBlock::iterator MI = BBI->begin(), > ME = BBI->end(); MI != ME; ++MI) { > if (MI->getDesc().isCall()) { > /// Standard code need for adding a post call safe point; > } else if (MI->getDebucLoc().getCol() == 1) { > /// Standard code need for adding a post call safe point; > } > } > } > > So it really looks like what we already have, except this special trick about checking the debug location. Piggy backing on the debug location is easy and works for me beca...
2015 Apr 23
2
[LLVMdev] Get precise line/column debug info from LLVM IR
...ed by an third-party tool) to instrument them. To achieve this, I am compiling my source files with `clang -g -O0 -emit-llvm` and looking for the information in the metadata using this code: const DebugLoc &location = instruction->getDebugLoc(); // location.getLine() // location.getCol() Unfortunately, this information is absolutely imprecise. Consider the following implementation of the Fibonacci function: unsigned fib(unsigned n) { if (n < 2) return n; unsigned f = fib(n - 1) + fib(n - 2); return f; } I would like to locate the...
2014 Jan 24
2
[LLVMdev] How to read v3.3 dbg metadata using v3.4 LLVM
...getMetadata(dbgKind)){ >> >> DILocation location(N); >> >> fileDirectoryName = location.getDirectory(); >> >> fileName = location.getFilename(); >> >> lineNumber = location.getLineNumber(); >> >> columnNumber = location.getColumnNumber(); >> >> } >> [1] >> >> int main(int argc, char **argv){ >> >> return 0; >> >> } >> >> [2] >> >> define i32 @main(i32 %argc, i8** %argv) #0 { >> >> entry: >> >> %retval = alloca i32,...
2013 Apr 26
0
[LLVMdev] Inconsistent use of is_stmt flag in .debug_line
...== PrologEndLoc) { Flags |= DWARF2_FLAG_PROLOGUE_END; PrologEndLoc = DebugLoc(); } if (PrologEndLoc.isUnknown()) Flags |= DWARF2_FLAG_IS_STMT; if (!DL.isUnknown()) { const MDNode *Scope = DL.getScope(Asm->MF->getFunction()->getContext()); recordSourceLine(DL.getLine(), DL.getCol(), Scope, Flags); It's easy to change this code to apply is_stmt for every line table entry but I think that this is the wrong approach. The real question is, why do we have an inconsistency where some function prologues contain instructions that can be mapped to the source line where the func...
2011 Nov 01
0
[LLVMdev] Adding a custom GC safe point creation phase
On 2011-10-31, at 17:21, Nicolas Geoffray wrote: > Here's a patch to allow a GCStrategy to customize the places where it wants to insert safe points. I'm not sure who maintains the GC code today in LLVM (I'd be happy to take ownership, if needed). > > The patch just adds up a custom safepoints flag, similar to the way the GCStrategy can customize intrinsics lowering, or
2011 Oct 31
2
[LLVMdev] Adding a custom GC safe point creation phase
Hi Chris, Gordon, Here's a patch to allow a GCStrategy to customize the places where it wants to insert safe points. I'm not sure who maintains the GC code today in LLVM (I'd be happy to take ownership, if needed). The patch just adds up a custom safepoints flag, similar to the way the GCStrategy can customize intrinsics lowering, or roots initialization. It works pretty well, as
2007 Jan 25
0
[854] trunk/wxruby2/swig/classes: Add support for GridBagSizer
...leased under the MIT-style wxruby2 license + +class wxGBPosition +{ +public: + wxGBPosition() : m_row(0), m_col(0) {} + wxGBPosition(int row, int col) : m_row(row), m_col(col) {} + + // default copy ctor and assignment operator are okay. + + int GetRow() const { return m_row; } + int GetCol() const { return m_col; } + void SetRow(int row) { m_row = row; } + void SetCol(int col) { m_col = col; } + + bool operator==(const wxGBPosition& p) const { return m_row == p.m_row && m_col == p.m_col; } + bool operator!=(const wxGBPosition& p) const { return !(*this ==...