search for: eleptr2

Displaying 2 results from an estimated 2 matches for "eleptr2".

Did you mean: eleptr1
2014 Aug 02
2
[LLVMdev] Create "appending" section that can be partially dead stripped
On 01/08/14 19:37, Reid Kleckner wrote: > What happens if you drop appending linkage? I think it will just work, > since you are already using a custom section, which will ensure that all > the data appears contiguously in memory. Thanks for the suggestion, but it still puts everything in a single .section statement. > Although, I do worry about what LLVM's alias analysis will
2014 Aug 05
2
[LLVMdev] Create "appending" section that can be partially dead stripped
...64-v128:128:128-a0:0:64-s0:64:64- f80:128:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" define i32 @main() { Entry: %sumvar = alloca i32 ; make the second and third element live by directly referring them %eleptr1 = getelementptr [2 x i32]* @arr2, i64 0, i32 0 %eleptr2 = getelementptr [2 x i32]* @arr3, i64 0, i32 0 %ele1 = load i32* %eleptr1 %ele2 = load i32* %eleptr2 %sum1 = add i32 %ele1, %ele2 store i32 %sum1, i32* %sumvar ; now loop over the entire array by using @arrstart and @arrstop %loopstop = ptrtoint [0 x i32]* @arrstop to i64 %loopstart =...