1 ! RUN: %flang -### -c --target=x86_64 -mcmodel=large -mlarge-data-threshold=32768 %s 2>&1 | FileCheck %s
2 ! RUN: %flang -### -c --target=x86_64 -mcmodel=large -mlarge-data-threshold=59000 %s 2>&1 | FileCheck %s --check-prefix=CHECK-59000
3 ! RUN: %flang -### -c --target=x86_64 -mcmodel=large -mlarge-data-threshold=1048576 %s 2>&1 | FileCheck %s --check-prefix=CHECK-1M
4 ! RUN: not %flang -c --target=x86_64 -mcmodel=large -mlarge-data-threshold=nonsense %s 2>&1 | FileCheck %s --check-prefix=INVALID
5 ! RUN: %flang -### -c --target=x86_64 -mlarge-data-threshold=32768 %s 2>&1 | FileCheck %s --check-prefix=NO-MCMODEL
6 ! RUN: %flang -### -c --target=x86_64 -mcmodel=small -mlarge-data-threshold=32768 %s 2>&1 | FileCheck %s --check-prefix=NO-MCMODEL
7 ! RUN: not %flang -### -c --target=aarch64 -mcmodel=small -mlarge-data-threshold=32768 %s 2>&1 | FileCheck %s --check-prefix=NOT-SUPPORTED
10 ! CHECK: "{{.*}}flang" "-fc1"
11 ! CHECK-SAME: "-mlarge-data-threshold=32768"
12 ! CHECK-59000: "{{.*}}flang" "-fc1"
13 ! CHECK-59000-SAME: "-mlarge-data-threshold=59000"
14 ! CHECK-1M: "{{.*}}flang" "-fc1"
15 ! CHECK-1M-SAME: "-mlarge-data-threshold=1048576"
16 ! NO-MCMODEL: 'mlarge-data-threshold=' only applies to medium and large code models
17 ! INVALID: error: invalid value 'nonsense' in '-mlarge-data-threshold='
18 ! NOT-SUPPORTED: error: unsupported option '-mlarge-data-threshold=' for target 'aarch64'