Home | History | Annotate | Download | only in Preprocessor
      1 // RUN: %clang_cc1 -Eonly %s -DOPT_O2 -O2 -verify
      2 #ifdef OPT_O2
      3   #ifndef __OPTIMIZE__
      4     #error "__OPTIMIZE__ not defined"
      5   #endif
      6   #ifdef __OPTIMIZE_SIZE__
      7     #error "__OPTIMIZE_SIZE__ defined"
      8   #endif
      9 #endif
     10 
     11 // RUN: %clang_cc1 -Eonly %s -DOPT_O0 -O0 -verify
     12 #ifdef OPT_O0
     13   #ifdef __OPTIMIZE__
     14     #error "__OPTIMIZE__ defined"
     15   #endif
     16   #ifdef __OPTIMIZE_SIZE__
     17     #error "__OPTIMIZE_SIZE__ defined"
     18   #endif
     19 #endif
     20 
     21 // RUN: %clang_cc1 -Eonly %s -DOPT_OS -Os -verify
     22 #ifdef OPT_OS
     23   #ifndef __OPTIMIZE__
     24     #error "__OPTIMIZE__ not defined"
     25   #endif
     26   #ifdef __OPTIMIZE_SIZE__
     27     #error "__OPTIMIZE_SIZE__ not defined"
     28   #endif
     29 #endif
     30