AntonRydahl created this revision. AntonRydahl added a reviewer: jdoerfert. Herald added a reviewer: awarzynski. Herald added projects: Flang, All. AntonRydahl requested review of this revision. Herald added subscribers: cfe-commits, wangpc. Herald added a project: clang.
I believe the help text for the flag `--offload-host-device` is wrong. Currently, the help text says "Only compile for the offloading host." but the flag alias with `--cuda-compile-host-device` which has the help text "Compile CUDA code for both host and device (default). Has no effect on non-CUDA compilations." Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D156641 Files: clang/include/clang/Driver/Options.td flang/test/Driver/driver-help-hidden.f90 flang/test/Driver/driver-help.f90 Index: flang/test/Driver/driver-help.f90 =================================================================== --- flang/test/Driver/driver-help.f90 +++ flang/test/Driver/driver-help.f90 @@ -80,7 +80,7 @@ ! HELP-NEXT: -module-dir <dir> Put MODULE files in <dir> ! HELP-NEXT: -nocpp Disable predefined and command line preprocessor macros ! HELP-NEXT: --offload-device-only Only compile for the offloading device. -! HELP-NEXT: --offload-host-device Only compile for the offloading host. +! HELP-NEXT: --offload-host-device Compile for both the offloading host and device (default). ! HELP-NEXT: --offload-host-only Only compile for the offloading host. ! HELP-NEXT: -o <file> Write output to <file> ! HELP-NEXT: -pedantic Warn on language extensions Index: flang/test/Driver/driver-help-hidden.f90 =================================================================== --- flang/test/Driver/driver-help-hidden.f90 +++ flang/test/Driver/driver-help-hidden.f90 @@ -84,7 +84,7 @@ ! CHECK-NEXT: -module-dir <dir> Put MODULE files in <dir> ! CHECK-NEXT: -nocpp Disable predefined and command line preprocessor macros ! CHECK-NEXT: --offload-device-only Only compile for the offloading device. -! CHECK-NEXT: --offload-host-device Only compile for the offloading host. +! CHECK-NEXT: --offload-host-device Compile for both the offloading host and device (default). ! CHECK-NEXT: --offload-host-only Only compile for the offloading host. ! CHECK-NEXT: -o <file> Write output to <file> ! CHECK-NEXT: -pedantic Warn on language extensions Index: clang/include/clang/Driver/Options.td =================================================================== --- clang/include/clang/Driver/Options.td +++ clang/include/clang/Driver/Options.td @@ -2875,7 +2875,7 @@ def offload_host_only : Flag<["--"], "offload-host-only">, Flags<[FlangOption]>, HelpText<"Only compile for the offloading host.">; def offload_host_device : Flag<["--"], "offload-host-device">, Flags<[FlangOption]>, - HelpText<"Only compile for the offloading host.">; + HelpText<"Compile for both the offloading host and device (default).">; def cuda_device_only : Flag<["--"], "cuda-device-only">, Alias<offload_device_only>, HelpText<"Compile CUDA code for device only">; def cuda_host_only : Flag<["--"], "cuda-host-only">, Alias<offload_host_only>,
Index: flang/test/Driver/driver-help.f90 =================================================================== --- flang/test/Driver/driver-help.f90 +++ flang/test/Driver/driver-help.f90 @@ -80,7 +80,7 @@ ! HELP-NEXT: -module-dir <dir> Put MODULE files in <dir> ! HELP-NEXT: -nocpp Disable predefined and command line preprocessor macros ! HELP-NEXT: --offload-device-only Only compile for the offloading device. -! HELP-NEXT: --offload-host-device Only compile for the offloading host. +! HELP-NEXT: --offload-host-device Compile for both the offloading host and device (default). ! HELP-NEXT: --offload-host-only Only compile for the offloading host. ! HELP-NEXT: -o <file> Write output to <file> ! HELP-NEXT: -pedantic Warn on language extensions Index: flang/test/Driver/driver-help-hidden.f90 =================================================================== --- flang/test/Driver/driver-help-hidden.f90 +++ flang/test/Driver/driver-help-hidden.f90 @@ -84,7 +84,7 @@ ! CHECK-NEXT: -module-dir <dir> Put MODULE files in <dir> ! CHECK-NEXT: -nocpp Disable predefined and command line preprocessor macros ! CHECK-NEXT: --offload-device-only Only compile for the offloading device. -! CHECK-NEXT: --offload-host-device Only compile for the offloading host. +! CHECK-NEXT: --offload-host-device Compile for both the offloading host and device (default). ! CHECK-NEXT: --offload-host-only Only compile for the offloading host. ! CHECK-NEXT: -o <file> Write output to <file> ! CHECK-NEXT: -pedantic Warn on language extensions Index: clang/include/clang/Driver/Options.td =================================================================== --- clang/include/clang/Driver/Options.td +++ clang/include/clang/Driver/Options.td @@ -2875,7 +2875,7 @@ def offload_host_only : Flag<["--"], "offload-host-only">, Flags<[FlangOption]>, HelpText<"Only compile for the offloading host.">; def offload_host_device : Flag<["--"], "offload-host-device">, Flags<[FlangOption]>, - HelpText<"Only compile for the offloading host.">; + HelpText<"Compile for both the offloading host and device (default).">; def cuda_device_only : Flag<["--"], "cuda-device-only">, Alias<offload_device_only>, HelpText<"Compile CUDA code for device only">; def cuda_host_only : Flag<["--"], "cuda-host-only">, Alias<offload_host_only>,
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits