OLD | NEW |
---|---|
1 # The following variables will likely need to be modified, depending on where | 1 # The following variables will likely need to be modified, depending on where |
2 # and how you built LLVM & Clang. They can be overridden in a command-line | 2 # and how you built LLVM & Clang. They can be overridden in a command-line |
3 # invocation of make, like: | 3 # invocation of make, like: |
4 # | 4 # |
5 # make LLVM_SRC_PATH=<path> LIBCXX_INSTALL_PATH=<path> CLANG_PATH=<path> \ | 5 # make LLVM_SRC_PATH=<path> LIBCXX_INSTALL_PATH=<path> CLANG_PATH=<path> \ |
6 # PNACL_BIN_PATH=<path> ... | 6 # PNACL_BIN_PATH=<path> ... |
7 # | 7 # |
8 | 8 |
9 # LLVM_SRC_PATH is the path to the root of the checked out source code. This | 9 # LLVM_SRC_PATH is the path to the root of the checked out source code. This |
10 # directory should contain the configure script, the include/ and lib/ | 10 # directory should contain the configure script, the include/ and lib/ |
(...skipping 392 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
403 @$(SHOW_BUILD_ATTS) | 403 @$(SHOW_BUILD_ATTS) |
404 | 404 |
405 sb_make_symlink: $(NEXES) | 405 sb_make_symlink: $(NEXES) |
406 $(foreach nexe,$(NEXES),rm -rf $(notdir $(nexe)); ln -s $(nexe);) | 406 $(foreach nexe,$(NEXES),rm -rf $(notdir $(nexe)); ln -s $(nexe);) |
407 | 407 |
408 %.pexe : %.nonfinal.pexe | 408 %.pexe : %.nonfinal.pexe |
409 $(SB_FINALIZE) -o $@ $< | 409 $(SB_FINALIZE) -o $@ $< |
410 | 410 |
411 .PHONY: all compile_only make_symlink runtime bloat sb docs help \ | 411 .PHONY: all compile_only make_symlink runtime bloat sb docs help \ |
412 help-check-lit help-check-xtest exists-nonsfi-x8632 \ | 412 help-check-lit help-check-xtest exists-nonsfi-x8632 \ |
413 exists-nonsfi-arm32 exists-sbtc exists-spec | 413 exists-nonsfi-arm32 exists-nonsfi-mips32 exists-sbtc exists-spec |
Jim Stichnoth
2016/06/22 19:14:16
I'm not sure we should bother with the "nonsfi" fe
| |
414 | 414 |
415 compile_only: $(OBJS) | 415 compile_only: $(OBJS) |
416 | 416 |
417 V8_LIBDIR=$(V8_DIR)/out/native/lib.target | 417 V8_LIBDIR=$(V8_DIR)/out/native/lib.target |
418 | 418 |
419 ifdef WASM | 419 ifdef WASM |
420 V8_LIBS := \ | 420 V8_LIBS := \ |
421 $(V8_LIBDIR)/libv8.so \ | 421 $(V8_LIBDIR)/libv8.so \ |
422 $(V8_LIBDIR)/libicuuc.so \ | 422 $(V8_LIBDIR)/libicuuc.so \ |
423 $(V8_LIBDIR)/libicui18n.so | 423 $(V8_LIBDIR)/libicui18n.so |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
524 check-lit: $(OBJDIR)/pnacl-sz make_symlink | 524 check-lit: $(OBJDIR)/pnacl-sz make_symlink |
525 PNACL_BIN_PATH=$(PNACL_BIN_PATH) \ | 525 PNACL_BIN_PATH=$(PNACL_BIN_PATH) \ |
526 $(LLVM_SRC_PATH)/utils/lit/lit.py -sv $(CHECK_LIT_TESTS) \ | 526 $(LLVM_SRC_PATH)/utils/lit/lit.py -sv $(CHECK_LIT_TESTS) \ |
527 $(FORCEASM_LIT_TEST_EXCLUDES) $(FORCEASM_LIT_PARAM) | 527 $(FORCEASM_LIT_TEST_EXCLUDES) $(FORCEASM_LIT_PARAM) |
528 | 528 |
529 ifdef MINIMAL | 529 ifdef MINIMAL |
530 check-xtest check-xtest-lite: $(OBJDIR)/pnacl-sz make_symlink runtime | 530 check-xtest check-xtest-lite: $(OBJDIR)/pnacl-sz make_symlink runtime |
531 @echo "Crosstests disabled, minimal build" | 531 @echo "Crosstests disabled, minimal build" |
532 else | 532 else |
533 check-xtest: $(OBJDIR)/pnacl-sz make_symlink runtime \ | 533 check-xtest: $(OBJDIR)/pnacl-sz make_symlink runtime \ |
534 exists-nonsfi-x8632 exists-nonsfi-arm32 crosstest/test_arith_ll.ll | 534 exists-nonsfi-x8632 exists-nonsfi-arm32 exists-nonsfi-mips32 crosstest/test_ar ith_ll.ll |
535 # Do all native/sse2 tests, but only test_vector_ops for native/sse4.1. | 535 # Do all native/sse2 tests, but only test_vector_ops for native/sse4.1. |
536 # For (slow) sandboxed tests, limit to Om1/sse4.1. | 536 # For (slow) sandboxed tests, limit to Om1/sse4.1. |
537 # run.py (used to run the sandboxed xtests) does not support | 537 # run.py (used to run the sandboxed xtests) does not support |
538 # specifying -cpu cortex-a15 to qemu, hence we disable the | 538 # specifying -cpu cortex-a15 to qemu, hence we disable the |
539 # hwdiv-arm tests. | 539 # hwdiv-arm tests. |
540 ./pydir/crosstest_generator.py -v --lit \ | 540 ./pydir/crosstest_generator.py -v --lit \ |
541 --toolchain-root $(TOOLCHAIN_ROOT) \ | 541 --toolchain-root $(TOOLCHAIN_ROOT) \ |
542 $(FORCEASM_FLAG) \ | 542 $(FORCEASM_FLAG) \ |
543 $(FORCEASM_XTEST_EXCLUDES) \ | 543 $(FORCEASM_XTEST_EXCLUDES) \ |
544 -i x8632,native,sse2 \ | 544 -i x8632,native,sse2 \ |
545 -i x8632,native,sse4.1,test_vector_ops \ | 545 -i x8632,native,sse4.1,test_vector_ops \ |
546 -i x8632,sandbox,sse4.1,Om1 \ | 546 -i x8632,sandbox,sse4.1,Om1 \ |
547 -i x8632,nonsfi,sse2,O2 \ | 547 -i x8632,nonsfi,sse2,O2 \ |
548 -i x8664,native,sse2 \ | 548 -i x8664,native,sse2 \ |
549 -i x8664,native,sse4.1,test_vector_ops \ | 549 -i x8664,native,sse4.1,test_vector_ops \ |
550 -i x8664,sandbox,sse4.1,Om1 \ | 550 -i x8664,sandbox,sse4.1,Om1 \ |
551 -i arm32 \ | 551 -i arm32 \ |
552 -i mips32 \ | |
Jim Stichnoth
2016/06/22 19:14:16
I don't think any of the MIPS cross tests are read
| |
553 -i mips32,native \ | |
552 -e arm32,sandbox,hwdiv-arm | 554 -e arm32,sandbox,hwdiv-arm |
553 PNACL_BIN_PATH=$(PNACL_BIN_PATH) \ | 555 PNACL_BIN_PATH=$(PNACL_BIN_PATH) \ |
554 $(LLVM_SRC_PATH)/utils/lit/lit.py -sv $(CHECK_XTEST_TESTS) | 556 $(LLVM_SRC_PATH)/utils/lit/lit.py -sv $(CHECK_XTEST_TESTS) |
555 check-xtest-lite: $(OBJDIR)/pnacl-sz make_symlink runtime \ | 557 check-xtest-lite: $(OBJDIR)/pnacl-sz make_symlink runtime \ |
556 exists-nonsfi-x8632 exists-nonsfi-arm32 crosstest/test_arith_ll.ll | 558 exists-nonsfi-x8632 exists-nonsfi-arm32 exists-nonsfi-mips32 crosstest/test_ar ith_ll.ll |
557 # Do all native/sse2/neon tests, which are relatively fast. | 559 # Do all native/sse2/neon tests, which are relatively fast. |
558 # Limit to test_global+mem_intrin for sandbox+nonsfi because sandbox and | 560 # Limit to test_global+mem_intrin for sandbox+nonsfi because sandbox and |
559 # nonsfi builds are slow, and test_global and mem_intrin are the most | 561 # nonsfi builds are slow, and test_global and mem_intrin are the most |
560 # common sources of problems. | 562 # common sources of problems. |
561 ./pydir/crosstest_generator.py -v --lit \ | 563 ./pydir/crosstest_generator.py -v --lit \ |
562 --toolchain-root $(TOOLCHAIN_ROOT) \ | 564 --toolchain-root $(TOOLCHAIN_ROOT) \ |
563 $(FORCEASM_FLAG) \ | 565 $(FORCEASM_FLAG) \ |
564 $(FORCEASM_XTEST_EXCLUDES) \ | 566 $(FORCEASM_XTEST_EXCLUDES) \ |
565 -i x8632,native,sse2,O2 \ | 567 -i x8632,native,sse2,O2 \ |
566 -i x8664,native,sse2,O2 \ | 568 -i x8664,native,sse2,O2 \ |
(...skipping 30 matching lines...) Expand all Loading... | |
597 ifeq ($(TARGET),x8664) | 599 ifeq ($(TARGET),x8664) |
598 TARGETFLAG=x8664 | 600 TARGETFLAG=x8664 |
599 SETUP=SetupGccX8664Opt | 601 SETUP=SetupGccX8664Opt |
600 SPEC := --filetype=obj | 602 SPEC := --filetype=obj |
601 endif | 603 endif |
602 ifeq ($(TARGET),arm32) | 604 ifeq ($(TARGET),arm32) |
603 TARGETFLAG=arm32 | 605 TARGETFLAG=arm32 |
604 SETUP=SetupGccArmOpt | 606 SETUP=SetupGccArmOpt |
605 SPEC := --filetype=obj | 607 SPEC := --filetype=obj |
606 endif | 608 endif |
609 ifeq ($(TARGET),mips32) | |
610 TARGETFLAG=mips32 | |
611 SETUP=SetupGccMipsOpt | |
612 SPEC := --filetype=obj | |
613 endif | |
607 SPECFLAGS := -O2 | 614 SPECFLAGS := -O2 |
608 SPECRUN := --run | 615 SPECRUN := --run |
609 %.spec2k: % $(OBJDIR)/pnacl-sz make_symlink runtime | 616 %.spec2k: % $(OBJDIR)/pnacl-sz make_symlink runtime |
610 ./pydir/szbuild_spec2k.py -v \ | 617 ./pydir/szbuild_spec2k.py -v \ |
611 $(SPECFLAGS) --target=$(TARGETFLAG) $(SPEC) $< $(SPECRUN) | 618 $(SPECFLAGS) --target=$(TARGETFLAG) $(SPEC) $< $(SPECRUN) |
612 | 619 |
613 check-spec: exists-spec $(ALLSPEC:=.spec2k) | 620 check-spec: exists-spec $(ALLSPEC:=.spec2k) |
614 | 621 |
615 check: check-lit check-unit check-xtest | 622 check: check-lit check-unit check-xtest |
616 | 623 |
624 NONSFI_LOADER_MIPS32 =\ | |
625 $(NACL_ROOT)/scons-out/opt-linux-mips32/obj/src/nonsfi/loader/nonsfi_loader | |
626 | |
617 NONSFI_LOADER_X8632 = \ | 627 NONSFI_LOADER_X8632 = \ |
618 $(NACL_ROOT)/scons-out/opt-linux-x86-32/obj/src/nonsfi/loader/nonsfi_loader | 628 $(NACL_ROOT)/scons-out/opt-linux-x86-32/obj/src/nonsfi/loader/nonsfi_loader |
619 NONSFI_LOADER_ARM32 = \ | 629 NONSFI_LOADER_ARM32 = \ |
620 $(NACL_ROOT)/scons-out/opt-linux-arm/obj/src/nonsfi/loader/nonsfi_loader | 630 $(NACL_ROOT)/scons-out/opt-linux-arm/obj/src/nonsfi/loader/nonsfi_loader |
621 SBTC_LIBFILE = $(SB_LLVM_PATH)/lib/libLLVMSupport.a | 631 SBTC_LIBFILE = $(SB_LLVM_PATH)/lib/libLLVMSupport.a |
622 SPEC_SAMPLE_PEXE = $(NACL_ROOT)/tests/spec2k/176.gcc/gcc.opt.stripped.pexe | 632 SPEC_SAMPLE_PEXE = $(NACL_ROOT)/tests/spec2k/176.gcc/gcc.opt.stripped.pexe |
623 | 633 |
624 exists-nonsfi-x8632: | 634 exists-nonsfi-x8632: |
625 @if [ ! -f $(NONSFI_LOADER_X8632) ] ; then \ | 635 @if [ ! -f $(NONSFI_LOADER_X8632) ] ; then \ |
626 echo "Missing file $(NONSFI_LOADER_X8632)"; \ | 636 echo "Missing file $(NONSFI_LOADER_X8632)"; \ |
627 echo "Consider running './scons nonsfi_loader'" \ | 637 echo "Consider running './scons nonsfi_loader'" \ |
628 "in the native_client directory."; \ | 638 "in the native_client directory."; \ |
629 exit 1 ; \ | 639 exit 1 ; \ |
630 fi | 640 fi |
631 | 641 |
632 exists-nonsfi-arm32: | 642 exists-nonsfi-arm32: |
633 @if [ ! -f $(NONSFI_LOADER_ARM32) ] ; then \ | 643 @if [ ! -f $(NONSFI_LOADER_ARM32) ] ; then \ |
634 echo "Missing file $(NONSFI_LOADER_ARM32)"; \ | 644 echo "Missing file $(NONSFI_LOADER_ARM32)"; \ |
635 echo "Consider running './scons platform=arm nonsfi_loader'" \ | 645 echo "Consider running './scons platform=arm nonsfi_loader'" \ |
636 "in the native_client directory."; \ | 646 "in the native_client directory."; \ |
637 exit 1 ; \ | 647 exit 1 ; \ |
638 fi | 648 fi |
639 | 649 |
650 exists-nonsfi-mips32: | |
651 @if [ ! -f $(NONSFI_LOADER_MIPS32) ] ; then \ | |
652 echo "Missing file $(NONSFI_LOADER_MIPS32)"; \ | |
653 echo "Consider running './scons platform=mips nonsfi_loader'" \ | |
654 "in the native_client directory."; \ | |
655 exit 1 ; \ | |
656 fi | |
657 | |
640 exists-sbtc: | 658 exists-sbtc: |
641 @if [ ! -f $(SBTC_LIBFILE) ] ; then \ | 659 @if [ ! -f $(SBTC_LIBFILE) ] ; then \ |
642 echo "Missing file $(SBTC_LIBFILE)"; \ | 660 echo "Missing file $(SBTC_LIBFILE)"; \ |
643 echo "Consider running 'toolchain_build_pnacl.py --build-sbtc'."; \ | 661 echo "Consider running 'toolchain_build_pnacl.py --build-sbtc'."; \ |
644 exit 1 ; \ | 662 exit 1 ; \ |
645 fi | 663 fi |
646 | 664 |
647 exists-spec: | 665 exists-spec: |
648 @if [ ! -f $(SPEC_SAMPLE_PEXE) ] ; then \ | 666 @if [ ! -f $(SPEC_SAMPLE_PEXE) ] ; then \ |
649 echo "Missing file $(SPEC_SAMPLE_PEXE)"; \ | 667 echo "Missing file $(SPEC_SAMPLE_PEXE)"; \ |
650 echo "Consider running" \ | 668 echo "Consider running" \ |
651 "'./run_all.sh BuildBenchmarks 0 SetupPnaclX8632Opt'" \ | 669 "'./run_all.sh BuildBenchmarks 0 SetupPnaclX8632Opt'" \ |
652 "in the native_client/tests/spec2k directory."; \ | 670 "in the native_client/tests/spec2k directory."; \ |
653 exit 1 ; \ | 671 exit 1 ; \ |
654 fi | 672 fi |
655 | 673 |
656 check-presubmit presubmit: exists-nonsfi-x8632 exists-nonsfi-arm32 \ | 674 check-presubmit presubmit: exists-nonsfi-x8632 exists-nonsfi-arm32 \ |
657 exists-sbtc exists-spec | 675 exists-nonsfi-mips32 exists-sbtc exists-spec |
658 # Make sure clang-format gets run. | 676 # Make sure clang-format gets run. |
659 +make -f Makefile.standalone format | 677 +make -f Makefile.standalone format |
660 # Verify MINIMAL build, plus proper usage of REQUIRES in lit tests. | 678 # Verify MINIMAL build, plus proper usage of REQUIRES in lit tests. |
661 +make -f Makefile.standalone \ | 679 +make -f Makefile.standalone \ |
662 MINIMAL=1 check | 680 MINIMAL=1 check |
663 # Check that there are no g++ build errors or warnings. | 681 # Check that there are no g++ build errors or warnings. |
664 +make -f Makefile.standalone \ | 682 +make -f Makefile.standalone \ |
665 GPLUSPLUS=1 compile_only | 683 GPLUSPLUS=1 compile_only |
666 # Check the x86 assembler unit tests. | 684 # Check the x86 assembler unit tests. |
667 +make -f Makefile.standalone \ | 685 +make -f Makefile.standalone \ |
(...skipping 29 matching lines...) Expand all Loading... | |
697 +make -f Makefile.standalone \ | 715 +make -f Makefile.standalone \ |
698 TARGET=arm32 SPECFLAGS='-Om1' SPECRUN= check-spec | 716 TARGET=arm32 SPECFLAGS='-Om1' SPECRUN= check-spec |
699 # Run a few spec2k tests for arm32 using qemu. Keep the list sorted in | 717 # Run a few spec2k tests for arm32 using qemu. Keep the list sorted in |
700 # roughly reverse order of runtime. | 718 # roughly reverse order of runtime. |
701 +make -f Makefile.standalone \ | 719 +make -f Makefile.standalone \ |
702 TARGET=arm32 ALLSPEC='252.eon 254.gap 176.gcc 181.mcf' check-spec | 720 TARGET=arm32 ALLSPEC='252.eon 254.gap 176.gcc 181.mcf' check-spec |
703 # Provide validation of user awesomeness! | 721 # Provide validation of user awesomeness! |
704 echo Success | 722 echo Success |
705 | 723 |
706 presubmit-lite: exists-nonsfi-x8632 exists-nonsfi-arm32 \ | 724 presubmit-lite: exists-nonsfi-x8632 exists-nonsfi-arm32 \ |
707 exists-sbtc exists-spec | 725 exists-nonsfi-mips32 exists-sbtc exists-spec |
708 # Make sure clang-format gets run. | 726 # Make sure clang-format gets run. |
709 +make -f Makefile.standalone format | 727 +make -f Makefile.standalone format |
710 # Verify MINIMAL build, plus proper usage of REQUIRES in lit tests. | 728 # Verify MINIMAL build, plus proper usage of REQUIRES in lit tests. |
711 +make -f Makefile.standalone \ | 729 +make -f Makefile.standalone \ |
712 MINIMAL=1 check sb-lite | 730 MINIMAL=1 check sb-lite |
713 # Check that there are no g++ build errors or warnings. | 731 # Check that there are no g++ build errors or warnings. |
714 +make -f Makefile.standalone \ | 732 +make -f Makefile.standalone \ |
715 GPLUSPLUS=1 compile_only | 733 GPLUSPLUS=1 compile_only |
716 # Run lit tests, cross tests, unit tests, and spec2k/x86-32. | 734 # Run lit tests, cross tests, unit tests, and spec2k/x86-32. |
717 +make -f Makefile.standalone \ | 735 +make -f Makefile.standalone \ |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
782 | 800 |
783 help-check-xtest: | 801 help-check-xtest: |
784 @cat Makefile.standalone-help/check-xtest.txt | 802 @cat Makefile.standalone-help/check-xtest.txt |
785 | 803 |
786 clean: | 804 clean: |
787 rm -rf pnacl-sz *.o $(foreach nexe,$(NEXES),$(notdir $(nexe))) \ | 805 rm -rf pnacl-sz *.o $(foreach nexe,$(NEXES),$(notdir $(nexe))) \ |
788 $(OBJDIR) $(SB_OBJDIR) $(SBB_OBJDIR) build/*.bloat.json | 806 $(OBJDIR) $(SB_OBJDIR) $(SBB_OBJDIR) build/*.bloat.json |
789 | 807 |
790 clean-all: clean | 808 clean-all: clean |
791 rm -rf build/ crosstest/Output/ | 809 rm -rf build/ crosstest/Output/ |
OLD | NEW |