[PATCH] D69268: [HIP] Add option -fgpu-allow-device-init

Artem Belevich via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Oct 21 10:55:45 PDT 2019


tra accepted this revision.
tra added a comment.
This revision is now accepted and ready to land.

Nice. I wish we could do that for CUDA.



================
Comment at: lib/Frontend/CompilerInvocation.cpp:2530
   Opts.GPURelocatableDeviceCode = Args.hasArg(OPT_fgpu_rdc);
+  Opts.GPUAllowDeviceInit = Args.hasArg(OPT_fgpu_allow_device_init);
   Opts.HIPUseNewLaunchAPI = Args.hasArg(OPT_fhip_new_launch_api);
----------------
It would be useful if we could get a warning if someone attempts to use this option for CUDA compilation, where the compiler will not enable device-side init.




CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D69268/new/

https://reviews.llvm.org/D69268





More information about the cfe-commits mailing list