Commit 6737371
committed
Do not modify the LLType of the argument
If we generate initialization function for SPMD
kernels we need to store addresses of the arguments before
we call kmpc_parallel_51 function. We use ptrtoint instruction
for scalar variables. Before this patch the LLVM IR code was generated
wrongly for complex variables:
void kernel_func(<float, float> *Arg_c)
//some code
ptrtoint i64* %Arg_c //error Arg_c was declared as pair of floats
//some code
call kmpc_parallel_51()
//some code
This patch causes that LLVM IR contains correct ptrtoint instruction:
void kernel_func(<float, float> *Arg_c)
//some code
ptrtoint <float, float>* %Arg_c //ok, Arg_c was declared as pair of floats
//some code
call kmpc_parallel_51()
//some code
Signed-off-by: Dominik Adamski <[email protected]>1 parent 5de4a26 commit 6737371
3 files changed
+9
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12267 | 12267 | | |
12268 | 12268 | | |
12269 | 12269 | | |
12270 | | - | |
| 12270 | + | |
12271 | 12271 | | |
12272 | 12272 | | |
12273 | 12273 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
237 | 237 | | |
238 | 238 | | |
239 | 239 | | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
240 | 245 | | |
241 | 246 | | |
242 | 247 | | |
| |||
806 | 811 | | |
807 | 812 | | |
808 | 813 | | |
809 | | - | |
| 814 | + | |
| 815 | + | |
810 | 816 | | |
811 | 817 | | |
812 | 818 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
162 | 162 | | |
163 | 163 | | |
164 | 164 | | |
| 165 | + | |
165 | 166 | | |
166 | 167 | | |
167 | 168 | | |
| |||
0 commit comments