### Issue type

Bug

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

Yes

### Source

source

### TensorFlow version

tf2.17

### Custom code

Yes

### OS platform and distribution

_No response_

### Mobile device

_No response_

### Python version

_No response_

### Bazel version

_No response_

### GCC/compiler version

_No response_

### CUDA/cuDNN version

_No response_

### GPU model and memory

_No response_

### Current behavior?

Version
TensorFlow Version: 2.x (with oneDNN optimization)
CUDA Environment: GPU-enabled system
Total GPU Memory: 11.5 GB (11539054592 bytes)
Python Version: 3.x
Current Behavior
Error Description
The application crashes during CUDA device context initialization when performing inverse FFT operations with extreme axis parameter values (36028797018963968). The failure occurs before the actual FFT computation, during GPU context acquisition phase.
Error Log
2025-11-21 10:59:22.617965: F tensorflow/core/platform/statusor.cc:33] Attempting to fetch value instead of handling error INTERNAL: failed initializing StreamExecutor for CUDA device ordinal 0: INTERNAL: failed call to cuDevicePrimaryCtxRetain: CUDA_ERROR_OUT_OF_MEMORY: out of memory; total memory reported: 11539054592
Aborted (core dumped)

### Standalone code to reproduce the issue

```shell
import tensorflow as tf
input_data = tf.constant([[1 + 2.0j, 3 + 4.0j], [5 + 6.0j, 7 + 8.0j]],
    dtype=tf.complex64)
fft_length = tf.constant([2, 2], dtype=tf.int32)
axes = tf.constant([36028797018963968, 36028797018963968], dtype=tf.int32)
result = tf.signal.ifft2d(input_data, name='ifftnd_op')
```

### Relevant log output

```shell

```