Commit Graph

2893 Commits

Author SHA1 Message Date
Muhammad Bassiouni
cfddb401db [libc][math] Refactor acos implementation to header-only in src/__support/math folder. (#148409)
Part of #147386

in preparation for:
https://discourse.llvm.org/t/rfc-make-clang-builtin-math-functions-constexpr-with-llvm-libc-to-support-c-23-constexpr-math-functions/86450
2025-07-19 05:21:34 +03:00
Muhammad Bassiouni
7e0ae019f8 [libc][math] Refactor exp10f16 implementation to header-only in src/__support/math folder. (#148408)
Part of #147386

in preparation for:
https://discourse.llvm.org/t/rfc-make-clang-builtin-math-functions-constexpr-with-llvm-libc-to-support-c-23-constexpr-math-functions/86450
2025-07-18 20:00:04 +03:00
Muhammad Bassiouni
b8bc3ff9be [libc][math] Refactor exp10f implementation to header-only in src/__support/math folder. (#148405)
Part of #147386

in preparation for:
https://discourse.llvm.org/t/rfc-make-clang-builtin-math-functions-constexpr-with-llvm-libc-to-support-c-23-constexpr-math-functions/86450
2025-07-17 20:25:00 +03:00
Guillaume Chatelet
e0cce5cdcb [libc] Improve Cortex memset and memcpy functions (#149044)
The code for `memcpy` is the same as in #148204 but it fixes the build
bot error by using `static_assert(cpp::always_false<decltype(access)>)`
instead of `static_assert(false)` (older compilers fails on
`static_assert(false)` in `constexpr` `else` bodies).

The code for `memset` is new and vastly improves performance over the
current byte per byte implementation.

Both `memset` and `memcpy` implementations use prefetching for sizes >=
64. This lowers a bit the performance for sizes between 64 and 256 but
improves throughput for greater sizes.
2025-07-17 10:15:43 +02:00
Muhammad Bassiouni
3a6ef8b359 [libc][math] Refactor exp10 implementation to header-only in src/__support/math folder. (#148400)
Part of #147386

in preparation for:
https://discourse.llvm.org/t/rfc-make-clang-builtin-math-functions-constexpr-with-llvm-libc-to-support-c-23-constexpr-math-functions/86450
2025-07-16 22:48:29 +03:00
Augie Fackler
d9190f8141 [bazel] run buildifier on mlir/BUILD.bazel
This reorders a couple of deps lists, but seems worth doing.
2025-07-16 10:48:45 -04:00
Augie Fackler
7d0a81c508 [bazel] update mlir BUILD files for fc114e4d93 2025-07-16 10:47:21 -04:00
Augie Fackler
a944e861f9 [bazel] update for 3e4153c97b 2025-07-16 10:16:16 -04:00
Guillaume Chatelet
999a8fb812 Revert "[libc][NFC] refactor Cortex memcpy code" (#149035)
Reverts llvm/llvm-project#148204

`libc-arm32-qemu-debian-dbg` is failing, reverting and investigating
2025-07-16 10:29:11 +02:00
Guillaume Chatelet
7c69c3b0ba [libc][NFC] refactor Cortex memcpy code (#148204)
This patch is in preparation for the Cortex `memset` implementation.
It improves the codegen by generating a prefetch for large sizes.
2025-07-16 10:06:18 +02:00
Jordan Rupprecht
c3dde3cf84 [bazel] Add tanpif rules after #147192 (#148909) 2025-07-15 12:50:33 -05:00
Muhammad Bassiouni
d969ec9422 [libc][math] Refactor exp implementation to header-only in src/__support/math folder. (#148761)
- **[libc][math] Refactor exp implementation to header-only in
src/__support/math folder.**
- **Reapply "[libc][math] Refactor exp implementation to header-only in
src/__support/math folder." (#148668)**
2025-07-15 12:10:08 -04:00
Walter Lee
6862afa008 [mlir][bazel] Fix 9609655 2025-07-14 13:34:19 -04:00
lntue
f4630baaa2 Revert "[libc][math] Refactor exp implementation to header-only in src/__support/math folder." (#148668)
Reverts llvm/llvm-project#148091
Full build bots are failing.
2025-07-14 12:46:26 -04:00
Muhammad Bassiouni
a76dfde936 [libc][math] Refactor exp implementation to header-only in src/__support/math folder. (#148091)
Part of #147386

in preparation for:
https://discourse.llvm.org/t/rfc-make-clang-builtin-math-functions-constexpr-with-llvm-libc-to-support-c-23-constexpr-math-functions/86450
2025-07-14 12:21:27 -04:00
Yi Zhang
96096550a1 [bazel] Add targets for transform.tune python extension (#148656) 2025-07-14 12:19:32 -04:00
Muhammad Bassiouni
cfcda5d0ff [libc][math] Refactor ldexpf implementation to header-only in src/__support/math folder (#147906)
Part of #147386

in preparation for:
https://discourse.llvm.org/t/rfc-make-clang-builtin-math-functions-constexpr-with-llvm-libc-to-support-c-23-constexpr-math-functions/86450

Please merge #147901 first

@lntue
2025-07-14 11:35:53 -04:00
Muhammad Bassiouni
074218dd10 [libc][math] Refactor ldexpf16 implementation to header-only in src/__support/math folder. (#147901)
Part of #147386

in preparation for:
https://discourse.llvm.org/t/rfc-make-clang-builtin-math-functions-constexpr-with-llvm-libc-to-support-c-23-constexpr-math-functions/86450

Please merge #147895 first
2025-07-14 11:00:01 -04:00
Muhammad Bassiouni
0ad2574de7 [libc][math] Refactor ldexpf128 implementation to header-only in src/__support/math folder. (#147895)
Part of #147386

in preparation for:
https://discourse.llvm.org/t/rfc-make-clang-builtin-math-functions-constexpr-with-llvm-libc-to-support-c-23-constexpr-math-functions/86450
2025-07-14 10:10:49 -04:00
Walter Lee
7e03c46624 [mlir][bazel] Port 0a34309 2025-07-14 09:26:33 -04:00
Muhammad Bassiouni
d06e9ce1dd [libc][math] Refactor frexpf implementation to header-only in src/__support/math folder. (#147893)
Part of #147386

in preparation for:
https://discourse.llvm.org/t/rfc-make-clang-builtin-math-functions-constexpr-with-llvm-libc-to-support-c-23-constexpr-math-functions/86450
2025-07-12 11:08:58 -04:00
Muhammad Bassiouni
395643e60b [libc][math] Refactor frexpf16 implementation to header-only in src/__support/math folder. (#147889)
Part of #147386

in preparation for:
https://discourse.llvm.org/t/rfc-make-clang-builtin-math-functions-constexpr-with-llvm-libc-to-support-c-23-constexpr-math-functions/86450
2025-07-12 00:48:01 -04:00
Muhammad Bassiouni
af6500d14c [libc][math] Refactor frexpf128 implementation to header-only in src/… (#147822)
Part of #147386 

in preparation for:
https://discourse.llvm.org/t/rfc-make-clang-builtin-math-functions-constexpr-with-llvm-libc-to-support-c-23-constexpr-math-functions/86450
2025-07-11 22:59:09 -04:00
quanwanandy
ba0df98aa9 Fix build for 0a34309 (#148314) 2025-07-11 16:35:51 -07:00
NAKAMURA Takumi
b8d21bf63b [bazel] Turn on EXPERIMENTAL_KEY_INSTRUCTIONS
It has been introduced in #131344 and turned on at #144324
2025-07-11 17:35:46 +09:00
Muhammad Bassiouni
c25a5e08ba [libc][math] Refactor expf16 implementation to header-only in src/__support/math folder. (#147428)
Part of #147386

in preparation for:
https://discourse.llvm.org/t/rfc-make-clang-builtin-math-functions-constexpr-with-llvm-libc-to-support-c-23-constexpr-math-functions/86450
2025-07-10 22:21:48 -04:00
Jorge Gorbe Moya
545b075a87 [bazel] Add missing dep after 61004b7eb5 2025-07-10 15:32:54 -07:00
James Y Knight
ce571c90a0 Revert "[bazel] Update after 24475409e4eac6fd60e2111424a4bef3452c8f21"
This reverts commit f71b188fbb.

The corresponding commit was reverted by fa74df38ad.
2025-07-10 13:58:17 -04:00
Christian Sigg
361a659796 [mlir][bazel] Port ddf9b91 2025-07-10 11:45:04 +02:00
Christian Sigg
96e4b50ffe [llvm][bazel] Port 7f3afab 2025-07-10 10:55:36 +02:00
Christian Sigg
2e38beebcf [libc][bazel] Port bb7cea0 2025-07-10 10:36:10 +02:00
Vincent Lee
03b0ae8da8 [mlgo-utils] Create symlinked entrypoints in root directory (#146981)
These scripts belong in the `mlgo-utils` directory when directly used
with python3. But since they are also used to package with pip, symlink
the entrypoint scripts to mlgo-utils directory. Adjust the bazel paths
to account for this as well. This loosely follows the same structure as lit.

Verified that I was also able to build the package successfully and use
the script.
2025-07-09 16:57:20 -07:00
sribee8
d5436b0b95 [libc] wcslcat implementation (#146588)
implemented wcslcat and tests.

---------

Co-authored-by: Sriya Pratipati <sriyap@google.com>
2025-07-09 23:54:03 +00:00
sribee8
16f046281b [libc] wcslcpy implementation (#146571)
Implemented wcslcpy and tests.

---------

Co-authored-by: Sriya Pratipati <sriyap@google.com>
2025-07-09 21:17:16 +00:00
James Y Knight
c57fe2f6ca [bazel] Update after 0580563299 2025-07-09 13:37:21 -04:00
James Y Knight
820a48523b [bazel] Update after 6f291cb099 2025-07-09 12:10:25 -04:00
James Y Knight
e7ab9209b1 [bazel] Fix after db03408b24 2025-07-09 12:10:24 -04:00
James Y Knight
f71b188fbb [bazel] Update after 24475409e4 2025-07-09 12:10:24 -04:00
James Y Knight
8438c7ddbd [bazel] Update after db7888ca9a 2025-07-09 11:41:55 -04:00
DeanSturtevant1
179107997c [bazel] Update after db7888ca9a (#146732) (#147726) 2025-07-09 11:06:35 -04:00
DeanSturtevant1
cdf5707bcb [bazel] Update after 0580563299 (#147597) 2025-07-08 17:01:07 -04:00
Christian Sigg
18991f4654 [llvm][bazel] Port commit 5088231. 2025-07-08 08:23:27 +02:00
DeanSturtevant1
ff600da8be Add ":MathDialect" as a dep of "GPUDialect". Fixes bazel build. (#147376)
Error was:
external/llvm-project/mlir/lib/Dialect/GPU/IR/GPUDialect.cpp:17:10:
fatal error: 'mlir/Dialect/Math/IR/Math.h' file not found
   17 | #include "mlir/Dialect/Math/IR/Math.h"
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
2025-07-07 12:24:04 -07:00
Nicolas Vasilache
c30b5b1549 [mlir][GPU][transform] Add gpu_to_rocdl conversion pattern (#146962)
Co-authored-by: Son Tuan Vu <vuson@google.com>
2025-07-07 18:34:09 +02:00
Christian Sigg
e430581e66 [libc][bazel] Add missing header dependencies. 2025-07-07 10:16:24 +02:00
Benjamin Kramer
9d994d1c08 [bazel] Port b9b2661f72 2025-07-05 13:58:54 +02:00
Benjamin Kramer
c7d3b81896 [bazel] Port 0ceb0c377a 2025-07-04 10:27:02 +02:00
Jorge Gorbe Moya
dfc5987fac [bazel] Add missing dep after 242996efee 2025-07-02 10:52:38 -07:00
Benjamin Kramer
13e6ea7b4c [bazel] Add missing dependency for 08cf6ae537 2025-07-01 18:21:45 +02:00
sribee8
47e28d9cd1 [libc] wcscspn implementation (#146158)
Implemented wcscspn and tests.

---------

Co-authored-by: Sriya Pratipati <sriyap@google.com>
2025-07-01 15:56:09 +00:00