| Age | Commit message (Collapse) | Author |
|
After #115084 the 80 bit long double tests error if sizeof(long double)
isn't 96 or 128 bits. This caused failures in long double is double
systems (since long double is 64 bits) so I've disabled the 80 bit long
double tests on systems that don't use them.
|
|
`long double` is haunted on most architectures, but it is especially so on
i386-linux-gnu. While have 80b of significant data, on i386-linux-gnu this type
has 96b of storage.
Fixes for supporting printf family of conversions for `long double` on
i386-linux-gnu. This allows the libc-stdlib-tests and libc_stdio_unittests
ninja target tests to pass on i386-linux-gnu.
Fixes: #110894
Link: #93709
Co-authored-by: Michael Jones <michaelrj@google.com>
|
|
The struct Sign should be in the correct namespace. Also update the
various tests that use it.
|
|
target (#104676)
This PR first adds osutils for Windows, and changes some libc code to
make libc and its tests build on the Windows target. It then temporarily
disables some libc tests that are currently problematic on Windows.
Specifically, the changes besides the addition of osutils include:
- Macro `LIBC_TYPES_HAS_FLOAT16` is disabled on Windows. `clang-cl`
generates calls to functions in `compiler-rt` to handle float16
arithmetic and these functions are currently not linked in on Windows.
- Macro `LIBC_TYPES_HAS_INT128` is disabled on Windows.
- The invocation to `::aligned_malloc` is changed to an invocation to
`::_aligned_malloc`.
- The following unit tests are temporarily disabled because they
currently fail on Windows:
- `test.src.__support.big_int_test`
- `test.src.__support.arg_list_test`
- `test.src.fenv.getenv_and_setenv_test`
- Tests involving `__m128i`, `__m256i`, and `__m512i` in
`test.src.string.memory_utils.op_tests.cpp`
- `test_range_errors` in `libc/test/src/math/smoke/AddTest.h` and
`libc/test/src/math/smoke/SubTest.h`
|
|
Fixes #98709.
|
|
|
|
Summary:
Cleans up two warnings I get locally while building.
|
|
Note: This is a reland of #84035.
The standard specifies that it it UB to specialize the following traits:
- `std::is_integral`
- `std::is_unsigned`
- `std::make_unsigned`
- `std::make_signed`
This patch:
- Removes specializations for `BigInt`
- Transforms SFINAE for `bit.h` functions from template parameter to
return type (This makes specialization easier).
- Adds `BigInt` specialization for `bit.h` functions.
- Fixes code depending on previous specializations.
|
|
Umbrella bug #83182
|
|
(#83395)
Umbrella bug #83182
|
|
The FXBits class is what will be used to modify fixed point numbers on a
bit level. This patch adds a basic implementation as well as basic
tests.
|
|
constants (#81998)
- #81835
- Fix for platforms where uint64_t is not available
|
|
bit constants" (#81882)
Reverts llvm/llvm-project#81835
This is breaking arm32 which does not support 64 bit types.
|
|
constants (#81835)
This is a reland of #81746
|
|
constants." (#81771)
Reverts llvm/llvm-project#81746
|
|
(#81746)
|
|
constants (#81267)
Adds user defined literal to construct unsigned integer constants. This
is useful when constructing constants for non native C++ types like
`__uint128_t` or our custom `BigInt` type.
|
|
```
/usr/local/google/home/lntue/experiment/llvm/llvm-project/libc/test/src/__support/FPUtil/fpbits_test.cpp:268:2: warning: extra ';' outside of a function is incompatible with C++98 [-Wc++98-compat-extra-semi]
};
^
1 warning generated.
```
```
In file included from /usr/local/google/home/lntue/experiment/llvm/llvm-project/libc/test/src/sys/socket/linux/bind_test.cpp:17:
/usr/local/google/home/lntue/experiment/llvm/llvm-project/libc/test/UnitTest/Test.h:17:9: warning: 'libc_make_test_file_path' macro redefined [-Wmacro-redefined]
#define libc_make_test_file_path(file_name) (file_name)
^
/usr/local/google/home/lntue/experiment/llvm/llvm-project/libc/test/UnitTest/LibcTest.h:20:9: note: previous definition is here
#define libc_make_test_file_path(file_name) \
^
1 warning generated.
```
|
|
It is needed to provide correct rounding when building FPRep from
greater precision representations.
|
|
|
|
- [libc][NFC] Rename FPBits nan functions
- rename build_signaling_nan in signaling_nan
- rename build_quiet_nan to quiet_nan
|
|
This test is platform agnostic, it runs all tests on all architectures.
|
|
|
|
|
|
- reland #79113
- Fix aarch64 RISC-V build
|
|
Reverts llvm/llvm-project#79113
It broke aarch64 build bot machines.
|
|
This patch reduces the surface of `FPBits`.
|
|
(#78978)
Reland #78588
|
|
(#78974)
Reverts llvm/llvm-project#78588
|
|
|
|
Another patch is needed to cover `DyadicFloat` and `NormalFloat`
constructors.
|
|
(#78465)
- [reland] #78192
- [reland] #78447
- Turn `as` static function into a `to_storage_type` member function.
|
|
specialization" (#78457)
Reverts llvm/llvm-project#78447
This broke the gcc buildbot.
|
|
(#78447)
- [reland] #78192
- Make the implementation work when `__uint128_t` is not available on
the plaftorm.
|
|
(#78192)" (#78329)
This reverts commit fdbf255c96cb18bc1fb08fa7264446bcbbd5fbd0.
Causes build breakage on 32b arm (see reports:
https://github.com/llvm/llvm-project/pull/78192).
These are reproducible for the 32b arm baremetal target on x86 hosts as
well.
|
|
This patch removes the `FPBits` specialization for x86 Extended Precision by moving it up to `FPRep`.
It also introduces enums (`Exponent`, `BiasedExponent` and `Significand`) to represent the exponent and significant parts of the floating point numbers. These enums are used to construct and observe floating point representations.
Additionally, we remove `LongDoubleBits.h` that is now unnecessary.
|
|
|
|
According to [wikipedia](https://en.wikipedia.org/wiki/Exponent_bias)
the "biased exponent" is the encoded form that is always positive
whereas the unbiased form is the actual "real" exponent that can be
positive or negative.
`FPBits` seems to be using `unbiased_exponent` to describe the encoded
form (unsigned). This patch simply use `biased` instead of `unbiased`.
|
|
(#73948)
|
|
with copysignf128. (#71731)
|
|
up its constants return types. (#71298)
|
|
This is step 4 of
https://discourse.llvm.org/t/rfc-customizable-namespace-to-allow-testing-the-libc-when-the-system-libc-is-also-llvms-libc/73079
|
|
str method of FPBits class is only used for pretty printing its objects
in tests. It brings cpp::string dependency to FPBits class, which is not ideal
for embedded use case. We move str method to a free function in test utils and
remove this dependency of FPBits class.
Reviewed By: sivachandra
Differential Revision: https://reviews.llvm.org/D152607
|
|
We got build failures due to the handling here, explicitly set the type.
Reviewed By: sivachandra
Differential Revision: https://reviews.llvm.org/D150983
|
|
Unit tests for the str() method have also been added.
Previously, a separate test only helper function was being used by the
test matchers which has regressed over many cleanups. Moreover, being a
test only utility, it was not tested separately (and hence the
regression).
Reviewed By: michaelrj
Differential Revision: https://reviews.llvm.org/D150906
|