2,247 changes: 2,247 additions & 0 deletions llvm/test/Transforms/OpenMP/custom_state_machines_pre_lto.ll

Large diffs are not rendered by default.

5 changes: 4 additions & 1 deletion llvm/test/Transforms/OpenMP/custom_state_machines_remarks.ll
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,10 @@ user_code.entry: ; preds = %entry
br label %common.ret
}

declare i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1) local_unnamed_addr
; Make it a weak definition so we will apply custom state machine rewriting but can't use the body in the reasoning.
define weak i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1) {
ret i32 0
}

; Function Attrs: convergent
declare void @unknown() local_unnamed_addr #1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,10 @@ worker.exit: ; preds = %entry
ret void
}

declare i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1)
define weak i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1) {
ret i32 0
}

declare void @unknown()

define internal void @__omp_outlined__(i32* noalias %.global_tid., i32* noalias %.bound_tid.) {
Expand Down
5 changes: 4 additions & 1 deletion llvm/test/Transforms/OpenMP/remove_globalization.ll
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,10 @@ target triple = "nvptx64"

%struct.ident_t = type { i32, i32, i32, i32, i8* }

declare i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1)
; Make it a weak definition so we will apply custom state machine rewriting but can't use the body in the reasoning.
define weak i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1) {
ret i32 0
}
declare void @__kmpc_target_deinit(%struct.ident_t*, i8, i1)

;.
Expand Down
5 changes: 4 additions & 1 deletion llvm/test/Transforms/OpenMP/replace_globalization.ll
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,10 @@ declare i32 @llvm.nvvm.read.ptx.sreg.ntid.x()

declare i32 @llvm.nvvm.read.ptx.sreg.warpsize()

declare i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1)
; Make it a weak definition so we will apply custom state machine rewriting but can't use the body in the reasoning.
define weak i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1) {
ret i32 0
}

declare void @__kmpc_target_deinit(%struct.ident_t*, i8, i1)

Expand Down
5 changes: 4 additions & 1 deletion llvm/test/Transforms/OpenMP/spmdization.ll
Original file line number Diff line number Diff line change
Expand Up @@ -2257,7 +2257,10 @@ declare void @unknowni32p(i32*) #2
; Function Attrs: argmemonly mustprogress nofree nosync nounwind willreturn
declare void @llvm.lifetime.start.p0i8(i64 immarg, i8* nocapture) #1

declare i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1)
; Make it a weak definition so we will apply custom state machine rewriting but can't use the body in the reasoning.
define weak i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1) {
ret i32 0
}

declare void @__kmpc_get_shared_variables(i8***)

Expand Down
5 changes: 4 additions & 1 deletion llvm/test/Transforms/OpenMP/spmdization_guarding.ll
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,10 @@ define internal void @__omp_outlined__1_wrapper(i16 zeroext %0, i32 %1) {

declare void @__kmpc_parallel_51(%struct.ident_t*, i32, i32, i32, i32, i8*, i8*, i8**, i64)

declare i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1)
; Make it a weak definition so we will apply custom state machine rewriting but can't use the body in the reasoning.
define weak i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1) {
ret i32 0
}

; Function Attrs: convergent
declare i32 @no_openmp(i32*) #1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,10 @@ worker.exit: ; preds = %entry
ret void
}

declare i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1)
; Make it a weak definition so we will apply custom state machine rewriting but can't use the body in the reasoning.
define weak i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1) {
ret i32 0
}

declare void @__kmpc_target_deinit(%struct.ident_t*, i8, i1)

Expand Down
5 changes: 4 additions & 1 deletion llvm/test/Transforms/OpenMP/spmdization_remarks.ll
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,10 @@ user_code.entry: ; preds = %entry
br label %common.ret
}

declare i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1) local_unnamed_addr
define weak i32 @__kmpc_target_init(%struct.ident_t*, i8, i1, i1) {
ret i32 0
}


; Function Attrs: convergent
declare void @unknown() local_unnamed_addr #1
Expand Down