2# error "A C++ compiler has been selected for C."
8#if defined(__CLASSIC_C__)
14#if !defined(__has_include)
17# define __has_include(x) 0
24#if defined(__INTEL_COMPILER) || defined(__ICC)
25# define COMPILER_ID "Intel"
27# define SIMULATE_ID "MSVC"
30# define SIMULATE_ID "GNU"
34# if __INTEL_COMPILER < 2021 || __INTEL_COMPILER == 202110 || __INTEL_COMPILER == 202111
35# define COMPILER_VERSION_MAJOR DEC(__INTEL_COMPILER/100)
36# define COMPILER_VERSION_MINOR DEC(__INTEL_COMPILER/10 % 10)
37# if defined(__INTEL_COMPILER_UPDATE)
38# define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER_UPDATE)
40# define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER % 10)
43# define COMPILER_VERSION_MAJOR DEC(__INTEL_COMPILER)
44# define COMPILER_VERSION_MINOR DEC(__INTEL_COMPILER_UPDATE)
47# define COMPILER_VERSION_PATCH DEC(0)
49# if defined(__INTEL_COMPILER_BUILD_DATE)
51# define COMPILER_VERSION_TWEAK DEC(__INTEL_COMPILER_BUILD_DATE)
55# define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
56# define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
59# define SIMULATE_VERSION_MAJOR DEC(__GNUC__)
60# elif defined(__GNUG__)
61# define SIMULATE_VERSION_MAJOR DEC(__GNUG__)
63# if defined(__GNUC_MINOR__)
64# define SIMULATE_VERSION_MINOR DEC(__GNUC_MINOR__)
66# if defined(__GNUC_PATCHLEVEL__)
67# define SIMULATE_VERSION_PATCH DEC(__GNUC_PATCHLEVEL__)
70#elif (defined(__clang__) && defined(__INTEL_CLANG_COMPILER)) || defined(__INTEL_LLVM_COMPILER)
71# define COMPILER_ID "IntelLLVM"
73# define SIMULATE_ID "MSVC"
76# define SIMULATE_ID "GNU"
82#if __INTEL_LLVM_COMPILER < 1000000L
83# define COMPILER_VERSION_MAJOR DEC(__INTEL_LLVM_COMPILER/100)
84# define COMPILER_VERSION_MINOR DEC(__INTEL_LLVM_COMPILER/10 % 10)
85# define COMPILER_VERSION_PATCH DEC(__INTEL_LLVM_COMPILER % 10)
87# define COMPILER_VERSION_MAJOR DEC(__INTEL_LLVM_COMPILER/10000)
88# define COMPILER_VERSION_MINOR DEC(__INTEL_LLVM_COMPILER/100 % 100)
89# define COMPILER_VERSION_PATCH DEC(__INTEL_LLVM_COMPILER % 100)
93# define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
94# define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
97# define SIMULATE_VERSION_MAJOR DEC(__GNUC__)
98#elif defined(__GNUG__)
99# define SIMULATE_VERSION_MAJOR DEC(__GNUG__)
101#if defined(__GNUC_MINOR__)
102# define SIMULATE_VERSION_MINOR DEC(__GNUC_MINOR__)
104#if defined(__GNUC_PATCHLEVEL__)
105# define SIMULATE_VERSION_PATCH DEC(__GNUC_PATCHLEVEL__)
108#elif defined(__PATHCC__)
109# define COMPILER_ID "PathScale"
110# define COMPILER_VERSION_MAJOR DEC(__PATHCC__)
111# define COMPILER_VERSION_MINOR DEC(__PATHCC_MINOR__)
112# if defined(__PATHCC_PATCHLEVEL__)
113# define COMPILER_VERSION_PATCH DEC(__PATHCC_PATCHLEVEL__)
116#elif defined(__BORLANDC__) && defined(__CODEGEARC_VERSION__)
117# define COMPILER_ID "Embarcadero"
118# define COMPILER_VERSION_MAJOR HEX(__CODEGEARC_VERSION__>>24 & 0x00FF)
119# define COMPILER_VERSION_MINOR HEX(__CODEGEARC_VERSION__>>16 & 0x00FF)
120# define COMPILER_VERSION_PATCH DEC(__CODEGEARC_VERSION__ & 0xFFFF)
122#elif defined(__BORLANDC__)
123# define COMPILER_ID "Borland"
125# define COMPILER_VERSION_MAJOR HEX(__BORLANDC__>>8)
126# define COMPILER_VERSION_MINOR HEX(__BORLANDC__ & 0xFF)
128#elif defined(__WATCOMC__) && __WATCOMC__ < 1200
129# define COMPILER_ID "Watcom"
131# define COMPILER_VERSION_MAJOR DEC(__WATCOMC__ / 100)
132# define COMPILER_VERSION_MINOR DEC((__WATCOMC__ / 10) % 10)
133# if (__WATCOMC__ % 10) > 0
134# define COMPILER_VERSION_PATCH DEC(__WATCOMC__ % 10)
137#elif defined(__WATCOMC__)
138# define COMPILER_ID "OpenWatcom"
140# define COMPILER_VERSION_MAJOR DEC((__WATCOMC__ - 1100) / 100)
141# define COMPILER_VERSION_MINOR DEC((__WATCOMC__ / 10) % 10)
142# if (__WATCOMC__ % 10) > 0
143# define COMPILER_VERSION_PATCH DEC(__WATCOMC__ % 10)
146#elif defined(__SUNPRO_C)
147# define COMPILER_ID "SunPro"
148# if __SUNPRO_C >= 0x5100
150# define COMPILER_VERSION_MAJOR HEX(__SUNPRO_C>>12)
151# define COMPILER_VERSION_MINOR HEX(__SUNPRO_C>>4 & 0xFF)
152# define COMPILER_VERSION_PATCH HEX(__SUNPRO_C & 0xF)
155# define COMPILER_VERSION_MAJOR HEX(__SUNPRO_C>>8)
156# define COMPILER_VERSION_MINOR HEX(__SUNPRO_C>>4 & 0xF)
157# define COMPILER_VERSION_PATCH HEX(__SUNPRO_C & 0xF)
160#elif defined(__HP_cc)
161# define COMPILER_ID "HP"
163# define COMPILER_VERSION_MAJOR DEC(__HP_cc/10000)
164# define COMPILER_VERSION_MINOR DEC(__HP_cc/100 % 100)
165# define COMPILER_VERSION_PATCH DEC(__HP_cc % 100)
168# define COMPILER_ID "Compaq"
170# define COMPILER_VERSION_MAJOR DEC(__DECC_VER/10000000)
171# define COMPILER_VERSION_MINOR DEC(__DECC_VER/100000 % 100)
172# define COMPILER_VERSION_PATCH DEC(__DECC_VER % 10000)
174#elif defined(__IBMC__) && defined(__COMPILER_VER__)
175# define COMPILER_ID "zOS"
177# define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
178# define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
179# define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
181#elif defined(__open_xl__) && defined(__clang__)
182# define COMPILER_ID "IBMClang"
183# define COMPILER_VERSION_MAJOR DEC(__open_xl_version__)
184# define COMPILER_VERSION_MINOR DEC(__open_xl_release__)
185# define COMPILER_VERSION_PATCH DEC(__open_xl_modification__)
186# define COMPILER_VERSION_TWEAK DEC(__open_xl_ptf_fix_level__)
189#elif defined(__ibmxl__) && defined(__clang__)
190# define COMPILER_ID "XLClang"
191# define COMPILER_VERSION_MAJOR DEC(__ibmxl_version__)
192# define COMPILER_VERSION_MINOR DEC(__ibmxl_release__)
193# define COMPILER_VERSION_PATCH DEC(__ibmxl_modification__)
194# define COMPILER_VERSION_TWEAK DEC(__ibmxl_ptf_fix_level__)
197#elif defined(__IBMC__) && !defined(__COMPILER_VER__) && __IBMC__ >= 800
198# define COMPILER_ID "XL"
200# define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
201# define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
202# define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
204#elif defined(__IBMC__) && !defined(__COMPILER_VER__) && __IBMC__ < 800
205# define COMPILER_ID "VisualAge"
207# define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
208# define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
209# define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
211#elif defined(__NVCOMPILER)
212# define COMPILER_ID "NVHPC"
213# define COMPILER_VERSION_MAJOR DEC(__NVCOMPILER_MAJOR__)
214# define COMPILER_VERSION_MINOR DEC(__NVCOMPILER_MINOR__)
215# if defined(__NVCOMPILER_PATCHLEVEL__)
216# define COMPILER_VERSION_PATCH DEC(__NVCOMPILER_PATCHLEVEL__)
220# define COMPILER_ID "PGI"
221# define COMPILER_VERSION_MAJOR DEC(__PGIC__)
222# define COMPILER_VERSION_MINOR DEC(__PGIC_MINOR__)
223# if defined(__PGIC_PATCHLEVEL__)
224# define COMPILER_VERSION_PATCH DEC(__PGIC_PATCHLEVEL__)
227#elif defined(__clang__) && defined(__cray__)
228# define COMPILER_ID "CrayClang"
229# define COMPILER_VERSION_MAJOR DEC(__cray_major__)
230# define COMPILER_VERSION_MINOR DEC(__cray_minor__)
231# define COMPILER_VERSION_PATCH DEC(__cray_patchlevel__)
232# define COMPILER_VERSION_INTERNAL_STR __clang_version__
236# define COMPILER_ID "Cray"
237# define COMPILER_VERSION_MAJOR DEC(_RELEASE_MAJOR)
238# define COMPILER_VERSION_MINOR DEC(_RELEASE_MINOR)
240#elif defined(__TI_COMPILER_VERSION__)
241# define COMPILER_ID "TI"
243# define COMPILER_VERSION_MAJOR DEC(__TI_COMPILER_VERSION__/1000000)
244# define COMPILER_VERSION_MINOR DEC(__TI_COMPILER_VERSION__/1000 % 1000)
245# define COMPILER_VERSION_PATCH DEC(__TI_COMPILER_VERSION__ % 1000)
247#elif defined(__CLANG_FUJITSU)
248# define COMPILER_ID "FujitsuClang"
249# define COMPILER_VERSION_MAJOR DEC(__FCC_major__)
250# define COMPILER_VERSION_MINOR DEC(__FCC_minor__)
251# define COMPILER_VERSION_PATCH DEC(__FCC_patchlevel__)
252# define COMPILER_VERSION_INTERNAL_STR __clang_version__
255#elif defined(__FUJITSU)
256# define COMPILER_ID "Fujitsu"
257# if defined(__FCC_version__)
258# define COMPILER_VERSION __FCC_version__
259# elif defined(__FCC_major__)
260# define COMPILER_VERSION_MAJOR DEC(__FCC_major__)
261# define COMPILER_VERSION_MINOR DEC(__FCC_minor__)
262# define COMPILER_VERSION_PATCH DEC(__FCC_patchlevel__)
264# if defined(__fcc_version)
265# define COMPILER_VERSION_INTERNAL DEC(__fcc_version)
266# elif defined(__FCC_VERSION)
267# define COMPILER_VERSION_INTERNAL DEC(__FCC_VERSION)
271#elif defined(__ghs__)
272# define COMPILER_ID "GHS"
274# ifdef __GHS_VERSION_NUMBER
275# define COMPILER_VERSION_MAJOR DEC(__GHS_VERSION_NUMBER / 100)
276# define COMPILER_VERSION_MINOR DEC(__GHS_VERSION_NUMBER / 10 % 10)
277# define COMPILER_VERSION_PATCH DEC(__GHS_VERSION_NUMBER % 10)
280#elif defined(__TASKING__)
281# define COMPILER_ID "Tasking"
282 # define COMPILER_VERSION_MAJOR DEC(__VERSION__/1000)
283 # define COMPILER_VERSION_MINOR DEC(__VERSION__ % 100)
284# define COMPILER_VERSION_INTERNAL DEC(__VERSION__)
286#elif defined(__ORANGEC__)
287# define COMPILER_ID "OrangeC"
288# define COMPILER_VERSION_MAJOR DEC(__ORANGEC_MAJOR__)
289# define COMPILER_VERSION_MINOR DEC(__ORANGEC_MINOR__)
290# define COMPILER_VERSION_PATCH DEC(__ORANGEC_PATCHLEVEL__)
292#elif defined(__TINYC__)
293# define COMPILER_ID "TinyCC"
295#elif defined(__BCC__)
296# define COMPILER_ID "Bruce"
298#elif defined(__SCO_VERSION__)
299# define COMPILER_ID "SCO"
301#elif defined(__ARMCC_VERSION) && !defined(__clang__)
302# define COMPILER_ID "ARMCC"
303#if __ARMCC_VERSION >= 1000000
305 # define COMPILER_VERSION_MAJOR DEC(__ARMCC_VERSION/1000000)
306 # define COMPILER_VERSION_MINOR DEC(__ARMCC_VERSION/10000 % 100)
307 # define COMPILER_VERSION_PATCH DEC(__ARMCC_VERSION % 10000)
310 # define COMPILER_VERSION_MAJOR DEC(__ARMCC_VERSION/100000)
311 # define COMPILER_VERSION_MINOR DEC(__ARMCC_VERSION/10000 % 10)
312 # define COMPILER_VERSION_PATCH DEC(__ARMCC_VERSION % 10000)
316#elif defined(__clang__) && defined(__apple_build_version__)
317# define COMPILER_ID "AppleClang"
318# if defined(_MSC_VER)
319# define SIMULATE_ID "MSVC"
321# define COMPILER_VERSION_MAJOR DEC(__clang_major__)
322# define COMPILER_VERSION_MINOR DEC(__clang_minor__)
323# define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
324# if defined(_MSC_VER)
326# define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
327# define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
329# define COMPILER_VERSION_TWEAK DEC(__apple_build_version__)
331#elif defined(__clang__) && defined(__ARMCOMPILER_VERSION)
332# define COMPILER_ID "ARMClang"
333 # define COMPILER_VERSION_MAJOR DEC(__ARMCOMPILER_VERSION/1000000)
334 # define COMPILER_VERSION_MINOR DEC(__ARMCOMPILER_VERSION/10000 % 100)
335 # define COMPILER_VERSION_PATCH DEC(__ARMCOMPILER_VERSION/100 % 100)
336# define COMPILER_VERSION_INTERNAL DEC(__ARMCOMPILER_VERSION)
338#elif defined(__clang__) && defined(__ti__)
339# define COMPILER_ID "TIClang"
340 # define COMPILER_VERSION_MAJOR DEC(__ti_major__)
341 # define COMPILER_VERSION_MINOR DEC(__ti_minor__)
342 # define COMPILER_VERSION_PATCH DEC(__ti_patchlevel__)
343# define COMPILER_VERSION_INTERNAL DEC(__ti_version__)
345#elif defined(__clang__)
346# define COMPILER_ID "Clang"
347# if defined(_MSC_VER)
348# define SIMULATE_ID "MSVC"
350# define COMPILER_VERSION_MAJOR DEC(__clang_major__)
351# define COMPILER_VERSION_MINOR DEC(__clang_minor__)
352# define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
353# if defined(_MSC_VER)
355# define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
356# define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
359#elif defined(__LCC__) && (defined(__GNUC__) || defined(__GNUG__) || defined(__MCST__))
360# define COMPILER_ID "LCC"
361# define COMPILER_VERSION_MAJOR DEC(__LCC__ / 100)
362# define COMPILER_VERSION_MINOR DEC(__LCC__ % 100)
363# if defined(__LCC_MINOR__)
364# define COMPILER_VERSION_PATCH DEC(__LCC_MINOR__)
366# if defined(__GNUC__) && defined(__GNUC_MINOR__)
367# define SIMULATE_ID "GNU"
368# define SIMULATE_VERSION_MAJOR DEC(__GNUC__)
369# define SIMULATE_VERSION_MINOR DEC(__GNUC_MINOR__)
370# if defined(__GNUC_PATCHLEVEL__)
371# define SIMULATE_VERSION_PATCH DEC(__GNUC_PATCHLEVEL__)
375#elif defined(__GNUC__)
376# define COMPILER_ID "GNU"
377# define COMPILER_VERSION_MAJOR DEC(__GNUC__)
378# if defined(__GNUC_MINOR__)
379# define COMPILER_VERSION_MINOR DEC(__GNUC_MINOR__)
381# if defined(__GNUC_PATCHLEVEL__)
382# define COMPILER_VERSION_PATCH DEC(__GNUC_PATCHLEVEL__)
385#elif defined(_MSC_VER)
386# define COMPILER_ID "MSVC"
388# define COMPILER_VERSION_MAJOR DEC(_MSC_VER / 100)
389# define COMPILER_VERSION_MINOR DEC(_MSC_VER % 100)
390# if defined(_MSC_FULL_VER)
393# define COMPILER_VERSION_PATCH DEC(_MSC_FULL_VER % 100000)
396# define COMPILER_VERSION_PATCH DEC(_MSC_FULL_VER % 10000)
399# if defined(_MSC_BUILD)
400# define COMPILER_VERSION_TWEAK DEC(_MSC_BUILD)
403#elif defined(_ADI_COMPILER)
404# define COMPILER_ID "ADSP"
405#if defined(__VERSIONNUM__)
407# define COMPILER_VERSION_MAJOR DEC(__VERSIONNUM__ >> 24 & 0xFF)
408# define COMPILER_VERSION_MINOR DEC(__VERSIONNUM__ >> 16 & 0xFF)
409# define COMPILER_VERSION_PATCH DEC(__VERSIONNUM__ >> 8 & 0xFF)
410# define COMPILER_VERSION_TWEAK DEC(__VERSIONNUM__ & 0xFF)
413#elif defined(__IAR_SYSTEMS_ICC__) || defined(__IAR_SYSTEMS_ICC)
414# define COMPILER_ID "IAR"
415# if defined(__VER__) && defined(__ICCARM__)
416# define COMPILER_VERSION_MAJOR DEC((__VER__) / 1000000)
417# define COMPILER_VERSION_MINOR DEC(((__VER__) / 1000) % 1000)
418# define COMPILER_VERSION_PATCH DEC((__VER__) % 1000)
419# define COMPILER_VERSION_INTERNAL DEC(__IAR_SYSTEMS_ICC__)
420# elif defined(__VER__) && (defined(__ICCAVR__) || defined(__ICCRX__) || defined(__ICCRH850__) || defined(__ICCRL78__) || defined(__ICC430__) || defined(__ICCRISCV__) || defined(__ICCV850__) || defined(__ICC8051__) || defined(__ICCSTM8__))
421# define COMPILER_VERSION_MAJOR DEC((__VER__) / 100)
422# define COMPILER_VERSION_MINOR DEC((__VER__) - (((__VER__) / 100)*100))
423# define COMPILER_VERSION_PATCH DEC(__SUBVERSION__)
424# define COMPILER_VERSION_INTERNAL DEC(__IAR_SYSTEMS_ICC__)
427#elif defined(__SDCC_VERSION_MAJOR) || defined(SDCC)
428# define COMPILER_ID "SDCC"
429# if defined(__SDCC_VERSION_MAJOR)
430# define COMPILER_VERSION_MAJOR DEC(__SDCC_VERSION_MAJOR)
431# define COMPILER_VERSION_MINOR DEC(__SDCC_VERSION_MINOR)
432# define COMPILER_VERSION_PATCH DEC(__SDCC_VERSION_PATCH)
435# define COMPILER_VERSION_MAJOR DEC(SDCC/100)
436# define COMPILER_VERSION_MINOR DEC(SDCC/10 % 10)
437# define COMPILER_VERSION_PATCH DEC(SDCC % 10)
444#elif defined(__hpux) || defined(__hpua)
445# define COMPILER_ID "HP"
448# define COMPILER_ID ""
457char const* info_simulate =
"INFO" ":" "simulate[" SIMULATE_ID
"]";
461char const* qnxnto =
"INFO" ":" "qnxnto[]";
464#if defined(__CRAYXT_COMPUTE_LINUX_TARGET)
465char const *info_cray =
"INFO" ":" "compiler_wrapper[CrayPrgEnv]";
468#define STRINGIFY_HELPER(X) #X
469#define STRINGIFY(X) STRINGIFY_HELPER(X)
472#if defined(__linux) || defined(__linux__) || defined(linux)
473# define PLATFORM_ID "Linux"
475#elif defined(__MSYS__)
476# define PLATFORM_ID "MSYS"
478#elif defined(__CYGWIN__)
479# define PLATFORM_ID "Cygwin"
481#elif defined(__MINGW32__)
482# define PLATFORM_ID "MinGW"
484#elif defined(__APPLE__)
485# define PLATFORM_ID "Darwin"
487#elif defined(_WIN32) || defined(__WIN32__) || defined(WIN32)
488# define PLATFORM_ID "Windows"
490#elif defined(__FreeBSD__) || defined(__FreeBSD)
491# define PLATFORM_ID "FreeBSD"
493#elif defined(__NetBSD__) || defined(__NetBSD)
494# define PLATFORM_ID "NetBSD"
496#elif defined(__OpenBSD__) || defined(__OPENBSD)
497# define PLATFORM_ID "OpenBSD"
499#elif defined(__sun) || defined(sun)
500# define PLATFORM_ID "SunOS"
502#elif defined(_AIX) || defined(__AIX) || defined(__AIX__) || defined(__aix) || defined(__aix__)
503# define PLATFORM_ID "AIX"
505#elif defined(__hpux) || defined(__hpux__)
506# define PLATFORM_ID "HP-UX"
508#elif defined(__HAIKU__)
509# define PLATFORM_ID "Haiku"
511#elif defined(__BeOS) || defined(__BEOS__) || defined(_BEOS)
512# define PLATFORM_ID "BeOS"
514#elif defined(__QNX__) || defined(__QNXNTO__)
515# define PLATFORM_ID "QNX"
517#elif defined(__tru64) || defined(_tru64) || defined(__TRU64__)
518# define PLATFORM_ID "Tru64"
520#elif defined(__riscos) || defined(__riscos__)
521# define PLATFORM_ID "RISCos"
523#elif defined(__sinix) || defined(__sinix__) || defined(__SINIX__)
524# define PLATFORM_ID "SINIX"
526#elif defined(__UNIX_SV__)
527# define PLATFORM_ID "UNIX_SV"
529#elif defined(__bsdos__)
530# define PLATFORM_ID "BSDOS"
532#elif defined(_MPRAS) || defined(MPRAS)
533# define PLATFORM_ID "MP-RAS"
535#elif defined(__osf) || defined(__osf__)
536# define PLATFORM_ID "OSF1"
538#elif defined(_SCO_SV) || defined(SCO_SV) || defined(sco_sv)
539# define PLATFORM_ID "SCO_SV"
541#elif defined(__ultrix) || defined(__ultrix__) || defined(_ULTRIX)
542# define PLATFORM_ID "ULTRIX"
544#elif defined(__XENIX__) || defined(_XENIX) || defined(XENIX)
545# define PLATFORM_ID "Xenix"
547#elif defined(__WATCOMC__)
548# if defined(__LINUX__)
549# define PLATFORM_ID "Linux"
551# elif defined(__DOS__)
552# define PLATFORM_ID "DOS"
554# elif defined(__OS2__)
555# define PLATFORM_ID "OS2"
557# elif defined(__WINDOWS__)
558# define PLATFORM_ID "Windows3x"
560# elif defined(__VXWORKS__)
561# define PLATFORM_ID "VxWorks"
567#elif defined(__INTEGRITY)
568# if defined(INT_178B)
569# define PLATFORM_ID "Integrity178"
572# define PLATFORM_ID "Integrity"
575# elif defined(_ADI_COMPILER)
576# define PLATFORM_ID "ADSP"
588#if defined(_WIN32) && defined(_MSC_VER)
590# define ARCHITECTURE_ID "IA64"
592# elif defined(_M_ARM64EC)
593# define ARCHITECTURE_ID "ARM64EC"
595# elif defined(_M_X64) || defined(_M_AMD64)
596# define ARCHITECTURE_ID "x64"
598# elif defined(_M_IX86)
599# define ARCHITECTURE_ID "X86"
601# elif defined(_M_ARM64)
602# define ARCHITECTURE_ID "ARM64"
604# elif defined(_M_ARM)
606# define ARCHITECTURE_ID "ARMV4I"
608# define ARCHITECTURE_ID "ARMV5I"
610# define ARCHITECTURE_ID "ARMV" STRINGIFY(_M_ARM)
613# elif defined(_M_MIPS)
614# define ARCHITECTURE_ID "MIPS"
617# define ARCHITECTURE_ID "SHx"
620# define ARCHITECTURE_ID ""
623#elif defined(__WATCOMC__)
625# define ARCHITECTURE_ID "I86"
627# elif defined(_M_IX86)
628# define ARCHITECTURE_ID "X86"
631# define ARCHITECTURE_ID ""
634#elif defined(__IAR_SYSTEMS_ICC__) || defined(__IAR_SYSTEMS_ICC)
635# if defined(__ICCARM__)
636# define ARCHITECTURE_ID "ARM"
638# elif defined(__ICCRX__)
639# define ARCHITECTURE_ID "RX"
641# elif defined(__ICCRH850__)
642# define ARCHITECTURE_ID "RH850"
644# elif defined(__ICCRL78__)
645# define ARCHITECTURE_ID "RL78"
647# elif defined(__ICCRISCV__)
648# define ARCHITECTURE_ID "RISCV"
650# elif defined(__ICCAVR__)
651# define ARCHITECTURE_ID "AVR"
653# elif defined(__ICC430__)
654# define ARCHITECTURE_ID "MSP430"
656# elif defined(__ICCV850__)
657# define ARCHITECTURE_ID "V850"
659# elif defined(__ICC8051__)
660# define ARCHITECTURE_ID "8051"
662# elif defined(__ICCSTM8__)
663# define ARCHITECTURE_ID "STM8"
666# define ARCHITECTURE_ID ""
669#elif defined(__ghs__)
670# if defined(__PPC64__)
671# define ARCHITECTURE_ID "PPC64"
673# elif defined(__ppc__)
674# define ARCHITECTURE_ID "PPC"
676# elif defined(__ARM__)
677# define ARCHITECTURE_ID "ARM"
679# elif defined(__x86_64__)
680# define ARCHITECTURE_ID "x64"
682# elif defined(__i386__)
683# define ARCHITECTURE_ID "X86"
686# define ARCHITECTURE_ID ""
689#elif defined(__clang__) && defined(__ti__)
690# if defined(__ARM_ARCH)
691# define ARCHITECTURE_ID "Arm"
694# define ARCHITECTURE_ID ""
697#elif defined(__TI_COMPILER_VERSION__)
698# if defined(__TI_ARM__)
699# define ARCHITECTURE_ID "ARM"
701# elif defined(__MSP430__)
702# define ARCHITECTURE_ID "MSP430"
704# elif defined(__TMS320C28XX__)
705# define ARCHITECTURE_ID "TMS320C28x"
707# elif defined(__TMS320C6X__) || defined(_TMS320C6X)
708# define ARCHITECTURE_ID "TMS320C6x"
711# define ARCHITECTURE_ID ""
714# elif defined(__ADSPSHARC__)
715# define ARCHITECTURE_ID "SHARC"
717# elif defined(__ADSPBLACKFIN__)
718# define ARCHITECTURE_ID "Blackfin"
720#elif defined(__TASKING__)
722# if defined(__CTC__) || defined(__CPTC__)
723# define ARCHITECTURE_ID "TriCore"
725# elif defined(__CMCS__)
726# define ARCHITECTURE_ID "MCS"
728# elif defined(__CARM__)
729# define ARCHITECTURE_ID "ARM"
731# elif defined(__CARC__)
732# define ARCHITECTURE_ID "ARC"
734# elif defined(__C51__)
735# define ARCHITECTURE_ID "8051"
737# elif defined(__CPCP__)
738# define ARCHITECTURE_ID "PCP"
741# define ARCHITECTURE_ID ""
745# define ARCHITECTURE_ID
750 ('0' + (((n) / 10000000)%10)), \
751 ('0' + (((n) / 1000000)%10)), \
752 ('0' + (((n) / 100000)%10)), \
753 ('0' + (((n) / 10000)%10)), \
754 ('0' + (((n) / 1000)%10)), \
755 ('0' + (((n) / 100)%10)), \
756 ('0' + (((n) / 10)%10)), \
761 ('0' + ((n)>>28 & 0xF)), \
762 ('0' + ((n)>>24 & 0xF)), \
763 ('0' + ((n)>>20 & 0xF)), \
764 ('0' + ((n)>>16 & 0xF)), \
765 ('0' + ((n)>>12 & 0xF)), \
766 ('0' + ((n)>>8 & 0xF)), \
767 ('0' + ((n)>>4 & 0xF)), \
771#ifdef COMPILER_VERSION
772char const* info_version =
"INFO" ":" "compiler_version[" COMPILER_VERSION
"]";
775#elif defined(COMPILER_VERSION_MAJOR)
776char const info_version[] = {
777 'I',
'N',
'F',
'O',
':',
778 'c',
'o',
'm',
'p',
'i',
'l',
'e',
'r',
'_',
'v',
'e',
'r',
's',
'i',
'o',
'n',
'[',
779 COMPILER_VERSION_MAJOR,
780# ifdef COMPILER_VERSION_MINOR
781 '.', COMPILER_VERSION_MINOR,
782# ifdef COMPILER_VERSION_PATCH
783 '.', COMPILER_VERSION_PATCH,
784# ifdef COMPILER_VERSION_TWEAK
785 '.', COMPILER_VERSION_TWEAK,
793#ifdef COMPILER_VERSION_INTERNAL
794char const info_version_internal[] = {
795 'I',
'N',
'F',
'O',
':',
796 'c',
'o',
'm',
'p',
'i',
'l',
'e',
'r',
'_',
'v',
'e',
'r',
's',
'i',
'o',
'n',
'_',
797 'i',
'n',
't',
'e',
'r',
'n',
'a',
'l',
'[',
798 COMPILER_VERSION_INTERNAL,
']',
'\0'};
799#elif defined(COMPILER_VERSION_INTERNAL_STR)
800char const* info_version_internal =
"INFO" ":" "compiler_version_internal[" COMPILER_VERSION_INTERNAL_STR
"]";
804#ifdef SIMULATE_VERSION_MAJOR
805char const info_simulate_version[] = {
806 'I',
'N',
'F',
'O',
':',
807 's',
'i',
'm',
'u',
'l',
'a',
't',
'e',
'_',
'v',
'e',
'r',
's',
'i',
'o',
'n',
'[',
808 SIMULATE_VERSION_MAJOR,
809# ifdef SIMULATE_VERSION_MINOR
810 '.', SIMULATE_VERSION_MINOR,
811# ifdef SIMULATE_VERSION_PATCH
812 '.', SIMULATE_VERSION_PATCH,
813# ifdef SIMULATE_VERSION_TWEAK
814 '.', SIMULATE_VERSION_TWEAK,
830#define C_STD_99 199901L
831#define C_STD_11 201112L
832#define C_STD_17 201710L
833#define C_STD_23 202311L
835#ifdef __STDC_VERSION__
836# define C_STD __STDC_VERSION__
839#if !defined(__STDC__) && !defined(__clang__)
840# if defined(_MSC_VER) || defined(__ibmxl__) || defined(__IBMC__)
841# define C_VERSION "90"
845#elif C_STD > C_STD_17
846# define C_VERSION "23"
847#elif C_STD > C_STD_11
848# define C_VERSION "17"
849#elif C_STD > C_STD_99
850# define C_VERSION "11"
851#elif C_STD >= C_STD_99
852# define C_VERSION "99"
854# define C_VERSION "90"
857 "INFO" ":" "standard_default[" C_VERSION "]";
860#if (defined(__clang__) || defined(__GNUC__) || defined(__xlC__) || \
861 defined(__TI_COMPILER_VERSION__)) && \
862 !defined(__STRICT_ANSI__)
874# if defined(__CLASSIC_C__)
875int main(argc, argv)
int argc;
char *argv[];
877int main(
int argc,
char* argv[])
884#ifdef COMPILER_VERSION_MAJOR
885 require += info_version[argc];
887#ifdef COMPILER_VERSION_INTERNAL
888 require += info_version_internal[argc];
891 require += info_simulate[argc];
893#ifdef SIMULATE_VERSION_MAJOR
894 require += info_simulate_version[argc];
896#if defined(__CRAYXT_COMPUTE_LINUX_TARGET)
897 require += info_cray[argc];
int main(int argc, char *argv[])
const char * info_language_extensions_default
char const * info_platform
const char * info_language_standard_default
char const * info_compiler