aboutsummaryrefslogtreecommitdiff
path: root/lib/Lex/Preprocessor.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-01-15 04:24:17 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-01-15 04:24:17 +0000
commita83fb8647bfca3aa9bd7049f817979f092244e83 (patch)
tree58b787c6864824712df6a044f818e882be63330c /lib/Lex/Preprocessor.cpp
parent4bb64e77dd3b22070e28b7f9ff99feb576eaf6ef (diff)
Add utils/ABITest, my ABI test generation tool.
- Mostly written as an entertaining exercise in enumerating large or (countably, naturally) infinite sets. But hey, its useful too! - Idea is to number all C-types so that the N-th type can quickly be computed, with a good deal of flexibility about what types to include, and taking some care so that the (N+1)-th type is interestingly different from the N-th type. For example, using the default generator, the 1,000,000-th function type is: -- typedef _Complex int T0; typedef char T1 __attribute__ ((vector_size (4))); typedef int T2 __attribute__ ((vector_size (4))); T2 fn1000000(T0 arg0, signed long long arg1, T1 arg2, T0 arg3); -- and the 1,000,001-th type is: -- typedef _Complex char T0; typedef _Complex char T2; typedef struct T1 { T2 field0; T2 field1; T2 field2; } T1; typedef struct T3 { } T3; unsigned short fn1000001(T0 arg0, T1 arg1, T3 arg2); -- Computing the 10^1600-th type takes a little less than 1s. :) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62253 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Lex/Preprocessor.cpp')
0 files changed, 0 insertions, 0 deletions