Failure to compile TF 2.15  from source on rocky 8.8
Any updates on this? Thanks > Any updates on this? Thanks

Not sure if this will help, but the issue is on the nvidia side.  https://stackoverflow.com/questions/70301375/noinline-macro-conflict-between-glib-and-cuda Thank you for the pointer. 
Looked at the links. Cuda headers do have mentioned wrappers for __noinline__ which seem to be the correct setting.  
Clang community  points to cuda sdk and  its not clear who is supposed to be doing a patch or when one is valid. 

Is there any configuration of later versions of tensorflow  that was done on RPM-based (CentOS or derivative) system?
This guide https://www.tensorflow.org/install/source#gpu seem to be for ubuntu and any configuration i tried for tensorflow
from 2.13 and up is not working
### Issue type

Build/Install

### Have you reproduced the bug with TensorFlow Nightly?

No

### Source

source

### TensorFlow version

2.15.0

### Custom code

No

### OS platform and distribution

rocky linux 8.8

### Mobile device

no

### Python version

3.10.2

### Bazel version

6.1.0

### GCC/compiler version

gcc 11.2.0  and clang 16.0.1

### CUDA/cuDNN version

12.2.0

### GPU model and memory

tesla v100

### Current behavior?

Compiling fails with an error. Log is shown below.
We are using all software  that compiled in house  as needed for the HPC cluster.
For the compilation the following modules are loaded 
```
bazel/6.1.0  cuda/12.2.0  python/3.10.2  tensorRT/8.6.1.6  java/11  gcc/11.2.0  llvm/16.0.1  clang/16.0.1
```

CASE 1: Running .configure results in this .tf.configure.bazelrc file:

```
build --action_env PYTHON_BIN_PATH="/opt/apps/python/3.10.2/bin/python3"
build --action_env PYTHON_LIB_PATH="/opt/apps/python/3.10.2/lib/python3.10/site-packages"
build --python_path="/opt/apps/python/3.10.2/bin/python3"
build --config=tensorrt
build --action_env TF_CUDA_VERSION="12"
build --action_env TF_CUDNN_VERSION="8"
build --action_env TF_TENSORRT_VERSION="8"
build --action_env TF_NCCL_VERSION=""
build --action_env TF_CUDA_PATHS="/opt/apps/cuda/12.2.0,/opt/apps/tensorRT/8.6.1.6,/usr"
build --action_env CUDA_TOOLKIT_PATH="/opt/apps/cuda/12.2.0"
build --action_env TF_CUDA_COMPUTE_CAPABILITIES="7.0,8.0"
build --action_env LD_LIBRARY_PATH="/opt/apps/clang/16.0.1/lib:/opt/apps/llvm/16.0.1/lib:/opt/apps/gcc/11.2.0/lib64:/opt/apps/gcc/11.2.0/lib:/opt/apps/gcc/11.2.0/lib/gcc/x86_64-pc-linux-gnu/11.2.0:/opt/apps/tensorRT/8.6.1.6/lib:/opt/apps/python/3.10.2
/lib:/opt/apps/cuda/12.2.0/lib64:/opt/apps/cuda/12.2.0/nvvm/lib64:/opt/apps/cuda/12.2.0/cublas/lib64:/opt/apps/cuda/12.2.0/extras/CUPTI/lib64:/opt/apps/cuda/12.2.0/extras/Debugger/lib64"
build --config=cuda_clang
build --action_env CLANG_CUDA_COMPILER_PATH="/opt/apps/clang/16.0.1/bin/clang-16"
build --copt=-Wno-gnu-offsetof-extensions
build --config=cuda_clang
build:opt --copt=-mavx2
build:opt --host_copt=-mavx2
test --test_size_filters=small,medium
test --test_env=LD_LIBRARY_PATH
test:v1 --test_tag_filters=-benchmark-test,-no_oss,-oss_excluded,-gpu,-oss_serial
test:v1 --build_tag_filters=-benchmark-test,-no_oss,-oss_excluded,-gpu
test:v2 --test_tag_filters=-benchmark-test,-no_oss,-oss_excluded,-gpu,-oss_serial,-v1only
test:v2 --build_tag_filters=-benchmark-test,-no_oss,-oss_excluded,-gpu,-v1only
```

