Chandler Carruth | 885e78c | 2015-03-24 21:18:10 +0000 | [diff] [blame] | 1 | // RUN: rm -rf %t |
| 2 | // |
| 3 | // RUN: %clang_cc1 -fmodules -x c++ -fmodules-cache-path=%t \ |
Richard Smith | 47972af | 2015-06-16 00:08:24 +0000 | [diff] [blame] | 4 | // RUN: -fno-implicit-modules \ |
Chandler Carruth | 885e78c | 2015-03-24 21:18:10 +0000 | [diff] [blame] | 5 | // RUN: -emit-module -fmodule-name=empty -o %t/base.pcm \ |
| 6 | // RUN: %s |
| 7 | // |
| 8 | // RUN: %clang_cc1 -fmodules -x c++ -fmodules-cache-path=%t \ |
Richard Smith | 47972af | 2015-06-16 00:08:24 +0000 | [diff] [blame] | 9 | // RUN: -fno-implicit-modules \ |
Chandler Carruth | 885e78c | 2015-03-24 21:18:10 +0000 | [diff] [blame] | 10 | // RUN: -emit-module -fmodule-name=empty -o %t/check.pcm \ |
| 11 | // RUN: %s |
| 12 | // |
Richard Smith | 9c25418 | 2015-07-19 21:41:12 +0000 | [diff] [blame] | 13 | // The module file should be identical each time we produce it. |
Chandler Carruth | 885e78c | 2015-03-24 21:18:10 +0000 | [diff] [blame] | 14 | // RUN: diff %t/base.pcm %t/check.pcm |
Richard Smith | 9c25418 | 2015-07-19 21:41:12 +0000 | [diff] [blame] | 15 | // |
Richard Smith | 842d61f | 2015-07-20 08:40:51 +0000 | [diff] [blame] | 16 | // We expect an empty module to be less than 30KB (and at least 10K, for now). |
Richard Smith | 9c25418 | 2015-07-19 21:41:12 +0000 | [diff] [blame] | 17 | // RUN: wc -c %t/base.pcm | FileCheck --check-prefix=CHECK-SIZE %s |
Richard Smith | 842d61f | 2015-07-20 08:40:51 +0000 | [diff] [blame] | 18 | // CHECK-SIZE: {{(^|[^0-9])[12][0-9][0-9][0-9][0-9]($|[^0-9])}} |
Chandler Carruth | 885e78c | 2015-03-24 21:18:10 +0000 | [diff] [blame] | 19 | |
| 20 | module empty { header "Inputs/empty.h" export * } |