Skip to content

Commit d8c83ca

Browse files
committed
fix offload section name
1 parent feabec8 commit d8c83ca

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

compiler/rustc_codegen_llvm/src/builder/gpu_offload.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ fn gen_define_handling<'ll>(
227227
let o_types =
228228
add_priv_unnamed_arr(&cx, &format!(".offload_maptypes.{num}"), &vec![3; num_ptr_types]);
229229
// Next: For each function, generate these three entries. A weak constant,
230-
// the llvm.rodata entry name, and the omp_offloading_entries value
230+
// the llvm.rodata entry name, and the llvm_offload_entries value
231231

232232
let name = format!(".kernel_{num}.region_id");
233233
let initializer = cx.get_const_i8(0);
@@ -262,7 +262,7 @@ fn gen_define_handling<'ll>(
262262
llvm::set_linkage(llglobal, WeakAnyLinkage);
263263
llvm::set_initializer(llglobal, initializer);
264264
llvm::set_alignment(llglobal, Align::ONE);
265-
let c_section_name = CString::new(".omp_offloading_entries").unwrap();
265+
let c_section_name = CString::new("llvm_offload_entries").unwrap();
266266
llvm::set_section(llglobal, &c_section_name);
267267
(o_types, region_id)
268268
}

0 commit comments

Comments
 (0)