CASE 2: If i rerun configure and choose not to use clang as cuda compiler it results in a slightly
different .tf.configure.bazelrc file  here are the diffs:

```
dont use clang
< build --action_env GCC_HOST_COMPILER_PATH="/opt/apps/gcc/11.2.0/bin/gcc"
< build --config=cuda
---
use clang
> build --config=cuda_clang
> build --action_env CLANG_CUDA_COMPILER_PATH="/opt/apps/clang/16.0.1/bin/clang-16"
> build --copt=-Wno-gnu-offsetof-extensions
> build --config=cuda_clang
```

Either way, with or without clang  in configuration bazel build fails.

For the CASE 2 compilation went further, but bazel subcommand failed with errors  apparently linking to
 /lib64/libstdc++.so.6 ( see log part below). This library should not  used as my LD_LIBRARY_PATH is set 
to use clang 16 and gcc 11.2.0 path first and gcc compilation includes libstdc++.so.6 that has all needed  CXXABI and GLIBCXX entries. Bazel binary and clang libraries are linked to use that correct libstdc++.so.6 supplied by gcc 11..2.0


### Standalone code to reproduce the issue

```shell
bazel build --config=opt --jobs=8 --verbose_failures --verbose_explanations \
            --explain=/tmp/explain //tensorflow/tools/pip_package:build_pip_package
```


### Relevant log output

