reference, declarationdefinition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced

References

tools/clang/include/clang/Basic/OpenCLExtensions.def
   36 OPENCLEXT_INTERNAL(cl_khr_3d_image_writes, 100, 200)
   38 OPENCLEXT_INTERNAL(cl_khr_select_fprounding_mode, 100, 110)
   39 OPENCLEXT_INTERNAL(cl_khr_byte_addressable_store, 100, 110)
   40 OPENCLEXT_INTERNAL(cl_khr_fp16, 100, ~0U)
   41 OPENCLEXT_INTERNAL(cl_khr_fp64, 100, 120)
   42 OPENCLEXT_INTERNAL(cl_khr_global_int32_base_atomics, 100, 110)
   43 OPENCLEXT_INTERNAL(cl_khr_global_int32_extended_atomics, 100, 110)
   44 OPENCLEXT_INTERNAL(cl_khr_local_int32_base_atomics, 100, 110)
   45 OPENCLEXT_INTERNAL(cl_khr_local_int32_extended_atomics, 100, 110)
   46 OPENCLEXT_INTERNAL(cl_khr_int64_base_atomics, 100, ~0U)
   47 OPENCLEXT_INTERNAL(cl_khr_int64_extended_atomics, 100, ~0U)
   48 OPENCLEXT_INTERNAL(cl_khr_gl_sharing, 100, ~0U)
   49 OPENCLEXT_INTERNAL(cl_khr_icd, 100, ~0U)
   52 OPENCLEXT_INTERNAL(cl_khr_gl_event, 110, ~0U)
   53 OPENCLEXT_INTERNAL(cl_khr_d3d10_sharing, 110, ~0U)
   56 OPENCLEXT_INTERNAL(cles_khr_int64, 110, ~0U)
   59 OPENCLEXT_INTERNAL(cl_khr_context_abort, 120, ~0U)
   60 OPENCLEXT_INTERNAL(cl_khr_d3d11_sharing, 120, ~0U)
   61 OPENCLEXT_INTERNAL(cl_khr_depth_images, 120, ~0U)
   62 OPENCLEXT_INTERNAL(cl_khr_dx9_media_sharing, 120, ~0U)
   63 OPENCLEXT_INTERNAL(cl_khr_image2d_from_buffer, 120, ~0U)
   64 OPENCLEXT_INTERNAL(cl_khr_initialize_memory, 120, ~0U)
   65 OPENCLEXT_INTERNAL(cl_khr_gl_depth_images, 120, ~0U)
   66 OPENCLEXT_INTERNAL(cl_khr_gl_msaa_sharing, 120, ~0U)
   67 OPENCLEXT_INTERNAL(cl_khr_spir, 120, ~0U)
   70 OPENCLEXT_INTERNAL(cl_khr_egl_event, 200, ~0U)
   71 OPENCLEXT_INTERNAL(cl_khr_egl_image, 200, ~0U)
   72 OPENCLEXT_INTERNAL(cl_khr_mipmap_image, 200, ~0U)
   73 OPENCLEXT_INTERNAL(cl_khr_srgb_image_writes, 200, ~0U)
   74 OPENCLEXT_INTERNAL(cl_khr_subgroups, 200, ~0U)
   75 OPENCLEXT_INTERNAL(cl_khr_terminate_context, 200, ~0U)
   78 OPENCLEXT_INTERNAL(cl_clang_storage_class_specifiers, 100, ~0U)
   81 OPENCLEXT_INTERNAL(cl_amd_media_ops, 100, ~0U)
   82 OPENCLEXT_INTERNAL(cl_amd_media_ops2, 100, ~0U)
   85 OPENCLEXT_INTERNAL(cl_arm_integer_dot_product_int8, 120, ~0U)
   86 OPENCLEXT_INTERNAL(cl_arm_integer_dot_product_accumulate_int8, 120, ~0U)
   87 OPENCLEXT_INTERNAL(cl_arm_integer_dot_product_accumulate_int16, 120, ~0U)
   88 OPENCLEXT_INTERNAL(cl_arm_integer_dot_product_accumulate_saturate_int8, 120, ~0U)
   91 OPENCLEXT_INTERNAL(cl_intel_subgroups, 120, ~0U)
   92 OPENCLEXT_INTERNAL(cl_intel_subgroups_short, 120, ~0U)
   93 OPENCLEXT_INTERNAL(cl_intel_device_side_avc_motion_estimation, 120, ~0U)
