| OLD | NEW |
| 1 #!/bin/bash | 1 #!/bin/bash |
| 2 | 2 |
| 3 # Copyright (c) 2012 The Native Client Authors. All rights reserved. | 3 # Copyright (c) 2012 The Native Client Authors. All rights reserved. |
| 4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
| 5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
| 6 | 6 |
| 7 set -o nounset | 7 set -o nounset |
| 8 set -o errexit | 8 set -o errexit |
| 9 | 9 |
| 10 # The script is located in "native_client/tests/spec2k" | 10 # The script is located in "native_client/tests/spec2k" |
| (...skipping 311 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 322 } | 322 } |
| 323 | 323 |
| 324 #@ | 324 #@ |
| 325 #@ SetupPnaclTranslatorFastX8664Opt | 325 #@ SetupPnaclTranslatorFastX8664Opt |
| 326 #@ use pnacl x8664 translator fast mode (with lto) | 326 #@ use pnacl x8664 translator fast mode (with lto) |
| 327 SetupPnaclTranslatorFastX8664Opt() { | 327 SetupPnaclTranslatorFastX8664Opt() { |
| 328 SetupPnaclX8664Common | 328 SetupPnaclX8664Common |
| 329 SUFFIX=pnacl_translator_fast.opt.x8664 | 329 SUFFIX=pnacl_translator_fast.opt.x8664 |
| 330 } | 330 } |
| 331 | 331 |
| 332 | |
| 333 #@ | 332 #@ |
| 334 #@ SetupPnaclTranslator1ThreadX8664Opt | 333 #@ SetupPnaclTranslator1ThreadX8664Opt |
| 335 #@ use pnacl x8664 translator (with lto). Compile w/ 1 thread. | 334 #@ use pnacl x8664 translator (with lto). Compile w/ 1 thread. |
| 336 SetupPnaclTranslator1ThreadX8664Opt() { | 335 SetupPnaclTranslator1ThreadX8664Opt() { |
| 337 SetupPnaclX8664Common | 336 SetupPnaclX8664Common |
| 338 SUFFIX=pnacl_translator_1thread.opt.x8664 | 337 SUFFIX=pnacl_translator_1thread.opt.x8664 |
| 339 } | 338 } |
| 340 | 339 |
| 341 #@ | 340 #@ |
| 342 #@ SetupPnaclTranslatorFast1ThreadX8664Opt | 341 #@ SetupPnaclTranslatorFast1ThreadX8664Opt |
| 343 #@ use pnacl x8664 translator fast mode (with lto). Compile w/ 1 thread. | 342 #@ use pnacl x8664 translator fast mode (with lto). Compile w/ 1 thread. |
| 344 SetupPnaclTranslatorFast1ThreadX8664Opt() { | 343 SetupPnaclTranslatorFast1ThreadX8664Opt() { |
| 345 SetupPnaclX8664Common | 344 SetupPnaclX8664Common |
| 346 SUFFIX=pnacl_translator_fast_1thread.opt.x8664 | 345 SUFFIX=pnacl_translator_fast_1thread.opt.x8664 |
| 347 } | 346 } |
| 348 | 347 |
| 349 | |
| 350 SetupPnaclX8632Common() { | 348 SetupPnaclX8632Common() { |
| 351 SetupSelLdr x86-32 | 349 SetupSelLdr x86-32 |
| 352 } | 350 } |
| 353 | 351 |
| 354 #@ | 352 #@ |
| 355 #@ SetupPnaclX8632 | 353 #@ SetupPnaclX8632 |
| 356 #@ use pnacl x86-32 compiler (no lto) | 354 #@ use pnacl x86-32 compiler (no lto) |
| 357 SetupPnaclX8632() { | 355 SetupPnaclX8632() { |
| 358 SetupPnaclX8632Common | 356 SetupPnaclX8632Common |
| 359 SUFFIX=pnacl.x8632 | 357 SUFFIX=pnacl.x8632 |
| 360 } | 358 } |
| 361 | 359 |
| 362 #@ | 360 #@ |
| 363 #@ SetupPnaclX8632Opt | 361 #@ SetupPnaclX8632Opt |
| 364 #@ use pnacl x86-32 compiler (with lto) | 362 #@ use pnacl x86-32 compiler (with lto) |
| 365 SetupPnaclX8632Opt() { | 363 SetupPnaclX8632Opt() { |
| 366 SetupPnaclX8632Common | 364 SetupPnaclX8632Common |
| 367 SUFFIX=pnacl.opt.x8632 | 365 SUFFIX=pnacl.opt.x8632 |
| 368 } | 366 } |
| 369 | 367 |
| 368 #@ |
| 369 #@ SetupPnaclX8632OptSz |
| 370 #@ use pnacl x86-32 compiler (with lto) plus Subzero |
| 371 SetupPnaclX8632OptSz() { |
| 372 SetupPnaclX8632Common |
| 373 SUFFIX=pnacl.opt.sz.x8632 |
| 374 } |
| 370 | 375 |
| 371 #@ | 376 #@ |
| 372 #@ SetupPnaclTranslatorX8632 | 377 #@ SetupPnaclTranslatorX8632 |
| 373 #@ use pnacl x8632 translator (no lto) | 378 #@ use pnacl x8632 translator (no lto) |
| 374 SetupPnaclTranslatorX8632() { | 379 SetupPnaclTranslatorX8632() { |
| 375 SetupPnaclX8632Common | 380 SetupPnaclX8632Common |
| 376 SUFFIX=pnacl_translator.x8632 | 381 SUFFIX=pnacl_translator.x8632 |
| 377 } | 382 } |
| 378 | 383 |
| 379 #@ | 384 #@ |
| 380 #@ SetupPnaclTranslatorX8632Opt | 385 #@ SetupPnaclTranslatorX8632Opt |
| 381 #@ use pnacl x8632 translator (with lto) | 386 #@ use pnacl x8632 translator (with lto) |
| 382 SetupPnaclTranslatorX8632Opt() { | 387 SetupPnaclTranslatorX8632Opt() { |
| 383 SetupPnaclX8632Common | 388 SetupPnaclX8632Common |
| 384 SUFFIX=pnacl_translator.opt.x8632 | 389 SUFFIX=pnacl_translator.opt.x8632 |
| 385 } | 390 } |
| 386 | 391 |
| 387 #@ | 392 #@ |
| 393 #@ SetupPnaclTranslatorX8632OptSz |
| 394 #@ use pnacl x8632 Subzero translator (with lto) |
| 395 SetupPnaclTranslatorX8632OptSz() { |
| 396 SetupPnaclX8632Common |
| 397 SUFFIX=pnacl_translator.opt.sz.x8632 |
| 398 } |
| 399 |
| 400 #@ |
| 388 #@ SetupPnaclTranslatorFastX8632Opt | 401 #@ SetupPnaclTranslatorFastX8632Opt |
| 389 #@ use pnacl x8632 translator fast mode (with lto) | 402 #@ use pnacl x8632 translator fast mode (with lto) |
| 390 SetupPnaclTranslatorFastX8632Opt() { | 403 SetupPnaclTranslatorFastX8632Opt() { |
| 391 SetupPnaclX8632Common | 404 SetupPnaclX8632Common |
| 392 SUFFIX=pnacl_translator_fast.opt.x8632 | 405 SUFFIX=pnacl_translator_fast.opt.x8632 |
| 393 } | 406 } |
| 394 | 407 |
| 395 #@ | 408 #@ |
| 396 #@ SetupPnaclTranslator1ThreadX8632Opt | 409 #@ SetupPnaclTranslator1ThreadX8632Opt |
| 397 #@ use pnacl x8632 translator (with lto). Compile w/ 1 thread. | 410 #@ use pnacl x8632 translator (with lto). Compile w/ 1 thread. |
| 398 SetupPnaclTranslator1ThreadX8632Opt() { | 411 SetupPnaclTranslator1ThreadX8632Opt() { |
| 399 SetupPnaclX8632Common | 412 SetupPnaclX8632Common |
| 400 SUFFIX=pnacl_translator_1thread.opt.x8632 | 413 SUFFIX=pnacl_translator_1thread.opt.x8632 |
| 401 } | 414 } |
| 402 | 415 |
| 403 #@ | 416 #@ |
| 404 #@ SetupPnaclTranslatorFast1ThreadX8632Opt | 417 #@ SetupPnaclTranslatorFast1ThreadX8632Opt |
| 405 #@ use pnacl x8632 translator fast mode (with lto). Compile w/ 1 thread. | 418 #@ use pnacl x8632 translator fast mode (with lto). Compile w/ 1 thread. |
| 406 SetupPnaclTranslatorFast1ThreadX8632Opt() { | 419 SetupPnaclTranslatorFast1ThreadX8632Opt() { |
| 407 SetupPnaclX8632Common | 420 SetupPnaclX8632Common |
| 408 SUFFIX=pnacl_translator_fast_1thread.opt.x8632 | 421 SUFFIX=pnacl_translator_fast_1thread.opt.x8632 |
| 409 } | 422 } |
| 410 | 423 |
| 411 | |
| 412 #@ | 424 #@ |
| 413 #@ SetupGccArm | 425 #@ SetupGccArm |
| 414 #@ use gcc cross compiler | 426 #@ use gcc cross compiler |
| 415 SetupGccArm() { | 427 SetupGccArm() { |
| 416 PREFIX="${QEMU_TOOL}" | 428 PREFIX="${QEMU_TOOL}" |
| 417 SUFFIX=gcc.arm | 429 SUFFIX=gcc.arm |
| 418 } | 430 } |
| 419 | 431 |
| 420 #@ | 432 #@ |
| 421 #@ SetupGccArmOpt | 433 #@ SetupGccArmOpt |
| 422 #@ use gcc cross compiler | 434 #@ use gcc cross compiler |
| 423 SetupGccArmOpt() { | 435 SetupGccArmOpt() { |
| 424 PREFIX="${QEMU_TOOL}" | 436 PREFIX="${QEMU_TOOL}" |
| 425 SUFFIX=gcc.opt.arm | 437 SUFFIX=gcc.opt.arm |
| 426 } | 438 } |
| 427 | 439 |
| 428 | |
| 429 SetupPnaclArmCommon() { | 440 SetupPnaclArmCommon() { |
| 430 SetupSelLdr arm "${QEMU_TOOL}" "-Q" | 441 SetupSelLdr arm "${QEMU_TOOL}" "-Q" |
| 431 } | 442 } |
| 432 | 443 |
| 433 #@ | 444 #@ |
| 434 #@ SetupPnaclArmOpt | 445 #@ SetupPnaclArmOpt |
| 435 #@ use pnacl arm compiler (with lto) -- run with QEMU | 446 #@ use pnacl arm compiler (with lto) -- run with QEMU |
| 436 SetupPnaclArmOpt() { | 447 SetupPnaclArmOpt() { |
| 437 SetupPnaclArmCommon | 448 SetupPnaclArmCommon |
| 438 SUFFIX=pnacl.opt.arm | 449 SUFFIX=pnacl.opt.arm |
| (...skipping 24 matching lines...) Expand all Loading... |
| 463 } | 474 } |
| 464 | 475 |
| 465 #@ | 476 #@ |
| 466 #@ SetupPnaclTranslatorFastArmOpt | 477 #@ SetupPnaclTranslatorFastArmOpt |
| 467 #@ use pnacl arm translator fast mode (with lto) | 478 #@ use pnacl arm translator fast mode (with lto) |
| 468 SetupPnaclTranslatorFastArmOpt() { | 479 SetupPnaclTranslatorFastArmOpt() { |
| 469 SetupPnaclArmCommon | 480 SetupPnaclArmCommon |
| 470 SUFFIX=pnacl_translator_fast.opt.arm | 481 SUFFIX=pnacl_translator_fast.opt.arm |
| 471 } | 482 } |
| 472 | 483 |
| 473 | |
| 474 | |
| 475 SetupPnaclArmCommonHW() { | 484 SetupPnaclArmCommonHW() { |
| 476 SetupSelLdr arm | 485 SetupSelLdr arm |
| 477 } | 486 } |
| 478 | 487 |
| 479 #@ | 488 #@ |
| 480 #@ SetupPnaclArmOptHW | 489 #@ SetupPnaclArmOptHW |
| 481 #@ use pnacl arm compiler (with lto) -- run on ARM hardware | 490 #@ use pnacl arm compiler (with lto) -- run on ARM hardware |
| 482 SetupPnaclArmOptHW() { | 491 SetupPnaclArmOptHW() { |
| 483 SetupPnaclArmCommonHW | 492 SetupPnaclArmCommonHW |
| 484 SUFFIX=pnacl.opt.arm | 493 SUFFIX=pnacl.opt.arm |
| (...skipping 499 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 984 | 993 |
| 985 [ $# = 0 ] && set -- help # Avoid reference to undefined $1. | 994 [ $# = 0 ] && set -- help # Avoid reference to undefined $1. |
| 986 | 995 |
| 987 if [ "$(type -t $1)" != "function" ]; then | 996 if [ "$(type -t $1)" != "function" ]; then |
| 988 Usage | 997 Usage |
| 989 echo "ERROR: unknown mode '$1'." >&2 | 998 echo "ERROR: unknown mode '$1'." >&2 |
| 990 exit 1 | 999 exit 1 |
| 991 fi | 1000 fi |
| 992 | 1001 |
| 993 "$@" | 1002 "$@" |
| OLD | NEW |