```shell
### CASE 1 log:

Extracting Bazel installation...
Starting local Bazel server and connecting to it...
WARNING: The following configs were expanded more than once: [tensorrt, cuda_clang, cuda]. For repeatable flags, repeats are counted twice and may lead to unexpected behavior.
INFO: Reading 'startup' options from /export/repositories/tensorflow admix/yamlspecs/tensorflow-2.15.0/.bazelrc: --windows_enable_symlinks
INFO: Options provided by the client:
  Inherited 'common' options: --isatty=0 --terminal_columns=80
INFO: Reading rc options for 'build' from /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc:
  Inherited 'common' options: --experimental_repo_remote_exec
INFO: Reading rc options for 'build' from /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc:
  'build' options: --define framework_shared_object=true --define tsl_protobuf_header_only=true --define=use_fast_cpp_protos=true --define=allow_oversize_protos=true --spawn_strategy=standalone -c opt --announce_rc --define=grpc_no_ar
es=true --noincompatible_remove_legacy_whole_archive --features=-force_no_whole_archive --enable_platform_specific_config --define=with_xla_support=true --config=short_logs --config=v2 --define=no_aws_support=true --define=no_hdfs_sup
port=true --experimental_cc_shared_library --experimental_link_static_libraries_once=false --incompatible_enforce_config_setting_visibility
INFO: Reading rc options for 'build' from /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.tf_configure.bazelrc:
  'build' options: --action_env PYTHON_BIN_PATH=/opt/apps/python/3.10.2/bin/python3 --action_env PYTHON_LIB_PATH=/opt/apps/python/3.10.2/lib/python3.10/site-packages --python_path=/opt/apps/python/3.10.2/bin/python3 --config=tensorrt 
--action_env TF_CUDA_VERSION=12 --action_env TF_CUDNN_VERSION=8 --action_env TF_TENSORRT_VERSION=8 --action_env TF_NCCL_VERSION= --action_env TF_CUDA_PATHS=/opt/apps/cuda/12.2.0,/opt/apps/tensorRT/8.6.1.6,/usr --action_env CUDA_TOOLKI
T_PATH=/opt/apps/cuda/12.2.0 --action_env TF_CUDA_COMPUTE_CAPABILITIES=7.0,8.0 --action_env LD_LIBRARY_PATH=/opt/apps/clang/16.0.1/lib:/opt/apps/llvm/16.0.1/lib:/opt/apps/gcc/11.2.0/lib64:/opt/apps/gcc/11.2.0/lib:/opt/apps/gcc/11.2.0/
lib/gcc/x86_64-pc-linux-gnu/11.2.0:/opt/apps/tensorRT/8.6.1.6/lib:/opt/apps/python/3.10.2/lib:/opt/apps/cuda/12.2.0/lib64:/opt/apps/cuda/12.2.0/nvvm/lib64:/opt/apps/cuda/12.2.0/cublas/lib64:/opt/apps/cuda/12.2.0/extras/CUPTI/lib64:/op
t/apps/cuda/12.2.0/extras/Debugger/lib64 --config=cuda_clang --action_env CLANG_CUDA_COMPILER_PATH=/opt/apps/clang/16.0.1/bin/clang-16 --copt=-Wno-gnu-offsetof-extensions --config=cuda_clang
INFO: Found applicable config definition build:short_logs in file /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc: --output_filter=DONT_MATCH_ANYTHING
INFO: Found applicable config definition build:v2 in file /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc: --define=tf_api_version=2 --action_env=TF2_BEHAVIOR=1
INFO: Found applicable config definition build:tensorrt in file /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc: --repo_env TF_NEED_TENSORRT=1
INFO: Found applicable config definition build:cuda_clang in file /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc: --config=cuda --config=tensorrt --action_env=TF_CUDA_CLANG=1 --@local_config_cuda//:cuda_com
piler=clang --repo_env=TF_CUDA_COMPUTE_CAPABILITIES=sm_50,sm_60,sm_70,sm_75,compute_80
INFO: Found applicable config definition build:cuda in file /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc: --repo_env TF_NEED_CUDA=1 --crosstool_top=@local_config_cuda//crosstool:toolchain --@local_config_
cuda//:enable_cuda
INFO: Found applicable config definition build:tensorrt in file /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc: --repo_env TF_NEED_TENSORRT=1
INFO: Found applicable config definition build:cuda_clang in file /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc: --config=cuda --config=tensorrt --action_env=TF_CUDA_CLANG=1 --@local_config_cuda//:cuda_com
piler=clang --repo_env=TF_CUDA_COMPUTE_CAPABILITIES=sm_50,sm_60,sm_70,sm_75,compute_80
INFO: Found applicable config definition build:cuda in file /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc: --repo_env TF_NEED_CUDA=1 --crosstool_top=@local_config_cuda//crosstool:toolchain --@local_config_
cuda//:enable_cuda
INFO: Found applicable config definition build:tensorrt in file /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc: --repo_env TF_NEED_TENSORRT=1
INFO: Found applicable config definition build:opt in file /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.tf_configure.bazelrc: --copt=-mavx2 --host_copt=-mavx2
INFO: Found applicable config definition build:linux in file /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc: --host_copt=-w --copt=-Wno-all --copt=-Wno-extra --copt=-Wno-deprecated --copt=-Wno-deprecated-de
clarations --copt=-Wno-ignored-attributes --copt=-Wno-array-bounds --copt=-Wunused-result --copt=-Werror=unused-result --copt=-Wswitch --copt=-Werror=switch --copt=-Wno-error=unused-but-set-variable --define=PREFIX=/usr --define=LIBDI
R=$(PREFIX)/lib --define=INCLUDEDIR=$(PREFIX)/include --define=PROTOBUF_INCLUDE_PATH=$(PREFIX)/include --cxxopt=-std=c++17 --host_cxxopt=-std=c++17 --config=dynamic_kernels --experimental_guard_against_concurrent_changes
INFO: Found applicable config definition build:dynamic_kernels in file /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/.bazelrc: --define=dynamic_loaded_kernels=true --copt=-DAUTOLOAD_DYNAMIC_KERNELS
Loading: 
Loading: 
DEBUG: /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/tensorflow/tools/toolchains/python/python_repo.bzl:21:14: 
TF_PYTHON_VERSION variable was not set correctly, using default version. 3.10 Python
will be used.

### successful compile lines are removed for brevity ###

[15,675 / 19,610] Compiling tensorflow/compiler/mlir/tosa/transforms/legalize_tfl.cc; 33s local ... (8 actions running)
[15,676 / 19,610] Compiling tensorflow/compiler/mlir/tosa/transforms/legalize_tfl.cc; 38s local ... (8 actions, 7 running)
[15,679 / 19,612] Compiling tensorflow/compiler/mlir/tosa/transforms/legalize_tfl.cc; 39s local ... (8 actions running)
ERROR: /export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.15.0/tensorflow/core/kernels/BUILD:5338:18: Compiling tensorflow/core/kernels/scatter_op_gpu.cu.cc failed: (Exit 1): clang-16 failed: error executing command (from ta
rget //tensorflow/core/kernels:scatter_op_gpu) 
  (cd /root/.cache/bazel/_bazel_root/e76370378c3e9e8e238b869c10fc760e/execroot/org_tensorflow && \
  exec env - \
    CLANG_CUDA_COMPILER_PATH=/opt/apps/clang/16.0.1/bin/clang-16 \
    CUDA_TOOLKIT_PATH=/opt/apps/cuda/12.2.0 \
    LD_LIBRARY_PATH=/opt/apps/clang/16.0.1/lib:/opt/apps/llvm/16.0.1/lib:/opt/apps/gcc/11.2.0/lib64:/opt/apps/gcc/11.2.0/lib:/opt/apps/gcc/11.2.0/lib/gcc/x86_64-pc-linux-gnu/11.2.0:/opt/apps/tensorRT/8.6.1.6/lib:/opt/apps/python/3.10.
2/lib:/opt/apps/cuda/12.2.0/lib64:/opt/apps/cuda/12.2.0/nvvm/lib64:/opt/apps/cuda/12.2.0/cublas/lib64:/opt/apps/cuda/12.2.0/extras/CUPTI/lib64:/opt/apps/cuda/12.2.0/extras/Debugger/lib64 \
    PATH=/opt/apps/clang/16.0.1/bin:/opt/apps/llvm/16.0.1/bin:/opt/apps/gcc/11.2.0/bin:/usr/lib/jvm/java-11/bin:/usr/lib/jvm/jre-11/bin:/opt/apps/tensorRT/8.6.1.6/bin:/opt/apps/python/3.10.2/bin:/opt/apps/cuda/12.2.0/bin:/opt/apps/baz
el/6.1.0/bin:/opt/rcic/bin:/usr/share/Modules/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/root/bin \
    PWD=/proc/self/cwd \
    PYTHON_BIN_PATH=/opt/apps/python/3.10.2/bin/python3 \
    PYTHON_LIB_PATH=/opt/apps/python/3.10.2/lib/python3.10/site-packages \
    TF2_BEHAVIOR=1 \
    TF_CUDA_CLANG=1 \
    TF_CUDA_COMPUTE_CAPABILITIES=7.0,8.0 \
    TF_CUDA_PATHS=/opt/apps/cuda/12.2.0,/opt/apps/tensorRT/8.6.1.6,/usr \
    TF_CUDA_VERSION=12 \
    TF_CUDNN_VERSION=8 \
    TF_NCCL_VERSION='' \
    TF_TENSORRT_VERSION=8 \
  /opt/apps/clang/16.0.1/bin/clang-16 -MD -MF bazel-out/k8-opt/bin/tensorflow/core/kernels/_objs/scatter_op_gpu/scatter_op_gpu.cu.pic.d '-frandom-seed=bazel-out/k8-opt/bin/tensorflow/core/kernels/_objs/scatter_op_gpu/scatter_op_gpu.cu
.pic.o' -DEIGEN_MPL2_ONLY '-DEIGEN_MAX_ALIGN_BYTES=64' -DHAVE_SYS_UIO_H -DTF_USE_SNAPPY '-DBAZEL_CURRENT_REPOSITORY=""' -iquote . -iquote bazel-out/k8-opt/bin -iquote external/com_google_absl -iquote bazel-out/k8-opt/bin/external/com_
google_absl -iquote external/nsync -iquote bazel-out/k8-opt/bin/external/nsync -iquote external/com_google_protobuf -iquote bazel-out/k8-opt/bin/external/com_google_protobuf -iquote external/local_tsl -iquote bazel-out/k8-opt/bin/exte
rnal/local_tsl -iquote external/com_googlesource_code_re2 -iquote bazel-out/k8-opt/bin/external/com_googlesource_code_re2 -iquote external/farmhash_archive -iquote bazel-out/k8-opt/bin/external/farmhash_archive -iquote external/fft2d 
-iquote bazel-out/k8-opt/bin/external/fft2d -iquote external/highwayhash -iquote bazel-out/k8-opt/bin/external/highwayhash -iquote external/gif -iquote bazel-out/k8-opt/bin/external/gif -iquote external/libjpeg_turbo -iquote bazel-out
/k8-opt/bin/external/libjpeg_turbo -iquote external/zlib -iquote bazel-out/k8-opt/bin/external/zlib -iquote external/eigen_archive -iquote bazel-out/k8-opt/bin/external/eigen_archive -iquote external/ml_dtypes -iquote bazel-out/k8-opt
/bin/external/ml_dtypes -iquote external/local_config_cuda -iquote bazel-out/k8-opt/bin/external/local_config_cuda -iquote external/snappy -iquote bazel-out/k8-opt/bin/external/snappy -iquote external/double_conversion -iquote bazel-o
ut/k8-opt/bin/external/double_conversion -iquote external/nccl_archive -iquote bazel-out/k8-opt/bin/external/nccl_archive -iquote external/local_config_rocm -iquote bazel-out/k8-opt/bin/external/local_config_rocm -iquote external/loca
l_config_tensorrt -iquote bazel-out/k8-opt/bin/external/local_config_tensorrt -iquote external/local_xla -iquote bazel-out/k8-opt/bin/external/local_xla -Ibazel-out/k8-opt/bin/external/ml_dtypes/_virtual_includes/float8 -Ibazel-out/k8
-opt/bin/external/ml_dtypes/_virtual_includes/int4 -Ibazel-out/k8-opt/bin/external/local_config_cuda/cuda/_virtual_includes/cuda_headers_virtual -Ibazel-out/k8-opt/bin/external/nccl_archive/_virtual_includes/nccl_config -Ibazel-out/k8
-opt/bin/external/local_config_tensorrt/_virtual_includes/tensorrt_headers -isystem external/nsync/public -isystem bazel-out/k8-opt/bin/external/nsync/public -isystem external/com_google_protobuf/src -isystem bazel-out/k8-opt/bin/exte
rnal/com_google_protobuf/src -isystem external/farmhash_archive/src -isystem bazel-out/k8-opt/bin/external/farmhash_archive/src -isystem external/gif -isystem bazel-out/k8-opt/bin/external/gif -isystem external/zlib -isystem bazel-out
/k8-opt/bin/external/zlib -isystem third_party/eigen3/mkl_include -isystem bazel-out/k8-opt/bin/third_party/eigen3/mkl_include -isystem external/eigen_archive -isystem bazel-out/k8-opt/bin/external/eigen_archive -isystem external/ml_d
types -isystem bazel-out/k8-opt/bin/external/ml_dtypes -isystem external/ml_dtypes/ml_dtypes -isystem bazel-out/k8-opt/bin/external/ml_dtypes/ml_dtypes -isystem external/local_config_cuda/cuda -isystem bazel-out/k8-opt/bin/external/lo
cal_config_cuda/cuda -isystem external/local_config_cuda/cuda/cuda/include -isystem bazel-out/k8-opt/bin/external/local_config_cuda/cuda/cuda/include -isystem external/local_config_rocm/rocm -isystem bazel-out/k8-opt/bin/external/loca
l_config_rocm/rocm -isystem external/local_config_rocm/rocm/rocm/include -isystem bazel-out/k8-opt/bin/external/local_config_rocm/rocm/rocm/include -isystem external/local_config_rocm/rocm/rocm/include/rocrand -isystem bazel-out/k8-op
t/bin/external/local_config_rocm/rocm/rocm/include/rocrand -isystem external/local_config_rocm/rocm/rocm/include/roctracer -isystem bazel-out/k8-opt/bin/external/local_config_rocm/rocm/rocm/include/roctracer -fmerge-all-constants -Wno
-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -fPIC -U_FORTIFY_SOURCE '-D_FORTIFY_SOURCE=1' -fstack-protector -Wall -Wno-invalid-partial-specialization -fno-omit-frame-pointer -n
o-canonical-prefixes -DNDEBUG -g0 -O2 -ffunction-sections -fdata-sections '--cuda-path=/opt/apps/cuda/12.2.0' -Wno-all -Wno-extra -Wno-deprecated -Wno-deprecated-declarations -Wno-ignored-attributes -Wno-array-bounds -Wunused-result '
-Werror=unused-result' -Wswitch '-Werror=switch' '-Wno-error=unused-but-set-variable' -DAUTOLOAD_DYNAMIC_KERNELS -Wno-gnu-offsetof-extensions -mavx2 '-std=c++17' -x cuda '-DGOOGLE_CUDA=1' '--no-cuda-include-ptx=all' '--cuda-gpu-arch=s
m_50' '--cuda-gpu-arch=sm_60' '--cuda-gpu-arch=sm_70' '--cuda-gpu-arch=sm_75' '--cuda-include-ptx=sm_80' '--cuda-gpu-arch=sm_80' -O3 -Xcuda-fatbinary --compress-all -DEIGEN_AVOID_STL_ARRAY -Iexternal/gemmlowp -Wno-sign-compare '-ftemp
late-depth=900' -fno-exceptions '-DGOOGLE_CUDA=1' '-DTENSORFLOW_USE_XLA=1' '-DGOOGLE_TENSORRT=1' -DINTEL_MKL -DENABLE_ONEDNN_V3 -DAMD_ZENDNN -msse3 -pthread -fcuda-flush-denormals-to-zero -c tensorflow/core/kernels/scatter_op_gpu.cu.c
c -o bazel-out/k8-opt/bin/tensorflow/core/kernels/_objs/scatter_op_gpu/scatter_op_gpu.cu.pic.o)
# Configuration: c9cdf7815656ac88d2cb4421ef529bda74485e1ed473208091218e401f0f31b0
# Execution platform: @local_execution_config_platform//:platform
clang-16: warning: CUDA version is newer than the latest partially supported version 11.8 [-Wunknown-cuda-version]
In file included from tensorflow/core/kernels/scatter_op_gpu.cu.cc:20:
In file included from ./tensorflow/core/kernels/scatter_functor_gpu.cu.h:23:
In file included from ./tensorflow/core/framework/tensor_types.h:20:
In file included from ./tensorflow/core/platform/logging.h:19:
In file included from ./tensorflow/core/platform/types.h:21:
In file included from ./tensorflow/core/platform/tstring.h:19:
In file included from ./tensorflow/core/platform/cord.h:19:
In file included from external/local_tsl/tsl/platform/cord.h:21:
In file included from external/com_google_absl/absl/strings/cord.h:74:
In file included from external/com_google_absl/absl/base/internal/endian.h:22:
In file included from external/com_google_absl/absl/base/casts.h:28:
In file included from /opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linux/12/../../../../include/c++/12/memory:77:
In file included from /opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linux/12/../../../../include/c++/12/bits/shared_ptr.h:53:
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linux/12/../../../../include/c++/12/bits/shared_ptr_base.h:196:22: error: use of undeclared identifier 'noinline'; did you mean 'inline'?
      __attribute__((__noinline__))
                     ^
bazel-out/k8-opt/bin/external/local_config_cuda/cuda/cuda/include/crt/host_defines.h:83:24: note: expanded from macro '__noinline__'
        __attribute__((noinline))
                       ^
In file included from tensorflow/core/kernels/scatter_op_gpu.cu.cc:20:
In file included from ./tensorflow/core/kernels/scatter_functor_gpu.cu.h:23:
In file included from ./tensorflow/core/framework/tensor_types.h:20:
In file included from ./tensorflow/core/platform/logging.h:19:
In file included from ./tensorflow/core/platform/types.h:21:
In file included from ./tensorflow/core/platform/tstring.h:19:
In file included from ./tensorflow/core/platform/cord.h:19:
In file included from external/local_tsl/tsl/platform/cord.h:21:
In file included from external/com_google_absl/absl/strings/cord.h:74:
In file included from external/com_google_absl/absl/base/internal/endian.h:22:
In file included from external/com_google_absl/absl/base/casts.h:28:
In file included from /opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linux/12/../../../../include/c++/12/memory:77:
In file included from /opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linux/12/../../../../include/c++/12/bits/shared_ptr.h:53:
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linux/12/../../../../include/c++/12/bits/shared_ptr_base.h:196:22: error: type name does not allow function specifier to be specified
bazel-out/k8-opt/bin/external/local_config_cuda/cuda/cuda/include/crt/host_defines.h:83:24: note: expanded from macro '__noinline__'
        __attribute__((noinline))
                       ^
In file included from tensorflow/core/kernels/scatter_op_gpu.cu.cc:20:
In file included from ./tensorflow/core/kernels/scatter_functor_gpu.cu.h:23:
In file included from ./tensorflow/core/framework/tensor_types.h:20:
In file included from ./tensorflow/core/platform/logging.h:19:
In file included from ./tensorflow/core/platform/types.h:21:
In file included from ./tensorflow/core/platform/tstring.h:19:
In file included from ./tensorflow/core/platform/cord.h:19:
In file included from external/local_tsl/tsl/platform/cord.h:21:
In file included from external/com_google_absl/absl/strings/cord.h:74:
In file included from external/com_google_absl/absl/base/internal/endian.h:22:
In file included from external/com_google_absl/absl/base/casts.h:28:
In file included from /opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linux/12/../../../../include/c++/12/memory:77:
In file included from /opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linux/12/../../../../include/c++/12/bits/shared_ptr.h:53:
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linux/12/../../../../include/c++/12/bits/shared_ptr_base.h:196:22: error: expected expression
bazel-out/k8-opt/bin/external/local_config_cuda/cuda/cuda/include/crt/host_defines.h:83:33: note: expanded from macro '__noinline__'
        __attribute__((noinline))
external/local_tsl/tsl/platform/default/logging.h:308:9: note: previous definition is here
#define CHECK(condition)              \
        ^
In file included from tensorflow/core/kernels/scatter_op_gpu.cu.cc:20:
In file included from ./tensorflow/core/kernels/scatter_functor_gpu.cu.h:26:
In file included from ./tensorflow/core/util/gpu_kernel_helper.h:28:
In file included from ./tensorflow/core/util/gpu_launch_config.h:27:
In file included from ./tensorflow/core/platform/stream_executor.h:19:
In file included from external/local_xla/xla/stream_executor/cuda/cuda_platform_id.h:19:
In file included from external/local_xla/xla/stream_executor/platform.h:27:
In file included from external/local_xla/xla/stream_executor/device_options.h:27:
external/com_google_absl/absl/log/check.h:65:9: warning: 'QCHECK' macro redefined [-Wmacro-redefined]
#define QCHECK(condition) ABSL_QCHECK_IMPL((condition), #condition)
        ^
external/local_tsl/tsl/platform/default/logging.h:542:9: note: previous definition is here
#define QCHECK(condition) CHECK(condition)
        ^
In file included from tensorflow/core/kernels/scatter_op_gpu.cu.cc:20:
In file included from ./tensorflow/core/kernels/scatter_functor_gpu.cu.h:26:
In file included from ./tensorflow/core/util/gpu_kernel_helper.h:28:
In file included from ./tensorflow/core/util/gpu_launch_config.h:27:
In file included from ./tensorflow/core/platform/stream_executor.h:19:
In file included from external/local_xla/xla/stream_executor/cuda/cuda_platform_id.h:19:
In file included from external/local_xla/xla/stream_executor/platform.h:27:
In file included from external/local_xla/xla/stream_executor/device_options.h:27:
external/com_google_absl/absl/log/check.h:88:9: warning: 'DCHECK' macro redefined [-Wmacro-redefined]
#define DCHECK(condition) ABSL_DCHECK_IMPL((condition), #condition)
        ^
external/local_tsl/tsl/platform/default/logging.h:521:9: note: previous definition is here
#define DCHECK(condition) \
        ^
### a few more similar warnings ###

21 warnings and 3 errors generated when compiling for sm_50.
Target //tensorflow/tools/pip_package:build_pip_package failed to build
[15,687 / 19,612] checking cached actions
INFO: Elapsed time: 3750.761s, Critical Path: 251.21s
INFO: 15687 processes: 6668 internal, 9019 local.
FAILED: Build did NOT complete successfully

### CASE 2 log:
### showing only the errors at the end ###

[24,431 / 26,425] Compiling tensorflow/compiler/mlir/tensorflow/ir/tf_ops.cc [for tool]; 94s local ... (8 actions, 7 running)
[24,435 / 26,425] Compiling tensorflow/compiler/mlir/tensorflow/ir/tf_ops.cc [for tool]; 95s local ... (8 actions, 7 running)
[24,440 / 26,425] Compiling tensorflow/compiler/mlir/tensorflow/ir/tf_ops.cc [for tool]; 96s local ... (8 actions, 7 running)
[24,446 / 26,425] Compiling tensorflow/compiler/mlir/tensorflow/ir/tf_ops.cc [for tool]; 97s local ... (8 actions, 7 running)
bazel-out/k8-opt-exec-50AE0418/bin/tensorflow/python/framework/offset_counter: /lib64/libstdc++.so.6: version 'CXXABI_1.3.13' not found (required by /root/.cache/bazel/_bazel_root/e76370378c3e9e8e238b869c10fc760e/execroot/org_tensorflow/bazel-out/k8-opt-exec-50AE0418/bin/tensorflow/python/framework/../../../_solib_local/_U_S_Stensorflow_Spython_Sframework_Coffset_Ucounter___Utensorflow/libtensorflow_framework.so.2)
bazel-out/k8-opt-exec-50AE0418/bin/tensorflow/python/framework/offset_counter: /lib64/libstdc++.so.6: version 'GLIBCXX_3.4.29' not found (required by /root/.cache/bazel/_bazel_root/e76370378c3e9e8e238b869c10fc760e/execroot/org_tensorflow/bazel-out/k8-opt-exec-50AE0418/bin/tensorflow/python/framework/../../../_solib_local/_U_S_Stensorflow_Spython_Sframework_Coffset_Ucounter___Utensorflow/libtensorflow_framework.so.2)
bazel-out/k8-opt-exec-50AE0418/bin/tensorflow/python/framework/offset_counter: /lib64/libstdc++.so.6: version 'GLIBCXX_3.4.26' not found (required by /root/.cache/bazel/_bazel_root/e76370378c3e9e8e238b869c10fc760e/execroot/org_tensorflow/bazel-out/k8-opt-exec-50AE0418/bin/tensorflow/python/framework/../../../_solib_local/_U_S_Stensorflow_Spython_Sframework_Coffset_Ucounter___Utensorflow/libtensorflow_framework.so.2)
```