tools/clang/lib/Frontend/InitPreprocessor.cpp
  690                       Twine(TI.useSignedCharForObjCBool() ? "0" : "1"));
  721           (TI.getTriple().isThumb() || TI.getTriple().isARM()))
  721           (TI.getTriple().isThumb() || TI.getTriple().isARM()))
  756   if (TI.isBigEndian()) {
  764   if (TI.getPointerWidth(0) == 64 && TI.getLongWidth() == 64
  764   if (TI.getPointerWidth(0) == 64 && TI.getLongWidth() == 64
  765       && TI.getIntWidth() == 32) {
  770   if (TI.getPointerWidth(0) == 32 && TI.getLongWidth() == 32
  770   if (TI.getPointerWidth(0) == 32 && TI.getLongWidth() == 32
  771       && TI.getIntWidth() == 32) {
  777   assert(TI.getCharWidth() == 8 && "Only support 8-bit char so far");
  778   Builder.defineMacro("__CHAR_BIT__", Twine(TI.getCharWidth()));
  780   DefineTypeSize("__SCHAR_MAX__", TargetInfo::SignedChar, TI, Builder);
  781   DefineTypeSize("__SHRT_MAX__", TargetInfo::SignedShort, TI, Builder);
  782   DefineTypeSize("__INT_MAX__", TargetInfo::SignedInt, TI, Builder);
  783   DefineTypeSize("__LONG_MAX__", TargetInfo::SignedLong, TI, Builder);
  784   DefineTypeSize("__LONG_LONG_MAX__", TargetInfo::SignedLongLong, TI, Builder);
  785   DefineTypeSize("__WCHAR_MAX__", TI.getWCharType(), TI, Builder);
  785   DefineTypeSize("__WCHAR_MAX__", TI.getWCharType(), TI, Builder);
  786   DefineTypeSize("__WINT_MAX__", TI.getWIntType(), TI, Builder);
  786   DefineTypeSize("__WINT_MAX__", TI.getWIntType(), TI, Builder);
  787   DefineTypeSize("__INTMAX_MAX__", TI.getIntMaxType(), TI, Builder);
  787   DefineTypeSize("__INTMAX_MAX__", TI.getIntMaxType(), TI, Builder);
  788   DefineTypeSize("__SIZE_MAX__", TI.getSizeType(), TI, Builder);
  788   DefineTypeSize("__SIZE_MAX__", TI.getSizeType(), TI, Builder);
  790   DefineTypeSize("__UINTMAX_MAX__", TI.getUIntMaxType(), TI, Builder);
  790   DefineTypeSize("__UINTMAX_MAX__", TI.getUIntMaxType(), TI, Builder);
  791   DefineTypeSize("__PTRDIFF_MAX__", TI.getPtrDiffType(0), TI, Builder);
  791   DefineTypeSize("__PTRDIFF_MAX__", TI.getPtrDiffType(0), TI, Builder);
  792   DefineTypeSize("__INTPTR_MAX__", TI.getIntPtrType(), TI, Builder);
  792   DefineTypeSize("__INTPTR_MAX__", TI.getIntPtrType(), TI, Builder);
  793   DefineTypeSize("__UINTPTR_MAX__", TI.getUIntPtrType(), TI, Builder);
  793   DefineTypeSize("__UINTPTR_MAX__", TI.getUIntPtrType(), TI, Builder);
  795   DefineTypeSizeof("__SIZEOF_DOUBLE__", TI.getDoubleWidth(), TI, Builder);
  795   DefineTypeSizeof("__SIZEOF_DOUBLE__", TI.getDoubleWidth(), TI, Builder);
  796   DefineTypeSizeof("__SIZEOF_FLOAT__", TI.getFloatWidth(), TI, Builder);
  796   DefineTypeSizeof("__SIZEOF_FLOAT__", TI.getFloatWidth(), TI, Builder);
  797   DefineTypeSizeof("__SIZEOF_INT__", TI.getIntWidth(), TI, Builder);
  797   DefineTypeSizeof("__SIZEOF_INT__", TI.getIntWidth(), TI, Builder);
  798   DefineTypeSizeof("__SIZEOF_LONG__", TI.getLongWidth(), TI, Builder);
  798   DefineTypeSizeof("__SIZEOF_LONG__", TI.getLongWidth(), TI, Builder);
  799   DefineTypeSizeof("__SIZEOF_LONG_DOUBLE__",TI.getLongDoubleWidth(),TI,Builder);
  799   DefineTypeSizeof("__SIZEOF_LONG_DOUBLE__",TI.getLongDoubleWidth(),TI,Builder);
  800   DefineTypeSizeof("__SIZEOF_LONG_LONG__", TI.getLongLongWidth(), TI, Builder);
  800   DefineTypeSizeof("__SIZEOF_LONG_LONG__", TI.getLongLongWidth(), TI, Builder);
  801   DefineTypeSizeof("__SIZEOF_POINTER__", TI.getPointerWidth(0), TI, Builder);
  801   DefineTypeSizeof("__SIZEOF_POINTER__", TI.getPointerWidth(0), TI, Builder);
  802   DefineTypeSizeof("__SIZEOF_SHORT__", TI.getShortWidth(), TI, Builder);
  802   DefineTypeSizeof("__SIZEOF_SHORT__", TI.getShortWidth(), TI, Builder);
  804                    TI.getTypeWidth(TI.getPtrDiffType(0)), TI, Builder);
  804                    TI.getTypeWidth(TI.getPtrDiffType(0)), TI, Builder);
  804                    TI.getTypeWidth(TI.getPtrDiffType(0)), TI, Builder);
  806                    TI.getTypeWidth(TI.getSizeType()), TI, Builder);
  806                    TI.getTypeWidth(TI.getSizeType()), TI, Builder);
  806                    TI.getTypeWidth(TI.getSizeType()), TI, Builder);
  808                    TI.getTypeWidth(TI.getWCharType()), TI, Builder);
  808                    TI.getTypeWidth(TI.getWCharType()), TI, Builder);
  808                    TI.getTypeWidth(TI.getWCharType()), TI, Builder);
  810                    TI.getTypeWidth(TI.getWIntType()), TI, Builder);
  810                    TI.getTypeWidth(TI.getWIntType()), TI, Builder);
  810                    TI.getTypeWidth(TI.getWIntType()), TI, Builder);
  811   if (TI.hasInt128Type())
  812     DefineTypeSizeof("__SIZEOF_INT128__", 128, TI, Builder);
  814   DefineType("__INTMAX_TYPE__", TI.getIntMaxType(), Builder);
  815   DefineFmt("__INTMAX", TI.getIntMaxType(), TI, Builder);
  815   DefineFmt("__INTMAX", TI.getIntMaxType(), TI, Builder);
  817                       TI.getTypeConstantSuffix(TI.getIntMaxType()));
  817                       TI.getTypeConstantSuffix(TI.getIntMaxType()));
  818   DefineType("__UINTMAX_TYPE__", TI.getUIntMaxType(), Builder);
  819   DefineFmt("__UINTMAX", TI.getUIntMaxType(), TI, Builder);
  819   DefineFmt("__UINTMAX", TI.getUIntMaxType(), TI, Builder);
  821                       TI.getTypeConstantSuffix(TI.getUIntMaxType()));
  821                       TI.getTypeConstantSuffix(TI.getUIntMaxType()));
  822   DefineTypeWidth("__INTMAX_WIDTH__",  TI.getIntMaxType(), TI, Builder);
  822   DefineTypeWidth("__INTMAX_WIDTH__",  TI.getIntMaxType(), TI, Builder);
  823   DefineType("__PTRDIFF_TYPE__", TI.getPtrDiffType(0), Builder);
  824   DefineFmt("__PTRDIFF", TI.getPtrDiffType(0), TI, Builder);
  824   DefineFmt("__PTRDIFF", TI.getPtrDiffType(0), TI, Builder);
  825   DefineTypeWidth("__PTRDIFF_WIDTH__", TI.getPtrDiffType(0), TI, Builder);
  825   DefineTypeWidth("__PTRDIFF_WIDTH__", TI.getPtrDiffType(0), TI, Builder);
  826   DefineType("__INTPTR_TYPE__", TI.getIntPtrType(), Builder);
  827   DefineFmt("__INTPTR", TI.getIntPtrType(), TI, Builder);
  827   DefineFmt("__INTPTR", TI.getIntPtrType(), TI, Builder);
  828   DefineTypeWidth("__INTPTR_WIDTH__", TI.getIntPtrType(), TI, Builder);
  828   DefineTypeWidth("__INTPTR_WIDTH__", TI.getIntPtrType(), TI, Builder);
  829   DefineType("__SIZE_TYPE__", TI.getSizeType(), Builder);
  830   DefineFmt("__SIZE", TI.getSizeType(), TI, Builder);
  830   DefineFmt("__SIZE", TI.getSizeType(), TI, Builder);
  831   DefineTypeWidth("__SIZE_WIDTH__", TI.getSizeType(), TI, Builder);
  831   DefineTypeWidth("__SIZE_WIDTH__", TI.getSizeType(), TI, Builder);
  832   DefineType("__WCHAR_TYPE__", TI.getWCharType(), Builder);
  833   DefineTypeWidth("__WCHAR_WIDTH__", TI.getWCharType(), TI, Builder);
  833   DefineTypeWidth("__WCHAR_WIDTH__", TI.getWCharType(), TI, Builder);
  834   DefineType("__WINT_TYPE__", TI.getWIntType(), Builder);
  835   DefineTypeWidth("__WINT_WIDTH__", TI.getWIntType(), TI, Builder);
  835   DefineTypeWidth("__WINT_WIDTH__", TI.getWIntType(), TI, Builder);
  836   DefineTypeWidth("__SIG_ATOMIC_WIDTH__", TI.getSigAtomicType(), TI, Builder);
  836   DefineTypeWidth("__SIG_ATOMIC_WIDTH__", TI.getSigAtomicType(), TI, Builder);
  837   DefineTypeSize("__SIG_ATOMIC_MAX__", TI.getSigAtomicType(), TI, Builder);
  837   DefineTypeSize("__SIG_ATOMIC_MAX__", TI.getSigAtomicType(), TI, Builder);
  838   DefineType("__CHAR16_TYPE__", TI.getChar16Type(), Builder);
  839   DefineType("__CHAR32_TYPE__", TI.getChar32Type(), Builder);
  841   DefineTypeWidth("__UINTMAX_WIDTH__",  TI.getUIntMaxType(), TI, Builder);
  841   DefineTypeWidth("__UINTMAX_WIDTH__",  TI.getUIntMaxType(), TI, Builder);
  842   DefineType("__UINTPTR_TYPE__", TI.getUIntPtrType(), Builder);
  843   DefineFmt("__UINTPTR", TI.getUIntPtrType(), TI, Builder);
  843   DefineFmt("__UINTPTR", TI.getUIntPtrType(), TI, Builder);
  844   DefineTypeWidth("__UINTPTR_WIDTH__", TI.getUIntPtrType(), TI, Builder);
  844   DefineTypeWidth("__UINTPTR_WIDTH__", TI.getUIntPtrType(), TI, Builder);
  846   if (TI.hasFloat16Type())
  847     DefineFloatMacros(Builder, "FLT16", &TI.getHalfFormat(), "F16");
  848   DefineFloatMacros(Builder, "FLT", &TI.getFloatFormat(), "F");
  849   DefineFloatMacros(Builder, "DBL", &TI.getDoubleFormat(), "");
  850   DefineFloatMacros(Builder, "LDBL", &TI.getLongDoubleFormat(), "L");
  854                       Twine((int)TI.getPointerWidth(0)));
  858                       Twine(TI.getSuitableAlign() / TI.getCharWidth()) );
  858                       Twine(TI.getSuitableAlign() / TI.getCharWidth()) );
  863   if (!TargetInfo::isTypeSigned(TI.getWCharType()))
  866   if (!TargetInfo::isTypeSigned(TI.getWIntType()))
  870   DefineExactWidthIntType(TargetInfo::SignedChar, TI, Builder);
  872   if (TI.getShortWidth() > TI.getCharWidth())
  872   if (TI.getShortWidth() > TI.getCharWidth())
  873     DefineExactWidthIntType(TargetInfo::SignedShort, TI, Builder);
  875   if (TI.getIntWidth() > TI.getShortWidth())
  875   if (TI.getIntWidth() > TI.getShortWidth())
  876     DefineExactWidthIntType(TargetInfo::SignedInt, TI, Builder);
  878   if (TI.getLongWidth() > TI.getIntWidth())
  878   if (TI.getLongWidth() > TI.getIntWidth())
  879     DefineExactWidthIntType(TargetInfo::SignedLong, TI, Builder);
  881   if (TI.getLongLongWidth() > TI.getLongWidth())
  881   if (TI.getLongLongWidth() > TI.getLongWidth())
  882     DefineExactWidthIntType(TargetInfo::SignedLongLong, TI, Builder);
  884   DefineExactWidthIntType(TargetInfo::UnsignedChar, TI, Builder);
  885   DefineExactWidthIntTypeSize(TargetInfo::UnsignedChar, TI, Builder);
  886   DefineExactWidthIntTypeSize(TargetInfo::SignedChar, TI, Builder);
  888   if (TI.getShortWidth() > TI.getCharWidth()) {
  888   if (TI.getShortWidth() > TI.getCharWidth()) {
  889     DefineExactWidthIntType(TargetInfo::UnsignedShort, TI, Builder);
  890     DefineExactWidthIntTypeSize(TargetInfo::UnsignedShort, TI, Builder);
  891     DefineExactWidthIntTypeSize(TargetInfo::SignedShort, TI, Builder);
  894   if (TI.getIntWidth() > TI.getShortWidth()) {
  894   if (TI.getIntWidth() > TI.getShortWidth()) {
  895     DefineExactWidthIntType(TargetInfo::UnsignedInt, TI, Builder);
  896     DefineExactWidthIntTypeSize(TargetInfo::UnsignedInt, TI, Builder);
  897     DefineExactWidthIntTypeSize(TargetInfo::SignedInt, TI, Builder);
  900   if (TI.getLongWidth() > TI.getIntWidth()) {
  900   if (TI.getLongWidth() > TI.getIntWidth()) {
  901     DefineExactWidthIntType(TargetInfo::UnsignedLong, TI, Builder);
  902     DefineExactWidthIntTypeSize(TargetInfo::UnsignedLong, TI, Builder);
  903     DefineExactWidthIntTypeSize(TargetInfo::SignedLong, TI, Builder);
  906   if (TI.getLongLongWidth() > TI.getLongWidth()) {
  906   if (TI.getLongLongWidth() > TI.getLongWidth()) {
  907     DefineExactWidthIntType(TargetInfo::UnsignedLongLong, TI, Builder);
  908     DefineExactWidthIntTypeSize(TargetInfo::UnsignedLongLong, TI, Builder);
  909     DefineExactWidthIntTypeSize(TargetInfo::SignedLongLong, TI, Builder);
  912   DefineLeastWidthIntType(8, true, TI, Builder);
  913   DefineLeastWidthIntType(8, false, TI, Builder);
  914   DefineLeastWidthIntType(16, true, TI, Builder);
  915   DefineLeastWidthIntType(16, false, TI, Builder);
  916   DefineLeastWidthIntType(32, true, TI, Builder);
  917   DefineLeastWidthIntType(32, false, TI, Builder);
  918   DefineLeastWidthIntType(64, true, TI, Builder);
  919   DefineLeastWidthIntType(64, false, TI, Builder);
  921   DefineFastIntType(8, true, TI, Builder);
  922   DefineFastIntType(8, false, TI, Builder);
  923   DefineFastIntType(16, true, TI, Builder);
  924   DefineFastIntType(16, false, TI, Builder);
  925   DefineFastIntType(32, true, TI, Builder);
  926   DefineFastIntType(32, false, TI, Builder);
  927   DefineFastIntType(64, true, TI, Builder);
  928   DefineFastIntType(64, false, TI, Builder);
  930   char UserLabelPrefix[2] = {TI.getDataLayout().getGlobalPrefix(), 0};
  951     unsigned InlineWidthBits = TI.getMaxAtomicInlineWidth();
  957     DEFINE_LOCK_FREE_MACRO(BOOL, Bool);
  958     DEFINE_LOCK_FREE_MACRO(CHAR, Char);
  960       DEFINE_LOCK_FREE_MACRO(CHAR8_T, Char); // Treat char8_t like char.
  961     DEFINE_LOCK_FREE_MACRO(CHAR16_T, Char16);
  962     DEFINE_LOCK_FREE_MACRO(CHAR32_T, Char32);
  963     DEFINE_LOCK_FREE_MACRO(WCHAR_T, WChar);
  964     DEFINE_LOCK_FREE_MACRO(SHORT, Short);
  965     DEFINE_LOCK_FREE_MACRO(INT, Int);
  966     DEFINE_LOCK_FREE_MACRO(LONG, Long);
  967     DEFINE_LOCK_FREE_MACRO(LLONG, LongLong);
  969                         getLockFreeValue(TI.getPointerWidth(0),
  970                                          TI.getPointerAlign(0),
  991   Builder.defineMacro("__FLT_EVAL_METHOD__", Twine(TI.getFloatEvalMethod()));
 1025   if (TI.getTriple().isOSDarwin()) {
 1033   if (TI.getTriple().isOSDarwin() && TI.getTriple().isSimulatorEnvironment())
 1033   if (TI.getTriple().isOSDarwin() && TI.getTriple().isSimulatorEnvironment())
 1088     if (TI.getTriple().isSPIR())
 1092   if (TI.hasInt128Type() && LangOpts.CPlusPlus && LangOpts.GNUMode) {
 1101   TI.getTargetDefines(LangOpts, Builder);