1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496
|
// Check handling MIPS specific features options.
//
// -mabicalls
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls -mabicalls 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MABICALLS %s
// CHECK-MABICALLS: "-target-feature" "-noabicalls"
//
// -mno-abicalls
// RUN: %clang --target=mips-linux-gnu -### -c %s -mabicalls -mno-abicalls 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MNOABICALLS %s
// CHECK-MNOABICALLS: "-target-feature" "+noabicalls"
//
// -mno-abicalls non-PIC N64
// RUN: %clang --target=mips64-linux-gnu -### -c -fno-PIC -mno-abicalls %s 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MNOABICALLS-N64NPIC %s
// CHECK-MNOABICALLS-N64NPIC: "-target-feature" "+noabicalls"
//
// -mgpopt
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-gpopt -mgpopt -Wno-unsupported-gpopt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MGPOPT-DEF-ABICALLS %s
// CHECK-MGPOPT-DEF-ABICALLS-NOT: "-mllvm" "-mgpopt"
//
// -mabicalls -mgpopt
// RUN: %clang --target=mips-linux-gnu -### -c %s -mabicalls -mno-gpopt -mgpopt -Wno-unsupported-gpopt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MGPOPT-EXPLICIT-ABICALLS %s
// CHECK-MGPOPT-EXPLICIT-ABICALLS-NOT: "-mllvm" "-mgpopt"
//
// -mno-abicalls -mgpopt
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls -mno-gpopt -mgpopt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MGPOPT %s
// CHECK-MGPOPT: "-mllvm" "-mgpopt"
//
// -mno-abicalls -mno-gpopt
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls -mgpopt -mno-gpopt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MNOGPOPT %s
// CHECK-MNOGPOPT-NOT: "-mllvm" "-mgpopt"
//
// -mno-abicalls
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MGPOPTDEF %s
// CHECK-MGPOPTDEF: "-mllvm" "-mgpopt"
//
// -mgpopt -mno-abicalls -mlocal-sdata
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls -mno-gpopt -mgpopt -mno-local-sdata -mlocal-sdata 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MLOCALSDATA %s
// CHECK-MLOCALSDATA: "-mllvm" "-mlocal-sdata=1"
//
// -mgpopt -mno-abicalls -mno-local-sdata
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls -mno-gpopt -mgpopt -mlocal-sdata -mno-local-sdata 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MNOLOCALSDATA %s
// CHECK-MNOLOCALSDATA: "-mllvm" "-mlocal-sdata=0"
//
// -mgpopt -mno-abicalls
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls -mgpopt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MLOCALSDATADEF %s
// CHECK-MLOCALSDATADEF-NOT: "-mllvm" "-mlocal-sdata"
//
// -mno-abicalls -mgpopt -mextern-sdata
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls -mgpopt -mno-extern-sdata -mextern-sdata 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MEXTERNSDATA %s
// CHECK-MEXTERNSDATA: "-mllvm" "-mextern-sdata=1"
//
// -mno-abicalls -mgpopt -mno-extern-sdata
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls -mgpopt -mextern-sdata -mno-extern-sdata 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MNOEXTERNSDATA %s
// CHECK-MNOEXTERNSDATA: "-mllvm" "-mextern-sdata=0"
//
// -mno-abicalls -mgpopt
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls -mgpopt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MEXTERNSDATADEF %s
// CHECK-MEXTERNSDATADEF-NOT: "-mllvm" "-mextern-sdata"
//
// -mno-abicalls -mgpopt -membedded-data
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls -mgpopt -mno-embedded-data -membedded-data 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MEMBEDDEDDATA %s
// CHECK-MEMBEDDEDDATA: "-mllvm" "-membedded-data=1"
//
// -mno-abicalls -mgpopt -mno-embedded-data
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls -mgpopt -membedded-data -mno-embedded-data 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MNOEMBEDDEDDATA %s
// CHECK-MNOEMBEDDEDDATA: "-mllvm" "-membedded-data=0"
//
// -mno-abicalls -mgpopt
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-abicalls -mgpopt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MEMBEDDEDDATADEF %s
// CHECK-MEMBEDDEDDATADEF-NOT: "-mllvm" "-membedded-data"
//
// MIPS64 + N64: -fno-pic -> -mno-abicalls -mgpopt
// RUN: %clang --target=mips64-mti-elf -mabi=64 -### -c %s -fno-pic -mno-abicalls 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-N64-GPOPT %s
// CHECK-N64-GPOPT: "-target-feature" "+noabicalls"
// CHECK-N64-GPOPT: "-mllvm" "-mgpopt"
//
// MIPS64 + N64: -fno-pic -mno-gpopt
// RUN: %clang --target=mips64-mti-elf -mabi=64 -### -c %s -fno-pic -mno-abicalls -mno-gpopt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-N64-MNO-GPOPT %s
// CHECK-N64-MNO-GPOPT: "-target-feature" "+noabicalls"
// CHECK-N64-MNO-GPOPT-NOT: "-mllvm" "-mgpopt"
//
// MIPS64 + N64: -mgpopt (-fpic is implicit)
// RUN: %clang --target=mips64-mti-linux-gnu -mabi=64 -### -c %s -mgpopt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-N64-PIC-GPOPT %s
// CHECK-N64-PIC-GPOPT-NOT: "-mllvm" "-mgpopt"
// CHECK-N64-PIC-GPOPT: ignoring '-mgpopt' option as it cannot be used with the implicit usage of -mabicalls
//
// -mips16
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mno-mips16 -mips16 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MIPS16 %s
// CHECK-MIPS16: "-target-feature" "+mips16"
//
// -mno-mips16
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mips16 -mno-mips16 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NOMIPS16 %s
// CHECK-NOMIPS16: "-target-feature" "-mips16"
//
// -mmicromips
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mno-micromips -mmicromips 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MICROMIPS %s
// CHECK-MICROMIPS: "-target-feature" "+micromips"
//
// -mno-micromips
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mmicromips -mno-micromips 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NOMICROMIPS %s
// CHECK-NOMICROMIPS: "-target-feature" "-micromips"
//
// -mdsp
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mno-dsp -mdsp 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MDSP %s
// CHECK-MDSP: "-target-feature" "+dsp"
//
// -mno-dsp
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mdsp -mno-dsp 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NOMDSP %s
// CHECK-NOMDSP: "-target-feature" "-dsp"
//
// -mdspr2
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mno-dspr2 -mdspr2 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MDSPR2 %s
// CHECK-MDSPR2: "-target-feature" "+dspr2"
//
// -mno-dspr2
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mdspr2 -mno-dspr2 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NOMDSPR2 %s
// CHECK-NOMDSPR2: "-target-feature" "-dspr2"
//
// -mmsa
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mno-msa -mmsa 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MMSA %s
// CHECK-MMSA: "-target-feature" "+msa"
//
// -mno-msa
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mmsa -mno-msa 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NOMMSA %s
// CHECK-NOMMSA: "-target-feature" "-msa"
//
// -mmsa
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mmsa 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MMSA-MFP64 %s
// CHECK-MMSA-MFP64: "-target-feature" "+msa" "-target-feature" "+fp64"
//
// -mmt
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mno-mt -mmt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MMT %s
// CHECK-MMT: "-target-feature" "+mt"
//
// -mno-mt
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mmt -mno-mt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NOMMT %s
// CHECK-NOMMT: "-target-feature" "-mt"
//
// -modd-spreg
// RUN: %clang --target=mips-linux-gnu -### -c %s -mno-odd-spreg -modd-spreg 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MODDSPREG %s
// CHECK-MODDSPREG: "-target-feature" "-nooddspreg"
//
// -mno-odd-spreg
// RUN: %clang --target=mips-linux-gnu -### -c %s -modd-spreg -mno-odd-spreg 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NOMODDSPREG %s
// CHECK-NOMODDSPREG: "-target-feature" "+nooddspreg"
//
// -mfpxx
// RUN: %clang --target=mips-linux-gnu -### -c %s -mfpxx 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MFPXX %s
// CHECK-MFPXX: "-target-feature" "+fpxx"
// CHECK-MFPXX: "-target-feature" "+nooddspreg"
//
// -mfpxx -modd-spreg
// RUN: %clang --target=mips-linux-gnu -### -c %s -mfpxx -modd-spreg 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MFPXX-ODDSPREG %s
// CHECK-MFPXX-ODDSPREG: "-target-feature" "+fpxx"
// CHECK-MFPXX-ODDSPREG: "-target-feature" "-nooddspreg"
//
// -mfp64
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mfp32 -mfp64 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MFP64 %s
// CHECK-MFP64: "-target-feature" "+fp64"
//
// -mfp32
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mfp64 -mfp32 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NOMFP64 %s
// CHECK-NOMFP64: "-target-feature" "-fp64"
//
// -mnan=2008
// RUN: %clang --target=mips-linux-gnu -march=mips32r3 -### -c %s \
// RUN: -mnan=legacy -mnan=2008 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NAN2008 %s
// CHECK-NAN2008: "-target-feature" "+nan2008" "-target-feature" "+abs2008"
//
// -mnan=2008 -mabs=legacy
// RUN: %clang --target=mips-linux-gnu -march=mips32r3 -### -c %s \
// RUN: -mabs=legacy -mnan=2008 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-ABSLEGACYNAN2008 %s
// CHECK-ABSLEGACYNAN2008: "-target-feature" "+nan2008" "-target-feature" "-abs2008"
//
// -mnan=legacy
// RUN: %clang --target=mips-linux-gnu -march=mips32r3 -### -c %s \
// RUN: -mnan=2008 -mnan=legacy 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NANLEGACY %s
// CHECK-NANLEGACY: "-target-feature" "-nan2008"
//
// -mabs=2008 on pre R2
// RUN: %clang --target=mips-linux-gnu -march=mips32 -### -c %s \
// RUN: -mabs=2008 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-ABSLEGACY %s
//
// -mabs=2008
// RUN: %clang --target=mips-linux-gnu -march=mips32r3 -### -c %s \
// RUN: -mabs=2008 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-ABS2008 %s
//
// -mabs=legacy
// RUN: %clang --target=mips-linux-gnu -march=mips32r3 -### -c %s \
// RUN: -mabs=legacy 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-ABSLEGACY %s
//
// -mabs=legacy on R6
// RUN: %clang --target=mips-linux-gnu -march=mips32r6 -### -c %s \
// RUN: -mabs=legacy 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-ABS2008 %s
//
// CHECK-ABSLEGACY: "-target-feature" "-abs2008"
// CHECK-ABSLEGACY-NOT: "-target-feature" "+abs2008"
// CHECK-ABS2008: "-target-feature" "+abs2008"
// CHECK-ABS2008-NOT: "-target-feature" "-abs2008"
//
// -mcompact-branches=never
// RUN: %clang --target=mips-linux-gnu -march=mips32r6 -### -c %s \
// RUN: -mcompact-branches=never 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-CBNEVER %s
// CHECK-CBNEVER: "-mllvm" "-mips-compact-branches=never"
//
// -mcompact-branches=optimal
// RUN: %clang --target=mips-linux-gnu -march=mips32r6 -### -c %s \
// RUN: -mcompact-branches=optimal 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-CBOPTIMAL %s
// CHECK-CBOPTIMAL: "-mllvm" "-mips-compact-branches=optimal"
//
// -mcompact-branches=always
// RUN: %clang --target=mips-linux-gnu -march=mips32r6 -### -c %s \
// RUN: -mcompact-branches=always 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-CBALWAYS %s
// CHECK-CBALWAYS: "-mllvm" "-mips-compact-branches=always"
//
// -mxgot
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mno-xgot -mxgot 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-XGOT %s
// CHECK-XGOT: "-target-feature" "+xgot"
//
// -mno-xgot
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mxgot -mno-xgot 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NOXGOT %s
// CHECK-NOXGOT: "-target-feature" "-xgot"
//
// -mldc1-sdc1
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mno-ldc1-sdc1 -mldc1-sdc1 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-LDC1SDC1 %s
// CHECK-LDC1SDC1-NOT: "-mllvm" "-mno-ldc1-sdc1"
//
// -mno-ldc1-sdc1
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mldc1-sdc1 -mno-ldc1-sdc1 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NOLDC1SDC1 %s
// CHECK-NOLDC1SDC1: "-mllvm" "-mno-ldc1-sdc1"
//
// -mcheck-zero-division
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mno-check-zero-division -mcheck-zero-division 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-ZERODIV %s
// CHECK-ZERODIV-NOT: "-mllvm" "-mno-check-zero-division"
//
// -mno-check-zero-division
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -mcheck-zero-division -mno-check-zero-division 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NOZERODIV %s
// CHECK-NOZERODIV: "-mllvm" "-mno-check-zero-division"
//
// -G
// RUN: %clang --target=mips-linux-gnu -### -c %s \
// RUN: -G 16 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MIPS-G %s
// CHECK-MIPS-G: "-mllvm" "-mips-ssection-threshold=16"
//
// -msoft-float (unknown vendor)
// RUN: %clang --target=mips-linux-gnu -### -c %s -msoft-float 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-SOFTFLOAT %s
// CHECK-SOFTFLOAT: "-target-feature" "+soft-float"
// CHECK-SOFTFLOAT-NOT: "-target-feature" "+fpxx"
//
// -msoft-float -mfpxx (unknown vendor)
// RUN: %clang --target=mips-linux-gnu -### -c %s -msoft-float -mfpxx 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-SOFTFLOAT-FPXX %s
// CHECK-SOFTFLOAT-FPXX: "-target-feature" "+soft-float"
// CHECK-SOFTFLOAT-FPXX: "-target-feature" "+fpxx"
//
// -msoft-float (MTI)
// RUN: %clang --target=mips-mti-linux-gnu -### -c %s -msoft-float 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MTI-SOFTFLOAT %s
// CHECK-MTI-SOFTFLOAT: "-target-feature" "+soft-float"
// CHECK-MTI-SOFTFLOAT-NOT: "-target-feature" "+fpxx"
//
// -msoft-float -mfpxx (MTI)
// RUN: %clang --target=mips-mti-linux-gnu -### -c %s -msoft-float -mfpxx 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MTI-SOFTFLOAT-FPXX %s
// CHECK-MTI-SOFTFLOAT-FPXX: "-target-feature" "+soft-float"
// CHECK-MTI-SOFTFLOAT-FPXX: "-target-feature" "+fpxx"
//
// -msoft-float (IMG)
// RUN: %clang --target=mips-img-linux-gnu -### -c %s -msoft-float 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-IMG-SOFTFLOAT %s
// CHECK-IMG-SOFTFLOAT: "-target-feature" "+soft-float"
// CHECK-IMG-SOFTFLOAT-NOT: "-target-feature" "+fpxx"
//
// -msoft-float -mfpxx (IMG)
// RUN: %clang --target=mips-img-linux-gnu -### -c %s -msoft-float -mfpxx 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-IMG-SOFTFLOAT-FPXX %s
// CHECK-IMG-SOFTFLOAT-FPXX: "-target-feature" "+soft-float"
// CHECK-IMG-SOFTFLOAT-FPXX: "-target-feature" "+fpxx"
//
// -msingle-float (unknown vendor)
// RUN: %clang --target=mips-linux-gnu -### -c %s -msingle-float 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-SINGLEFLOAT %s
// CHECK-SINGLEFLOAT: "-target-feature" "+single-float"
// CHECK-SINGLEFLOAT-NOT: "-target-feature" "+fpxx"
//
// -msingle-float -mfpxx (unknown vendor)
// RUN: %clang --target=mips-linux-gnu -### -c %s -msingle-float -mfpxx 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-SINGLEFLOAT-FPXX %s
// CHECK-SINGLEFLOAT-FPXX: "-target-feature" "+single-float"
// CHECK-SINGLEFLOAT-FPXX: "-target-feature" "+fpxx"
//
// -msingle-float (MTI)
// RUN: %clang --target=mips-mti-linux-gnu -### -c %s -msingle-float 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MTI-SINGLEFLOAT %s
// CHECK-MTI-SINGLEFLOAT: "-target-feature" "+single-float"
// CHECK-MTI-SINGLEFLOAT-NOT: "-target-feature" "+fpxx"
//
// -msingle-float -mfpxx (MTI)
// RUN: %clang --target=mips-mti-linux-gnu -### -c %s -msingle-float -mfpxx 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-MTI-SINGLEFLOAT-FPXX %s
// CHECK-MTI-SINGLEFLOAT-FPXX: "-target-feature" "+single-float"
// CHECK-MTI-SINGLEFLOAT-FPXX: "-target-feature" "+fpxx"
//
// -msingle-float (IMG)
// RUN: %clang --target=mips-img-linux-gnu -### -c %s -msingle-float 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-IMG-SINGLEFLOAT %s
// CHECK-IMG-SINGLEFLOAT: "-target-feature" "+single-float"
// CHECK-IMG-SINGLEFLOAT-NOT: "-target-feature" "+fpxx"
//
// -msingle-float -mfpxx (IMG)
// RUN: %clang --target=mips-img-linux-gnu -### -c %s -msingle-float -mfpxx 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-IMG-SINGLEFLOAT-FPXX %s
// CHECK-IMG-SINGLEFLOAT-FPXX: "-target-feature" "+single-float"
// CHECK-IMG-SINGLEFLOAT-FPXX: "-target-feature" "+fpxx"
// -mlong-call
// RUN: %clang --target=mips-img-linux-gnu -### -c %s \
// RUN: -mno-abicalls -mlong-calls 2>&1 \
// RUN: | FileCheck --check-prefix=LONG-CALLS-ON %s
// RUN: %clang --target=mips-img-linux-gnu -### -c %s \
// RUN: -mno-abicalls -mno-long-calls 2>&1 \
// RUN: | FileCheck --check-prefix=LONG-CALLS-OFF %s
// RUN: %clang --target=mips-img-linux-gnu -### -c %s 2>&1 \
// RUN: | FileCheck --check-prefix=LONG-CALLS-DEF %s
// RUN: %clang --target=mips-img-linux-gnu -### -c %s -mlong-calls 2>&1 \
// RUN: | FileCheck --check-prefix=LONG-CALLS-DEF %s
// LONG-CALLS-ON: "-target-feature" "+long-calls"
// LONG-CALLS-OFF: "-target-feature" "-long-calls"
// LONG-CALLS-DEF-NOT: "long-calls"
//
// -mbranch-likely
// RUN: %clang --target=mips-mti-linux-gnu -### -c %s -mbranch-likely 2>&1 \
// RUN: | FileCheck --check-prefix=BRANCH-LIKELY %s
// BRANCH-LIKELY: argument unused during compilation: '-mbranch-likely'
//
// -mno-branch-likely
// RUN: %clang --target=mips-mti-linux-gnu -### -c %s -mno-branch-likely 2>&1 \
// RUN: | FileCheck --check-prefix=NO-BRANCH-LIKELY %s
// NO-BRANCH-LIKELY: argument unused during compilation: '-mno-branch-likely'
// -mindirect-jump=hazard
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -mindirect-jump=hazard 2>&1 \
// RUN: | FileCheck --check-prefix=INDIRECT-BH %s
// INDIRECT-BH: "-target-feature" "+use-indirect-jump-hazard"
//
// -mcrc
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -mno-crc -mcrc 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-CRC %s
// CHECK-CRC: "-target-feature" "+crc"
//
// -mno-crc
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -mcrc -mno-crc 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NO-CRC %s
// CHECK-NO-CRC: "-target-feature" "-crc"
//
// -mvirt
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -mno-virt -mvirt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-VIRT %s
// CHECK-VIRT: "-target-feature" "+virt"
//
// -mno-virt
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -mvirt -mno-virt 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NO-VIRT %s
// CHECK-NO-VIRT: "-target-feature" "-virt"
//
// -mginv
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -mno-ginv -mginv 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-GINV %s
// CHECK-GINV: "-target-feature" "+ginv"
//
// -mno-ginv
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -mginv -mno-ginv 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NO-GINV %s
// CHECK-NO-GINV: "-target-feature" "-ginv"
//
// -mrelax-pic-calls
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -mno-relax-pic-calls -mrelax-pic-calls 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-RELAX-PIC-CALLS %s
// CHECK-RELAX-PIC-CALLS-NOT: "-mllvm" "-mips-jalr-reloc=0"
//
// -mno-relax-pic-calls
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -mrelax-pic-calls -mno-relax-pic-calls 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NO-RELAX-PIC-CALLS %s
// CHECK-NO-RELAX-PIC-CALLS: "-mllvm" "-mips-jalr-reloc=0"
//
// -mno-unaligned-access
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -munaligned-access -mno-strict-align \
// RUN: -mno-unaligned-access 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-STRICT-ALIGN %s
// CHECK-STRICT-ALIGN: "-target-feature" "+strict-align"
//
// -munaligned-access
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -mno-unaligned-access -mstrict-align \
// RUN: -munaligned-access 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NO-STRICT-ALIGN %s
// CHECK-NO-STRICT-ALIGN: "-target-feature" "-strict-align"
//
// -mstrict-align
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -munaligned-access -mno-strict-align \
// RUN: -mstrict-align 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-STRICT-ALIGN %s
//
// -mno-strict-align
// RUN: %clang --target=mips-unknown-linux-gnu -### -c %s \
// RUN: -mno-unaligned-access -mstrict-align \
// RUN: -mno-strict-align 2>&1 \
// RUN: | FileCheck --check-prefix=CHECK-NO-STRICT-ALIGN %s
|