[OpenMP] Run the Attributor as part of the device runtime optimization
authorJohannes Doerfert <johannes@jdoerfert.de>
Tue, 24 Jan 2023 03:45:06 +0000 (19:45 -0800)
committerJohannes Doerfert <johannes@jdoerfert.de>
Tue, 24 Jan 2023 06:45:47 +0000 (22:45 -0800)
This will help us propagate assumptions to call sites, among other
things.

openmp/libomptarget/DeviceRTL/CMakeLists.txt

index 872dcb4..49b398c 100644 (file)
@@ -114,7 +114,7 @@ set(src_files
 )
 
 set(clang_opt_flags -O3 -mllvm -openmp-opt-disable -DSHARED_SCRATCHPAD_SIZE=512)
-set(link_opt_flags  -O3        -openmp-opt-disable)
+set(link_opt_flags  -O3        -openmp-opt-disable -attributor-enable=module)
 set(link_export_flag -passes=internalize -internalize-public-api-file=${source_directory}/exports)
 set(link_extract_flag --func='__keep_alive' --delete)