[PATCH] D63029: [NFC][CUDA] Avoid undefined grep in cuda-types.cu

Artem Belevich via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Jun 7 15:11:52 PDT 2019


tra added inline comments.


================
Comment at: test/Preprocessor/cuda-types.cu:11
 // RUN: %clang --cuda-host-only -nocudainc -target i386-unknown-linux-gnu -x cuda -E -dM -o - /dev/null \
-// RUN:   | grep 'define __[^ ]*\(TYPE\|MAX\|SIZEOF|WIDTH\)\|define __GCC_ATOMIC' \
-// RUN:   | grep -v '__LDBL\|_LONG_DOUBLE' > %t/i386-host-defines-filtered
+// RUN:   | grep -E 'define __[^ ]*(TYPE|MAX|SIZEOF\|WIDTH)|define __GCC_ATOMIC' \
+// RUN:   | grep -Ev '__LDBL|_LONG_DOUBLE' > %t/i386-host-defines-filtered
----------------
I believe that was a typo in the original test. It should be `TYPE|MAX|SIZEOF|WIDTH` now.
`SIZEOF` and `WIDTH` are parts of different defines we're looking for.

E.g
```
#define __SIZEOF_DOUBLE__ 8
...
#define __INTPTR_WIDTH__ 32

```


Repository:
  rC Clang

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

https://reviews.llvm.org/D63029





More information about the cfe-commits mailing list