[clang] [Clang][OpenMP] Clang adding the addrSpace according to DataLayout fix (PR #65483)

via cfe-commits cfe-commits at lists.llvm.org
Tue Sep 12 16:37:49 PDT 2023


gulfemsavrun wrote:

We also started seeing a test failure after this commit:
```
FAIL: Clang :: OpenMP/test_target_uses_allocators_large_cap_codegen.cpp (13374 of 19273)
--
/b/s/w/ir/x/w/llvm-llvm-project/clang/test/OpenMP/test_target_uses_allocators_large_cap_codegen.cpp:167:18: error: CHECK1-LABEL: expected string not found in input
// CHECK1-LABEL: define internal void @{{__omp_offloading_[0-9a-z]+_[0-9a-z]+}}__Z30test_uses_allocators_large_capv_l102(
                 ^
<stdin>:20:75: note: scanning from here
define dso_local noundef signext i32 @_Z30test_uses_allocators_large_capv() #0 {
                                                                          ^
<stdin>:87:1: note: possible intended match here
define internal void @__omp_offloading_801_2c05cbb__Z30test_uses_allocators_large_capv_l94(i64 noundef %x) #1 {
^

Input file: <stdin>
Check file: /b/s/w/ir/x/w/llvm-llvm-project/clang/test/OpenMP/test_target_uses_allocators_large_cap_codegen.cpp

-dump-input=help explains the following input dump.

Input was:
<<<<<<
             .
             .
             .
            15: @.omp_offloading.entry_name = internal unnamed_addr constant [69 x i8] c"__omp_offloading_801_2c05cbb__Z30test_uses_allocators_large_capv_l94\00" 
            16: @.omp_offloading.entry.__omp_offloading_801_2c05cbb__Z30test_uses_allocators_large_capv_l94 = weak constant %struct.__tgt_offload_entry { ptr @.__omp_offloading_801_2c05cbb__Z30test_uses_allocators_large_capv_l94.region_id, ptr @.omp_offloading.entry_name, i64 0, i32 0, i32 0 }, section "omp_offloading_entries", align 1 
            17: @llvm.global_ctors = appending global [1 x { i32, ptr, ptr }] [{ i32, ptr, ptr } { i32 0, ptr @.omp_offloading.requires_reg, ptr null }] 
            18:  
            19: ; Function Attrs: mustprogress noinline nounwind optnone 
            20: define dso_local noundef signext i32 @_Z30test_uses_allocators_large_capv() #0 { 
label:167'0                                                                               X~~~~~~ error: no match found
            21: entry: 
label:167'0     ~~~~~~~
            22:  %x = alloca i32, align 4 
label:167'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~
            23:  %device_result = alloca i32, align 4 
label:167'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            24:  %x.casted = alloca i64, align 8 
label:167'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            25:  %.offload_baseptrs = alloca [2 x ptr], align 8 
label:167'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
             .
             .
             .
            82: omp_offload.cont: ; preds = %omp_offload.failed, %entry 
label:167'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            83:  ret i32 0 
label:167'0     ~~~~~~~~~~~
            84: } 
label:167'0     ~~
            85:  
label:167'0     ~
            86: ; Function Attrs: noinline norecurse nounwind optnone 
label:167'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            87: define internal void @__omp_offloading_801_2c05cbb__Z30test_uses_allocators_large_capv_l94(i64 noundef %x) #1 { 
label:167'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
label:167'1     ?                                                                                                                possible intended match
            88: entry: 
label:167'0     ~~~~~~~
            89:  %x.addr = alloca i64, align 8 
label:167'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            90:  %0 = call i32 @__kmpc_global_thread_num(ptr @1) 
label:167'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            91:  store i64 %x, ptr %x.addr, align 8 
label:167'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            92:  %.x..void.addr = call ptr @__kmpc_alloc(i32 %0, i64 4, ptr inttoptr (i64 2 to ptr)) 
label:167'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
             .
             .
             .
>>>>>>

--
```

https://logs.chromium.org/logs/fuchsia/buildbucket/cr-buildbucket/8770130626803585601/+/u/clang/test/stdout

https://github.com/llvm/llvm-project/pull/65483


More information about the cfe-commits mailing list