This is an archive of the discontinued LLVM Phabricator instance.

[OpenMP][Offloading] Change `bool IsSPMD` to `int8_t Mode` in `__kmpc_target_init` and `__kmpc_target_deinit`
ClosedPublic

Authored by tianshilei1992 on Sep 22 2021, 12:04 PM.

Details

Summary

This is a follow-up of D110029, which uses bitset to indicate execution mode. This patches makes the changes in the function call.

Diff Detail

Event Timeline

tianshilei1992 requested review of this revision.Sep 22 2021, 12:04 PM
Herald added a reviewer: sstefan1. · View Herald Transcript
Herald added a reviewer: baziotis. · View Herald Transcript
Herald added projects: Restricted Project, Restricted Project, Restricted Project. · View Herald Transcript

fix issues and add more tests

remove unrelated changes introduced by tools

tianshilei1992 retitled this revision from [WIP][OpenMP][Offloading] Change `bool IsSPMD` to `int8_t Mode` in `__kmpc_target_init` and `__kmpc_target_deinit` to [OpenMP][Offloading] Change `bool IsSPMD` to `int8_t Mode` in `__kmpc_target_init` and `__kmpc_target_deinit`.Sep 22 2021, 12:42 PM
tianshilei1992 edited the summary of this revision. (Show Details)

rebase and make changes in new device runtime

jdoerfert accepted this revision.Sep 22 2021, 1:09 PM

This should not change anything, right? Please confirm running a non-trivial example, like miniqmc or so, and then this is good to go.

This revision is now accepted and ready to land.Sep 22 2021, 1:09 PM

This should not change anything, right? Please confirm running a non-trivial example, like miniqmc or so, and then this is good to go.

miniQMC report 26/26 Passed. Will land the patch if Phabricator comes all green.

➜  OMP_NUM_THREADS=4 ctest .
Test project /home/shiltian/Documents/apps/miniqmc/build
      Start  1: unit_test_utilities
 1/26 Test  #1: unit_test_utilities ............................   Passed    0.15 sec
      Start  2: unit_test_particle
 2/26 Test  #2: unit_test_particle .............................   Passed    0.06 sec
      Start  3: unit_test_omptarget_math
 3/26 Test  #3: unit_test_omptarget_math .......................   Passed    0.20 sec
      Start  4: unit_test_omptarget_reduction
 4/26 Test  #4: unit_test_omptarget_reduction ..................   Passed    0.19 sec
      Start  5: unit_test_omptarget_target_task
 5/26 Test  #5: unit_test_omptarget_target_task ................   Passed    0.33 sec
      Start  6: unit_test_omptarget_complex
 6/26 Test  #6: unit_test_omptarget_complex ....................   Passed    0.18 sec
      Start  7: unit_test_omptarget_complex_reduction
 7/26 Test  #7: unit_test_omptarget_complex_reduction ..........   Passed    0.20 sec
      Start  8: unit_test_omptarget_math_with_complex_header
 8/26 Test  #8: unit_test_omptarget_math_with_complex_header ...   Passed    0.07 sec
      Start  9: unit_test_omptarget_memory_interop
 9/26 Test  #9: unit_test_omptarget_memory_interop .............   Passed    0.18 sec
      Start 10: unit_test_omptarget_partial_update
10/26 Test #10: unit_test_omptarget_partial_update .............   Passed    0.18 sec
      Start 11: unit_test_omptarget_partial_update_full
11/26 Test #11: unit_test_omptarget_partial_update_full ........   Passed    0.35 sec
      Start 12: unit_test_omptarget_map_always
12/26 Test #12: unit_test_omptarget_map_always .................   Passed    0.19 sec
      Start 13: unit_test_omptarget_icpx_opencl_wrong_number
13/26 Test #13: unit_test_omptarget_icpx_opencl_wrong_number ...   Passed    0.21 sec
      Start 14: unit_test_omptarget_nowait_taskwait
14/26 Test #14: unit_test_omptarget_nowait_taskwait ............   Passed    0.35 sec
      Start 15: unit_test_omptarget_taskloop
15/26 Test #15: unit_test_omptarget_taskloop ...................   Passed    0.06 sec
      Start 16: unit_test_omptarget_runtime_mem
16/26 Test #16: unit_test_omptarget_runtime_mem ................   Passed    0.18 sec
      Start 17: unit_test_omptarget_map_transfer
17/26 Test #17: unit_test_omptarget_map_transfer ...............   Passed    0.55 sec
      Start 18: unit_test_omptarget_allocator
18/26 Test #18: unit_test_omptarget_allocator ..................   Passed    0.18 sec
      Start 19: unit_test_wavefunction
19/26 Test #19: unit_test_wavefunction .........................   Passed    0.07 sec
      Start 20: unit_test_Drivers
20/26 Test #20: unit_test_Drivers ..............................   Passed    0.06 sec
      Start 21: unit_test_assignDevice
21/26 Test #21: unit_test_assignDevice .........................   Passed    0.09 sec
      Start 22: miniqmc-g111-r1-t16
22/26 Test #22: miniqmc-g111-r1-t16 ............................   Passed    8.12 sec
      Start 23: miniqmc_sync_move-g111-r1-t16
23/26 Test #23: miniqmc_sync_move-g111-r1-t16 ..................   Passed    4.95 sec
      Start 24: check_spo-g111-r1-t16
24/26 Test #24: check_spo-g111-r1-t16 ..........................   Passed    8.29 sec
      Start 25: check_spo_batched-g111-r1-t16
25/26 Test #25: check_spo_batched-g111-r1-t16 ..................   Passed    5.22 sec
      Start 26: check_wfc-g111-r1-t16
26/26 Test #26: check_wfc-g111-r1-t16 ..........................   Passed    0.67 sec

100% tests passed, 0 tests failed out of 26

Label Time Summary:
check      = 226.94 sec*proc (3 tests)
miniqmc    = 209.11 sec*proc (2 tests)
unit       =   4.05 sec*proc (21 tests)

Total Test time (real) =  31.33 sec

update two cases

This revision was landed with ongoing or failed builds.Sep 22 2021, 2:16 PM
This revision was automatically updated to reflect the committed changes.