summaryrefslogtreecommitdiffstats
path: root/compiler-rt/test/builtins/CMakeLists.txt
Commit message (Collapse)AuthorAgeFilesLines
* [Builtins] Provide a mechanism to selectively disable tests based on whether ↵Dan Liew2019-10-171-0/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | an implementation is provided by a builtin library. Summary: If a platform removes some builtin implementations (e.g. via the Darwin-excludes mechanism) then this can lead to test failures because the test expects an implementation to be available. To solve this lit features are added for each configuration based on which sources are included in the builtin library. The features are of the form `librt_has_<name>` where `<name>` is the name of the source file with the file extension removed. This handles C and assembly sources. With the lit features in place it is possible to make certain tests require them. Example: ``` REQUIRES: librt_has_comparedf2 ``` All top-level tests in `test/builtins/Unit` (i.e. not under `arm`, `ppc`, and `riscv`) have been annotated with the appropriate `REQUIRES: librt_has_*` statement. rdar://problem/55520987 Reviewers: beanz, steven_wu, arphaman, dexonsmith, phosek, thakis Subscribers: mgorny, #sanitizers, llvm-commits Tags: #llvm, #sanitizers Differential Revision: https://reviews.llvm.org/D68064 llvm-svn: 375150
* compiler-rt/builtins: Make check-builtins run tests on macOS.Nico Weber2019-09-141-4/+8
| | | | | | Differential Revision: https://reviews.llvm.org/D66984 llvm-svn: 371926
* [compiler-rt] Rename lit.*.cfg.* -> lit.*.cfg.py.*Reid Kleckner2019-06-271-4/+4
| | | | | | | | | | | | | These lit configuration files are really Python source code. Using the .py file extension helps editors and tools use the correct language mode. LLVM and Clang already use this convention for lit configuration, this change simply applies it to all of compiler-rt. Reviewers: vitalybuka, dberris Differential Revision: https://reviews.llvm.org/D63658 llvm-svn: 364591
* Compile and test i128 math builtins for Win64Reid Kleckner2018-11-011-0/+10
| | | | | | | | | | | | | | | | | | | | | Summary: Windows has always been LLP64, not LP64, so the macros were incorrect. Check for _WIN64, since AArch64 sets that too. The tests have to be fixed up in two main ways: 1. Use 'ULL' suffixes to avoid sign extension when passing hex literals with the sign bit set to signed 128 arguments. Clang -fms-compatibility makes such hex literals signed, not unsigned. 2. Disable various tests for 80-bit long double interoperation with i128 values. Reviewers: joerg, mstorsjo Subscribers: javed.absar, kristof.beyls, hiraditya, aheejin, llvm-commits Differential Revision: https://reviews.llvm.org/D53918 llvm-svn: 345796
* [PATCH] [compiler-rt, RISCV] Support builtins for RISC-VShiva Chen2018-03-011-0/+5
| | | | | | | | | | | Summary: Support builtins for RISC-V, RV32 and RV64. Reviewers: asb, apazos, mgrang Differential Revision: https://reviews.llvm.org/D42958 llvm-svn: 326420
* [builtins] Get the builtins tests passing on WindowsReid Kleckner2017-04-071-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | Many things were broken: - We stopped building most builtins on Windows in r261432 for reasons that are not at all clear to me. This essentially reverts that patch. - Fix %librt to expand to clang_rt.builtins-$arch.lib on Windows instead of libclang_rt.builtins-$arch.a. - Fix memory protection tests (trampoline, enable executable, clear cache) on Windows. One issue was that the MSVC incremental linker generates ILT thunks for functions with external linkage, so memcpying the functions into the executable stack buffer wasn't working. You can't memcpy an RIP-relative jump without fixing up the offset. - Disable tests that rely on C99 complex library functions when using the MSVC CRT, which isn't compatible with clang's C99 _Complex. In theory, these could all be separate patches, but it would not green the tests, so let's try for it all at once. Hopefully this fixes the clang-x64-ninja-win7 bot. llvm-svn: 299780
* [Builtin] Unxfail tests for armhfWeiming Zhao2017-03-291-0/+5
| | | | | | | | | | | | | | | | | | | | | Summary: Originally, a few tests fail for armhf target due to: 1) COMPILER_RT_ARMHF_TARGET was not set when building the lib 2) COMPILER_RT_ABI should not be defined as `__attribute__((pcs("aapcs")))` for armhf when building for both lib and tests This address https://bugs.llvm.org//show_bug.cgi?id=32261 mulsc3_test.c is a newly exposed issue, which will be addressed separately. Reviewers: rengolin, compnerd Reviewed By: compnerd Subscribers: aemerson, llvm-commits, mgorny Differential Revision: https://reviews.llvm.org/D31448 llvm-svn: 298974
* Reland "[Compiler-rt][Builtins] Implement lit-test support (part 2 of 2)"Weiming Zhao2017-03-271-0/+20
| | | | | | | | | Re-land of r298714 which got reverted in r298868. It looks like the current lit tests won't run for Apple. Possible reason is the libname is different. (need to update the base_lib variable of lit.cfg) llvm-svn: 298892
* Revert "[Compiler-rt][Builtins] Implement lit-test support (part 2 of 2)"Juergen Ributzka2017-03-271-17/+0
| | | | | | This broke GreenDragon: http://lab.llvm.org:8080/green/job/clang-stage1-configure-RA_check/29505/consoleFull llvm-svn: 298868
* [Compiler-rt][Builtins] Implement lit-test support (part 2 of 2)Weiming Zhao2017-03-241-0/+17
| | | | | | | | | | | | | | Summary: Original r297566 (https://reviews.llvm.org/D30802) is splitted into two parts. This part adds CMakefile/lit.cfg support. Reviewers: rengolin, compnerd, jroelofs, erik.pilkington Subscribers: srhines, dberris, mgorny Differential Revision: https://reviews.llvm.org/D31259 llvm-svn: 298714
* Revert "[Builtin] Implement lit-test support"Weiming Zhao2017-03-111-16/+0
| | | | | | | Due to test failure of check-builtins for aarch64 and armhf. This reverts commit r297566. llvm-svn: 297569
* [Builtin] Implement lit-test supportWeiming Zhao2017-03-111-0/+16
| | | | | | | | | | | | | | | | | | | Summary: This patch implements a initial support of lit test for builtins. Unit/arm/call_apsr.S is updated to support thumb1. It also fixes a bug in arm/aeabi_uldivmod_test.c gcc_personality_test is XFAILED as the framework cannot handle it so far. cpu_model_test is also XFAILED for now as it is expected to return non-zero. Reviewers: rengolin, compnerd, jroelofs, erik.pilkington, arphaman Reviewed By: jroelofs Subscribers: jroelofs, aemerson, srhines, nemanjai, llvm-commits, mgorny Differential Revision: https://reviews.llvm.org/D30802 llvm-svn: 297566
* Reapply r297382: "[compiler-rt][builtins] Add __isOSVersionAtLeast()"Erik Pilkington2017-03-091-0/+15
| | | | | | Looks like the problem was a case-insensitive include of dispatch/dispatch.h. llvm-svn: 297392
* Revert "[compiler-rt][builtins] Add __isOSVersionAtLeast()"Erik Pilkington2017-03-091-15/+0
| | | | | | This reverts r297382, it was causing build failures. llvm-svn: 297388
* [compiler-rt][builtins] Add __isOSVersionAtLeast()Erik Pilkington2017-03-091-0/+15
This predicate compares the host's marketing OS version to one passed as argument. Currently, only darwin targets are supported. This is done by parsing the SystemVersion.plist file. Also added in this patch is some lit testing infrastructure for builtins, which previously had none. This part of the patch was written by Alex Lorenz (with some minor modifications). This patch is part of a feature I proposed here: http://lists.llvm.org/pipermail/cfe-dev/2016-July/049851.html Differential revision: https://reviews.llvm.org/D30136 llvm-svn: 297382
OpenPOWER on IntegriCloud