7781 lines · plain
1# This file is licensed under the Apache License v2.0 with LLVM Exceptions.2# See https://llvm.org/LICENSE.txt for license information.3# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception4 5# LLVM libc project.6load("@bazel_skylib//lib:selects.bzl", "selects")7load("@bazel_skylib//rules:common_settings.bzl", "string_flag")8load("@rules_python//python:defs.bzl", "py_binary")9load(10 ":libc_build_rules.bzl",11 "libc_function",12 "libc_generated_header",13 "libc_header_library",14 "libc_math_function",15 "libc_support_library",16)17load(":platforms.bzl", "PLATFORM_CPU_ARM64", "PLATFORM_CPU_X86_64")18 19package(20 default_visibility = ["//visibility:public"],21 features = [22 "parse_headers",23 "-use_header_modules",24 "-layering_check",25 ],26)27 28licenses(["notice"])29 30# A flag to pick which `mpfr` to use for math tests.31# Usage: `--@llvm-project//libc:mpfr=<disable|external|system>`.32# Flag documentation: https://bazel.build/extending/config33string_flag(34 name = "mpfr",35 build_setting_default = "external",36 values = [37 "disable", # Skip tests that need mpfr38 "external", # Build mpfr from source39 "system", # Use system mpfr (non hermetic)40 ],41)42 43config_setting(44 name = "mpfr_disable",45 flag_values = {":mpfr": "disable"},46)47 48config_setting(49 name = "mpfr_external",50 flag_values = {":mpfr": "external"},51)52 53config_setting(54 name = "mpfr_system",55 flag_values = {":mpfr": "system"},56)57 58# A flag to pick which `mpc` to use for math tests.59# Usage: `--@llvm-project//libc:mpc=<disable|external|system>`.60# Flag documentation: https://bazel.build/extending/config61string_flag(62 name = "mpc",63 build_setting_default = "external",64 values = [65 "disable", # Skip tests that need mpc66 "external", # Build mpc from source67 "system", # Use system mpc (non hermetic)68 ],69)70 71config_setting(72 name = "mpc_disable",73 flag_values = {":mpc": "disable"},74)75 76config_setting(77 name = "mpc_external",78 flag_values = {":mpc": "external"},79)80 81config_setting(82 name = "mpc_system",83 flag_values = {":mpc": "system"},84)85 86########################### Header Generation ##################################87 88py_binary(89 name = "hdrgen",90 srcs = glob(["utils/hdrgen/hdrgen/**/*.py"]),91 imports = ["utils/hdrgen"],92 main = "utils/hdrgen/hdrgen/main.py",93 deps = ["@pyyaml//:yaml"],94)95 96libc_generated_header(97 name = "include_stdbit_h",98 hdr = "staging/include/stdbit.h",99 other_srcs = ["include/stdbit.h.def"],100 yaml_template = "include/stdbit.yaml",101)102 103# Library containing all headers that can be transitively included by generated llvm-libc104# public headers (or by the unit tests).105libc_support_library(106 name = "public_headers_deps",107 textual_hdrs = [108 "include/__llvm-libc-common.h",109 ] + glob([110 "include/llvm-libc-types/**/*.h",111 "include/llvm-libc-macros/**/*.h",112 ]),113)114 115################################## Base Config #################################116 117libc_support_library(118 name = "__support_macros_config",119 hdrs = ["src/__support/macros/config.h"],120 deps = [121 "__support_macros_properties_architectures",122 "__support_macros_properties_compiler",123 ],124)125 126################################# Include Files ################################127 128libc_support_library(129 name = "llvm_libc_macros_complex_macros",130 hdrs = [131 "include/llvm-libc-macros/cfloat128-macros.h",132 "include/llvm-libc-macros/cfloat16-macros.h",133 "include/llvm-libc-macros/complex-macros.h",134 ],135 deps = [":llvm_libc_macros_float_macros"],136)137 138libc_support_library(139 name = "llvm_libc_macros_math_macros",140 hdrs = ["include/llvm-libc-macros/math-macros.h"],141 deps = [":llvm_libc_macros_limits_macros"],142)143 144libc_support_library(145 name = "llvm_libc_macros_limits_macros",146 hdrs = ["include/llvm-libc-macros/limits-macros.h"],147)148 149libc_support_library(150 name = "llvm_libc_macros_float_macros",151 hdrs = ["include/llvm-libc-macros/float-macros.h"],152)153 154libc_support_library(155 name = "llvm_libc_macros_float16_macros",156 hdrs = ["include/llvm-libc-macros/float16-macros.h"],157 deps = [":llvm_libc_types_float128"],158)159 160libc_support_library(161 name = "llvm_libc_macros_stdint_macros",162 hdrs = ["include/llvm-libc-macros/stdint-macros.h"],163)164 165libc_support_library(166 name = "llvm_libc_macros_stdfix_macros",167 hdrs = ["include/llvm-libc-macros/stdfix-macros.h"],168 deps = [":llvm_libc_macros_float_macros"],169)170 171libc_support_library(172 name = "llvm_libc_types_float128",173 hdrs = ["include/llvm-libc-types/float128.h"],174 deps = [":llvm_libc_macros_float_macros"],175)176 177libc_support_library(178 name = "llvm_libc_types_cfloat128",179 hdrs = ["include/llvm-libc-types/cfloat128.h"],180 deps = [181 ":llvm_libc_macros_complex_macros",182 ":llvm_libc_macros_float_macros",183 ],184)185 186libc_support_library(187 name = "llvm_libc_types_cfloat16",188 hdrs = ["include/llvm-libc-types/cfloat16.h"],189 deps = [":llvm_libc_macros_complex_macros"],190)191 192libc_support_library(193 name = "llvm_libc_macros_fcntl_macros",194 hdrs = ["include/llvm-libc-macros/linux/fcntl-macros.h"],195)196 197libc_support_library(198 name = "llvm_libc_types_size_t",199 hdrs = ["include/llvm-libc-types/size_t.h"],200)201 202########################### Macro Proxy Header Files ###########################203 204libc_support_library(205 name = "hdr_math_macros",206 hdrs = ["hdr/math_macros.h"],207)208 209libc_support_library(210 name = "hdr_fenv_macros",211 hdrs = ["hdr/fenv_macros.h"],212)213 214libc_support_library(215 name = "hdr_fcntl_macros",216 hdrs = ["hdr/fcntl_macros.h"],217 deps = [":hdr_fcntl_overlay"],218)219 220libc_support_library(221 name = "hdr_fcntl_overlay",222 hdrs = ["hdr/fcntl_overlay.h"],223)224 225libc_support_library(226 name = "hdr_signal_macros",227 hdrs = ["hdr/signal_macros.h"],228)229 230libc_support_library(231 name = "hdr_sys_epoll_macros",232 hdrs = ["hdr/sys_epoll_macros.h"],233)234 235libc_support_library(236 name = "hdr_errno_macros",237 hdrs = ["hdr/errno_macros.h"],238)239 240libc_support_library(241 name = "hdr_time_macros",242 hdrs = ["hdr/time_macros.h"],243)244 245libc_support_library(246 name = "hdr_float_macros",247 hdrs = ["hdr/float_macros.h"],248)249 250libc_support_library(251 name = "hdr_stdio_macros",252 hdrs = ["hdr/stdio_macros.h"],253 deps = [254 ":hdr_stdio_overlay",255 ],256)257 258libc_support_library(259 name = "hdr_unistd_macros",260 hdrs = ["hdr/unistd_macros.h"],261 deps = [262 ":hdr_unistd_overlay",263 ],264)265 266libc_support_library(267 name = "hdr_limits_macros",268 hdrs = ["hdr/limits_macros.h"],269)270 271libc_support_library(272 name = "hdr_stdio_overlay",273 hdrs = ["hdr/stdio_overlay.h"],274)275 276libc_support_library(277 name = "hdr_stdlib_macros",278 hdrs = ["hdr/stdlib_macros.h"],279 deps = [280 ":hdr_stdlib_overlay",281 ],282)283 284libc_support_library(285 name = "hdr_stdlib_overlay",286 hdrs = ["hdr/stdlib_overlay.h"],287)288 289libc_support_library(290 name = "hdr_unistd_overlay",291 hdrs = ["hdr/unistd_overlay.h"],292)293 294libc_support_library(295 name = "hdr_wchar_macros",296 hdrs = ["hdr/wchar_macros.h"],297 deps = [298 ":hdr_wchar_overlay",299 ],300)301 302libc_support_library(303 name = "hdr_wchar_overlay",304 hdrs = ["hdr/wchar_overlay.h"],305)306 307libc_support_library(308 name = "hdr_stdint_proxy",309 hdrs = ["hdr/stdint_proxy.h"],310)311 312############################ Type Proxy Header Files ###########################313 314libc_support_library(315 name = "func_aligned_alloc",316 hdrs = ["hdr/func/aligned_alloc.h"],317 deps = [":hdr_stdlib_overlay"],318)319 320libc_support_library(321 name = "func_free",322 hdrs = ["hdr/func/free.h"],323 deps = [":hdr_stdlib_overlay"],324)325 326libc_support_library(327 name = "func_malloc",328 hdrs = ["hdr/func/malloc.h"],329 deps = [":hdr_stdlib_overlay"],330)331 332libc_support_library(333 name = "func_realloc",334 hdrs = ["hdr/func/realloc.h"],335 deps = [":hdr_stdlib_overlay"],336)337 338libc_support_library(339 name = "types_clockid_t",340 hdrs = ["hdr/types/clockid_t.h"],341)342 343libc_support_library(344 name = "types_clock_t",345 hdrs = ["hdr/types/clock_t.h"],346)347 348libc_support_library(349 name = "types_div_t",350 hdrs = ["hdr/types/div_t.h"],351 deps = [":hdr_stdlib_overlay"],352)353 354libc_support_library(355 name = "types_fenv_t",356 hdrs = ["hdr/types/fenv_t.h"],357)358 359libc_support_library(360 name = "types_fexcept_t",361 hdrs = ["hdr/types/fexcept_t.h"],362)363 364libc_support_library(365 name = "types_ldiv_t",366 hdrs = ["hdr/types/ldiv_t.h"],367 deps = [":hdr_stdlib_overlay"],368)369 370libc_support_library(371 name = "types_lldiv_t",372 hdrs = ["hdr/types/lldiv_t.h"],373 deps = [":hdr_stdlib_overlay"],374)375 376libc_support_library(377 name = "types_mode_t",378 hdrs = ["hdr/types/mode_t.h"],379 deps = [":hdr_fcntl_overlay"],380)381 382libc_support_library(383 name = "types_sigset_t",384 hdrs = ["hdr/types/sigset_t.h"],385)386 387libc_support_library(388 name = "types_size_t",389 hdrs = ["hdr/types/size_t.h"],390)391 392libc_support_library(393 name = "types_struct_epoll_event",394 hdrs = ["hdr/types/struct_epoll_event.h"],395)396 397libc_support_library(398 name = "types_struct_f_owner_ex",399 hdrs = ["hdr/types/struct_f_owner_ex.h"],400 deps = [":hdr_fcntl_overlay"],401)402 403libc_support_library(404 name = "types_struct_flock",405 hdrs = ["hdr/types/struct_flock.h"],406 deps = [":hdr_fcntl_overlay"],407)408 409libc_support_library(410 name = "types_struct_flock64",411 hdrs = ["hdr/types/struct_flock64.h"],412 deps = [":hdr_fcntl_overlay"],413)414 415libc_support_library(416 name = "types_struct_timespec",417 hdrs = ["hdr/types/struct_timespec.h"],418)419 420libc_support_library(421 name = "types_time_t",422 hdrs = ["hdr/types/time_t.h"],423)424 425libc_support_library(426 name = "types_struct_timeval",427 hdrs = ["hdr/types/struct_timeval.h"],428)429 430libc_support_library(431 name = "types_struct_rlimit",432 hdrs = ["hdr/types/struct_rlimit.h"],433)434 435libc_support_library(436 name = "types_pid_t",437 hdrs = ["hdr/types/pid_t.h"],438)439 440libc_support_library(441 name = "types_uid_t",442 hdrs = ["hdr/types/uid_t.h"],443)444 445libc_support_library(446 name = "types_off_t",447 hdrs = ["hdr/types/off_t.h"],448 deps = [449 ":hdr_stdio_overlay",450 ],451)452 453libc_support_library(454 name = "types_FILE",455 hdrs = ["hdr/types/FILE.h"],456 deps = [457 ":hdr_stdio_overlay",458 ],459)460 461libc_support_library(462 name = "types_ssize_t",463 hdrs = ["hdr/types/ssize_t.h"],464)465 466libc_support_library(467 name = "types_socklen_t",468 hdrs = ["hdr/types/socklen_t.h"],469)470 471libc_support_library(472 name = "types_struct_sockaddr",473 hdrs = ["hdr/types/struct_sockaddr.h"],474)475 476libc_support_library(477 name = "types_struct_msghdr",478 hdrs = ["hdr/types/struct_msghdr.h"],479)480 481libc_support_library(482 name = "types_wchar_t",483 hdrs = ["hdr/types/wchar_t.h"],484 deps = [485 ":hdr_wchar_overlay",486 ],487)488 489libc_support_library(490 name = "types_wint_t",491 hdrs = ["hdr/types/wint_t.h"],492 deps = [493 ":hdr_wchar_overlay",494 ],495)496 497############################### Support libraries ##############################498 499libc_support_library(500 name = "__support_macros_properties_architectures",501 hdrs = ["src/__support/macros/properties/architectures.h"],502)503 504libc_support_library(505 name = "__support_macros_properties_compiler",506 hdrs = ["src/__support/macros/properties/compiler.h"],507)508 509libc_support_library(510 name = "__support_macros_properties_os",511 hdrs = ["src/__support/macros/properties/os.h"],512)513 514libc_support_library(515 name = "__support_macros_properties_complex_types",516 hdrs = ["src/__support/macros/properties/complex_types.h"],517 deps = [518 ":__support_macros_properties_types",519 ":hdr_stdint_proxy",520 ":llvm_libc_types_cfloat128",521 ":llvm_libc_types_cfloat16",522 ],523)524 525libc_support_library(526 name = "__support_macros_properties_types",527 hdrs = ["src/__support/macros/properties/types.h"],528 deps = [529 ":__support_macros_config",530 ":__support_macros_properties_architectures",531 ":__support_macros_properties_compiler",532 ":__support_macros_properties_cpu_features",533 ":__support_macros_properties_os",534 ":hdr_float_macros",535 ":hdr_stdint_proxy",536 ":llvm_libc_macros_float16_macros",537 ":llvm_libc_types_float128",538 ],539)540 541libc_support_library(542 name = "__support_macros_properties_cpu_features",543 hdrs = ["src/__support/macros/properties/cpu_features.h"],544 deps = [545 "__support_macros_properties_architectures",546 ],547)548 549libc_support_library(550 name = "__support_macros_attributes",551 hdrs = ["src/__support/macros/attributes.h"],552 deps = [553 ":__support_macros_config",554 ":__support_macros_properties_architectures",555 ],556)557 558libc_support_library(559 name = "__support_macros_optimization",560 hdrs = ["src/__support/macros/optimization.h"],561 deps = [562 ":__support_macros_attributes",563 ":__support_macros_config",564 ":__support_macros_properties_compiler",565 ],566)567 568libc_support_library(569 name = "__support_macros_sanitizer",570 hdrs = ["src/__support/macros/sanitizer.h"],571 deps = [572 ":__support_macros_config",573 ],574)575 576libc_support_library(577 name = "__support_macros_null_check",578 hdrs = ["src/__support/macros/null_check.h"],579 deps = [580 ":__support_macros_config",581 ":__support_macros_optimization",582 ],583)584 585libc_support_library(586 name = "__support_common",587 hdrs = [588 "src/__support/common.h",589 "src/__support/endian_internal.h",590 ],591 deps = [592 ":__support_macros_attributes",593 ":__support_macros_config",594 ":__support_macros_properties_architectures",595 ":__support_macros_properties_compiler",596 ":hdr_stdint_proxy",597 ],598)599 600libc_support_library(601 name = "__support_cpp_algorithm",602 hdrs = ["src/__support/CPP/algorithm.h"],603 deps = [604 ":__support_macros_attributes",605 ":__support_macros_config",606 ],607)608 609libc_support_library(610 name = "__support_cpp_iterator",611 hdrs = ["src/__support/CPP/iterator.h"],612 deps = [613 ":__support_cpp_type_traits",614 ":__support_macros_attributes",615 ],616)617 618libc_support_library(619 name = "__support_cpp_array",620 hdrs = ["src/__support/CPP/array.h"],621 deps = [622 ":__support_cpp_iterator",623 ":__support_macros_attributes",624 ],625)626 627libc_support_library(628 name = "__support_cpp_bit",629 hdrs = ["src/__support/CPP/bit.h"],630 deps = [631 ":__support_cpp_limits",632 ":__support_cpp_type_traits",633 ":__support_macros_attributes",634 ":__support_macros_sanitizer",635 ],636)637 638libc_support_library(639 name = "__support_cpp_bitset",640 hdrs = ["src/__support/CPP/bitset.h"],641 deps = [642 ":__support_macros_attributes",643 ":__support_macros_config",644 ],645)646 647libc_support_library(648 name = "__support_cpp_cstddef",649 hdrs = ["src/__support/CPP/cstddef.h"],650 deps = [651 ":__support_cpp_type_traits",652 ":__support_macros_attributes",653 ],654)655 656libc_support_library(657 name = "__support_cpp_expected",658 hdrs = ["src/__support/CPP/expected.h"],659 deps = [660 ":__support_macros_attributes",661 ":__support_macros_config",662 ],663)664 665libc_support_library(666 name = "__support_cpp_functional",667 hdrs = ["src/__support/CPP/functional.h"],668 deps = [669 "__support_cpp_type_traits",670 "__support_cpp_utility",671 "__support_macros_attributes",672 ],673)674 675libc_support_library(676 name = "__support_cpp_tuple",677 hdrs = ["src/__support/CPP/tuple.h"],678 deps = [679 "__support_cpp_utility",680 ],681)682 683libc_support_library(684 name = "__support_cpp_limits",685 hdrs = ["src/__support/CPP/limits.h"],686 deps = [687 "__support_cpp_type_traits",688 "__support_macros_attributes",689 ":__support_macros_properties_types",690 ":hdr_limits_macros",691 ],692)693 694libc_support_library(695 name = "__support_cpp_new",696 srcs = ["src/__support/CPP/new.cpp"],697 hdrs = ["src/__support/CPP/new.h"],698 deps = [699 ":__support_common",700 ":__support_macros_properties_os",701 ":func_aligned_alloc",702 ":func_free",703 ":func_malloc",704 ],705)706 707libc_support_library(708 name = "__support_cpp_optional",709 hdrs = ["src/__support/CPP/optional.h"],710 deps = [711 ":__support_cpp_utility",712 ":hdr_stdint_proxy",713 ],714)715 716libc_support_library(717 name = "__support_cpp_simd",718 hdrs = ["src/__support/CPP/simd.h"],719 deps = [720 ":__support_cpp_algorithm",721 ":__support_cpp_bit",722 ":__support_cpp_tuple",723 ":__support_cpp_type_traits",724 ":__support_macros_attributes",725 ":hdr_stdint_proxy",726 ],727)728 729libc_support_library(730 name = "__support_cpp_span",731 hdrs = ["src/__support/CPP/span.h"],732 deps = [733 ":__support_cpp_array",734 ":__support_cpp_limits",735 ":__support_cpp_type_traits",736 ],737)738 739libc_support_library(740 name = "__support_cpp_string_view",741 hdrs = ["src/__support/CPP/string_view.h"],742 deps = [743 ":__support_common",744 ":__support_cpp_limits",745 ],746)747 748libc_support_library(749 name = "__support_cpp_stringstream",750 hdrs = ["src/__support/CPP/stringstream.h"],751 deps = [752 ":__support_cpp_span",753 ":__support_cpp_string_view",754 ":__support_cpp_type_traits",755 ":__support_integer_to_string",756 ],757)758 759libc_support_library(760 name = "__support_cpp_string",761 hdrs = ["src/__support/CPP/string.h"],762 deps = [763 ":__support_common",764 ":__support_cpp_string_view",765 ":__support_integer_to_string",766 ":func_free",767 ":func_malloc",768 ":func_realloc",769 ":string_memory_utils",770 ":string_utils",771 ],772)773 774libc_support_library(775 name = "__support_cpp_type_traits",776 hdrs = glob(["src/__support/CPP/type_traits/*.h"]) + [777 "src/__support/CPP/type_traits.h",778 "src/__support/CPP/utility/declval.h",779 "src/__support/CPP/utility/forward.h",780 ],781 deps = [782 ":__support_macros_attributes",783 ":__support_macros_config",784 ":__support_macros_properties_compiler",785 ":__support_macros_properties_complex_types",786 ":__support_macros_properties_types",787 ":hdr_stdint_proxy",788 ":llvm_libc_macros_stdfix_macros",789 ],790)791 792libc_support_library(793 name = "__support_cpp_utility",794 hdrs = glob(["src/__support/CPP/utility/*.h"]) + [795 "src/__support/CPP/utility.h",796 ],797 deps = [798 ":__support_cpp_type_traits",799 ":__support_macros_attributes",800 ],801)802 803libc_support_library(804 name = "__support_cpp_atomic",805 hdrs = ["src/__support/CPP/atomic.h"],806 deps = [807 ":__support_cpp_type_traits",808 ":__support_macros_attributes",809 ":__support_macros_properties_architectures",810 ":hdr_stdint_proxy",811 ],812)813 814libc_support_library(815 name = "__support_blockstore",816 hdrs = ["src/__support/blockstore.h"],817 deps = [818 ":__support_cpp_array",819 ":__support_cpp_new",820 ":__support_libc_assert",821 ],822)823 824libc_support_library(825 name = "__support_arg_list",826 hdrs = ["src/__support/arg_list.h"],827 deps = [828 ":__support_common",829 ":string_memory_utils",830 ],831)832 833libc_support_library(834 name = "__support_c_string",835 hdrs = ["src/__support/c_string.h"],836 deps = [837 ":__support_cpp_string",838 ],839)840 841libc_support_library(842 name = "__support_fixedvector",843 hdrs = ["src/__support/fixedvector.h"],844 deps = [845 ":__support_cpp_array",846 ":__support_cpp_iterator",847 ":__support_libc_assert",848 ":string_memory_utils",849 ],850)851 852libc_support_library(853 name = "__support_char_vector",854 hdrs = ["src/__support/char_vector.h"],855 deps = [856 ":__support_common",857 ":func_free",858 ":func_malloc",859 ":func_realloc",860 ],861)862 863libc_support_library(864 name = "__support_error_or",865 hdrs = ["src/__support/error_or.h"],866 deps = [867 ":__support_common",868 ":__support_cpp_expected",869 ],870)871 872libc_support_library(873 name = "__support_float_to_string",874 hdrs = [875 "src/__support/float_to_string.h",876 "src/__support/ryu_constants.h",877 "src/__support/ryu_long_double_constants.h",878 ],879 deps = [880 ":__support_big_int",881 ":__support_common",882 ":__support_cpp_type_traits",883 ":__support_fputil_dyadic_float",884 ":__support_fputil_fp_bits",885 ":__support_libc_assert",886 ],887)888 889libc_support_library(890 name = "__support_number_pair",891 hdrs = ["src/__support/number_pair.h"],892 deps = [893 ":__support_cpp_type_traits",894 ],895)896 897libc_support_library(898 name = "__support_big_int",899 hdrs = ["src/__support/big_int.h"],900 deps = [901 ":__support_cpp_array",902 ":__support_cpp_bit",903 ":__support_cpp_limits",904 ":__support_cpp_optional",905 ":__support_cpp_type_traits",906 ":__support_macros_attributes",907 ":__support_macros_optimization",908 ":__support_macros_properties_types",909 ":__support_math_extras",910 ":__support_number_pair",911 ],912)913 914libc_support_library(915 name = "__support_sign",916 hdrs = ["src/__support/sign.h"],917 deps = [918 ":__support_macros_attributes",919 ],920)921 922libc_support_library(923 name = "__support_uint128",924 hdrs = ["src/__support/uint128.h"],925 deps = [926 ":__support_big_int",927 ":__support_macros_attributes",928 ":__support_macros_properties_types",929 ],930)931 932libc_support_library(933 name = "__support_integer_literals",934 hdrs = ["src/__support/integer_literals.h"],935 deps = [936 ":__support_cpp_limits",937 ":__support_ctype_utils",938 ":__support_uint128",939 ],940)941 942libc_support_library(943 name = "__support_str_to_num_result",944 hdrs = ["src/__support/str_to_num_result.h"],945 deps = [946 ":__support_macros_attributes",947 ":__support_macros_config",948 ],949)950 951libc_support_library(952 name = "__support_integer_operations",953 hdrs = ["src/__support/integer_operations.h"],954 deps = [":__support_cpp_type_traits"],955)956 957libc_support_library(958 name = "__support_integer_to_string",959 hdrs = ["src/__support/integer_to_string.h"],960 deps = [961 ":__support_big_int",962 ":__support_common",963 ":__support_cpp_algorithm",964 ":__support_cpp_bit",965 ":__support_cpp_limits",966 ":__support_cpp_optional",967 ":__support_cpp_span",968 ":__support_cpp_string_view",969 ":__support_cpp_type_traits",970 ":__support_ctype_utils",971 ],972)973 974libc_support_library(975 name = "__support_libc_assert",976 hdrs = ["src/__support/libc_assert.h"],977)978 979libc_support_library(980 name = "__support_ctype_utils",981 hdrs = ["src/__support/ctype_utils.h"],982 deps = [983 ":__support_macros_attributes",984 ":__support_macros_config",985 ],986)987 988libc_support_library(989 name = "__support_str_to_integer",990 hdrs = ["src/__support/str_to_integer.h"],991 deps = [992 ":__support_common",993 ":__support_cpp_limits",994 ":__support_cpp_type_traits",995 ":__support_ctype_utils",996 ":__support_str_to_num_result",997 ":__support_uint128",998 ":__support_wctype_utils",999 ":hdr_errno_macros",1000 ],1001)1002 1003libc_support_library(1004 name = "__support_str_to_float",1005 hdrs = [1006 "src/__support/detailed_powers_of_ten.h",1007 "src/__support/high_precision_decimal.h",1008 "src/__support/str_to_float.h",1009 ],1010 deps = [1011 ":__support_common",1012 ":__support_cpp_bit",1013 ":__support_cpp_limits",1014 ":__support_cpp_optional",1015 ":__support_cpp_string_view",1016 ":__support_ctype_utils",1017 ":__support_fputil_fp_bits",1018 ":__support_fputil_rounding_mode",1019 ":__support_macros_null_check",1020 ":__support_str_to_integer",1021 ":__support_str_to_num_result",1022 ":__support_uint128",1023 ":__support_wctype_utils",1024 ":hdr_errno_macros",1025 ],1026)1027 1028libc_support_library(1029 name = "__support_complex_type",1030 hdrs = ["src/__support/complex_type.h"],1031 deps = [1032 ":__support_macros_config",1033 ":__support_macros_properties_complex_types",1034 ":__support_macros_properties_types",1035 ],1036)1037 1038libc_support_library(1039 name = "__support_complex_basic_ops",1040 hdrs = ["src/__support/complex_basic_ops.h"],1041 deps = [1042 ":__support_complex_type",1043 ":__support_cpp_bit",1044 ":__support_fputil_fp_bits",1045 ],1046)1047 1048libc_support_library(1049 name = "__support_fputil_basic_operations",1050 hdrs = [1051 "src/__support/FPUtil/BasicOperations.h",1052 "src/__support/FPUtil/generic/add_sub.h",1053 "src/__support/FPUtil/generic/div.h",1054 "src/__support/FPUtil/generic/mul.h",1055 ],1056 deps = [1057 ":__support_common",1058 ":__support_cpp_type_traits",1059 ":__support_fputil_cast",1060 ":__support_fputil_dyadic_float",1061 ":__support_fputil_fenv_impl",1062 ":__support_fputil_fp_bits",1063 ":__support_fputil_rounding_mode",1064 ":__support_macros_optimization",1065 ":__support_uint128",1066 ],1067)1068 1069libc_support_library(1070 name = "__support_fputil_comparison_operations",1071 hdrs = [1072 "src/__support/FPUtil/comparison_operations.h",1073 ],1074 deps = [1075 ":__support_cpp_type_traits",1076 ":__support_fputil_fenv_impl",1077 ":__support_fputil_fp_bits",1078 ":__support_macros_config",1079 ],1080)1081 1082libc_support_library(1083 name = "__support_file_file",1084 srcs = [1085 "include/llvm-libc-types/off_t.h",1086 "src/__support/File/file.cpp",1087 ],1088 hdrs = ["src/__support/File/file.h"],1089 deps = [1090 ":__support_cpp_new",1091 ":__support_cpp_span",1092 ":__support_error_or",1093 ":__support_threads_mutex",1094 ":errno",1095 ":func_aligned_alloc",1096 ":func_free",1097 ":func_malloc",1098 ":func_realloc",1099 ":hdr_stdio_macros",1100 ":hdr_stdio_overlay",1101 ":string_memory_utils",1102 ":types_off_t",1103 ],1104)1105 1106libc_support_library(1107 name = "__support_file_linux_lseekimpl",1108 hdrs = ["src/__support/File/linux/lseekImpl.h"],1109 deps = [1110 ":__support_common",1111 ":__support_error_or",1112 ":__support_osutil_syscall",1113 ":errno",1114 ":hdr_stdio_overlay",1115 ":types_off_t",1116 ],1117)1118 1119libc_support_library(1120 name = "__support_math_extras",1121 hdrs = ["src/__support/math_extras.h"],1122 deps = [1123 ":__support_cpp_bit",1124 ":__support_cpp_limits",1125 ":__support_cpp_type_traits",1126 ":__support_macros_attributes",1127 ],1128)1129 1130libc_support_library(1131 name = "__support_fixed_point",1132 hdrs = [1133 "src/__support/fixed_point/fx_bits.h",1134 "src/__support/fixed_point/fx_rep.h",1135 ],1136 deps = [1137 ":__support_cpp_algorithm",1138 ":__support_cpp_bit",1139 ":__support_cpp_type_traits",1140 ":__support_libc_assert",1141 ":__support_macros_attributes",1142 ":__support_macros_null_check",1143 ":__support_macros_optimization",1144 ":__support_math_extras",1145 ":llvm_libc_macros_stdfix_macros",1146 ],1147)1148 1149libc_support_library(1150 name = "__support_fputil_generic_fmod",1151 hdrs = ["src/__support/FPUtil/generic/FMod.h"],1152 deps = [1153 ":__support_common",1154 ":__support_cpp_bit",1155 ":__support_cpp_limits",1156 ":__support_cpp_type_traits",1157 ":__support_fputil_fenv_impl",1158 ":__support_fputil_fp_bits",1159 ],1160)1161 1162libc_support_library(1163 name = "__support_fputil_bfloat16",1164 hdrs = ["src/__support/FPUtil/bfloat16.h"],1165 deps = [1166 ":__support_cpp_bit",1167 ":__support_cpp_type_traits",1168 ":__support_fputil_basic_operations",1169 ":__support_fputil_cast",1170 ":__support_fputil_comparison_operations",1171 ":__support_fputil_dyadic_float",1172 ":__support_macros_config",1173 ":__support_macros_properties_types",1174 ],1175)1176 1177alias(1178 name = "bfloat16", # Alias for test/src/math:bfloat16_test.1179 actual = ":__support_fputil_bfloat16",1180)1181 1182libc_support_library(1183 name = "__support_fputil_cast",1184 hdrs = ["src/__support/FPUtil/cast.h"],1185 deps = [1186 ":__support_cpp_algorithm",1187 ":__support_cpp_type_traits",1188 ":__support_fputil_dyadic_float",1189 ":__support_fputil_fp_bits",1190 ":__support_macros_properties_types",1191 ":hdr_fenv_macros",1192 ],1193)1194 1195libc_support_library(1196 name = "__support_fputil_division_and_remainder_operations",1197 hdrs = ["src/__support/FPUtil/DivisionAndRemainderOperations.h"],1198 deps = [1199 ":__support_common",1200 ":__support_cpp_type_traits",1201 ":__support_fputil_fp_bits",1202 ":__support_fputil_manipulation_functions",1203 ":__support_fputil_normal_float",1204 ],1205)1206 1207libc_support_library(1208 name = "__support_fputil_except_value_utils",1209 hdrs = ["src/__support/FPUtil/except_value_utils.h"],1210 deps = [1211 ":__support_cpp_optional",1212 ":__support_fputil_cast",1213 ":__support_fputil_fenv_impl",1214 ":__support_fputil_fp_bits",1215 ":__support_fputil_rounding_mode",1216 ":__support_macros_properties_cpu_features",1217 ":__support_macros_properties_types",1218 ],1219)1220 1221libc_support_library(1222 name = "__support_fputil_fenv_impl",1223 hdrs = ["src/__support/FPUtil/FEnvImpl.h"],1224 textual_hdrs = [1225 "src/__support/FPUtil/x86_64/FEnvImpl.h",1226 "src/__support/FPUtil/aarch64/FEnvImpl.h",1227 "src/__support/FPUtil/aarch64/fenv_darwin_impl.h",1228 ],1229 deps = [1230 ":__support_fputil_fp_bits",1231 ":__support_macros_attributes",1232 ":__support_macros_properties_architectures",1233 ":__support_macros_sanitizer",1234 ":errno",1235 ":hdr_fenv_macros",1236 ":hdr_math_macros",1237 ":types_fenv_t",1238 ],1239)1240 1241libc_support_library(1242 name = "__support_fputil_rounding_mode",1243 hdrs = ["src/__support/FPUtil/rounding_mode.h"],1244 deps = [1245 ":__support_cpp_type_traits",1246 ":__support_macros_attributes",1247 ":__support_macros_config",1248 ":hdr_fenv_macros",1249 ],1250)1251 1252libc_support_library(1253 name = "__support_fputil_fp_bits",1254 hdrs = ["src/__support/FPUtil/FPBits.h"],1255 deps = [1256 ":__support_common",1257 ":__support_cpp_bit",1258 ":__support_cpp_type_traits",1259 ":__support_libc_assert",1260 ":__support_macros_attributes",1261 ":__support_macros_properties_types",1262 ":__support_math_extras",1263 ":__support_sign",1264 ":__support_uint128",1265 ],1266)1267 1268libc_support_library(1269 name = "__support_fputil_fpbits_str",1270 hdrs = ["src/__support/FPUtil/fpbits_str.h"],1271 deps = [1272 ":__support_common",1273 ":__support_cpp_string",1274 ":__support_cpp_type_traits",1275 ":__support_fputil_fp_bits",1276 ":__support_integer_to_string",1277 ":__support_uint128",1278 ],1279)1280 1281libc_support_library(1282 name = "__support_fputil_hypot",1283 hdrs = ["src/__support/FPUtil/Hypot.h"],1284 deps = [1285 ":__support_common",1286 ":__support_cpp_bit",1287 ":__support_cpp_type_traits",1288 ":__support_fputil_basic_operations",1289 ":__support_fputil_cast",1290 ":__support_fputil_fenv_impl",1291 ":__support_fputil_fp_bits",1292 ":__support_fputil_rounding_mode",1293 ":__support_uint128",1294 ],1295)1296 1297libc_support_library(1298 name = "__support_fputil_manipulation_functions",1299 hdrs = ["src/__support/FPUtil/ManipulationFunctions.h"],1300 textual_hdrs = [1301 "src/__support/FPUtil/x86_64/NextAfterLongDouble.h",1302 "src/__support/FPUtil/x86_64/NextUpDownLongDouble.h",1303 ],1304 deps = [1305 ":__support_common",1306 ":__support_cpp_bit",1307 ":__support_cpp_limits",1308 ":__support_cpp_type_traits",1309 ":__support_fputil_cast",1310 ":__support_fputil_dyadic_float",1311 ":__support_fputil_fp_bits",1312 ":__support_fputil_nearest_integer_operations",1313 ":__support_fputil_normal_float",1314 ":__support_macros_optimization",1315 ":__support_uint128",1316 ":hdr_math_macros",1317 ],1318)1319 1320libc_support_library(1321 name = "__support_fputil_nearest_integer_operations",1322 hdrs = ["src/__support/FPUtil/NearestIntegerOperations.h"],1323 deps = [1324 ":__support_common",1325 ":__support_cpp_type_traits",1326 ":__support_fputil_fenv_impl",1327 ":__support_fputil_fp_bits",1328 ":__support_fputil_rounding_mode",1329 ":__support_macros_attributes",1330 ":hdr_math_macros",1331 ],1332)1333 1334libc_support_library(1335 name = "__support_fputil_normal_float",1336 hdrs = ["src/__support/FPUtil/NormalFloat.h"],1337 deps = [1338 ":__support_common",1339 ":__support_cpp_type_traits",1340 ":__support_fputil_fp_bits",1341 ],1342)1343 1344sqrt_common_hdrs = [1345 "src/__support/FPUtil/sqrt.h",1346 "src/__support/FPUtil/generic/sqrt.h",1347 "src/__support/FPUtil/generic/sqrt_80_bit_long_double.h",1348]1349 1350sqrt_hdrs = selects.with_or({1351 "//conditions:default": sqrt_common_hdrs,1352 PLATFORM_CPU_X86_64: sqrt_common_hdrs + [1353 "src/__support/FPUtil/x86_64/sqrt.h",1354 ],1355 PLATFORM_CPU_ARM64: sqrt_common_hdrs + [1356 "src/__support/FPUtil/aarch64/sqrt.h",1357 ],1358})1359 1360libc_support_library(1361 name = "__support_fputil_sqrt",1362 hdrs = sqrt_hdrs,1363 deps = [1364 ":__support_common",1365 ":__support_cpp_bit",1366 ":__support_cpp_type_traits",1367 ":__support_fputil_cast",1368 ":__support_fputil_dyadic_float",1369 ":__support_fputil_fenv_impl",1370 ":__support_fputil_fp_bits",1371 ":__support_fputil_rounding_mode",1372 ":__support_macros_properties_cpu_features",1373 ":__support_uint128",1374 ],1375)1376 1377fma_common_hdrs = [1378 "src/__support/FPUtil/FMA.h",1379 "src/__support/FPUtil/generic/FMA.h",1380]1381 1382libc_support_library(1383 name = "__support_fputil_fma",1384 hdrs = fma_common_hdrs,1385 deps = [1386 ":__support_cpp_bit",1387 ":__support_cpp_type_traits",1388 ":__support_fputil_basic_operations",1389 ":__support_fputil_dyadic_float",1390 ":__support_fputil_fenv_impl",1391 ":__support_fputil_fp_bits",1392 ":__support_fputil_rounding_mode",1393 ":__support_macros_attributes",1394 ":__support_macros_optimization",1395 ":__support_macros_properties_cpu_features",1396 ":__support_uint128",1397 ],1398)1399 1400libc_support_library(1401 name = "__support_fputil_multiply_add",1402 hdrs = [1403 "src/__support/FPUtil/multiply_add.h",1404 ],1405 deps = [1406 ":__support_common",1407 ":__support_cpp_type_traits",1408 ],1409)1410 1411libc_support_library(1412 name = "__support_fputil_polyeval",1413 hdrs = [1414 "src/__support/FPUtil/PolyEval.h",1415 ],1416 deps = [1417 ":__support_common",1418 ":__support_fputil_multiply_add",1419 ],1420)1421 1422nearest_integer_common_hdrs = [1423 "src/__support/FPUtil/nearest_integer.h",1424]1425 1426nearest_integer_platform_hdrs = [1427 "src/__support/FPUtil/x86_64/nearest_integer.h",1428 "src/__support/FPUtil/aarch64/nearest_integer.h",1429]1430 1431libc_support_library(1432 name = "__support_fputil_nearest_integer",1433 hdrs = nearest_integer_common_hdrs,1434 # These are conditionally included and will #error out if the platform1435 # doesn't support rounding instructions, so they can't be compiled on their1436 # own.1437 textual_hdrs = nearest_integer_platform_hdrs,1438 deps = [1439 ":__support_common",1440 ":__support_macros_optimization",1441 ":__support_macros_properties_architectures",1442 ":__support_macros_properties_cpu_features",1443 ],1444)1445 1446libc_support_library(1447 name = "__support_fputil_double_double",1448 hdrs = ["src/__support/FPUtil/double_double.h"],1449 deps = [1450 ":__support_common",1451 ":__support_fputil_multiply_add",1452 ":__support_number_pair",1453 ],1454)1455 1456libc_support_library(1457 name = "__support_fputil_triple_double",1458 hdrs = ["src/__support/FPUtil/triple_double.h"],1459 deps = [1460 ":__support_common",1461 ],1462)1463 1464libc_support_library(1465 name = "__support_fputil_dyadic_float",1466 hdrs = ["src/__support/FPUtil/dyadic_float.h"],1467 deps = [1468 ":__support_big_int",1469 ":__support_common",1470 ":__support_cpp_type_traits",1471 ":__support_fputil_fenv_impl",1472 ":__support_fputil_fp_bits",1473 ":__support_fputil_multiply_add",1474 ":__support_fputil_rounding_mode",1475 ":__support_macros_optimization",1476 ],1477)1478 1479libc_support_library(1480 name = "__support_osutil_syscall",1481 hdrs = ["src/__support/OSUtil/syscall.h"],1482 textual_hdrs = select({1483 "@platforms//os:macos": [1484 "src/__support/OSUtil/darwin/syscall.h",1485 "src/__support/OSUtil/darwin/arm/syscall.h",1486 ],1487 "@platforms//os:linux": [1488 "src/__support/OSUtil/linux/syscall.h",1489 "src/__support/OSUtil/linux/aarch64/syscall.h",1490 "src/__support/OSUtil/linux/x86_64/syscall.h",1491 ],1492 "@platforms//os:windows": [],1493 }),1494 deps = [1495 ":__support_common",1496 ":__support_cpp_bit",1497 ":__support_macros_optimization",1498 ":__support_macros_sanitizer",1499 ],1500)1501 1502libc_support_library(1503 name = "__support_osutil_linux_auxv",1504 hdrs = ["src/__support/OSUtil/linux/auxv.h"],1505 target_compatible_with = select({1506 "@platforms//os:linux": [],1507 "//conditions:default": ["@platforms//:incompatible"],1508 }),1509 deps = [1510 ":__support_common",1511 ":__support_osutil_syscall",1512 ":__support_threads_callonce",1513 ":hdr_fcntl_macros",1514 ],1515)1516 1517libc_support_library(1518 name = "__support_osutil_vdso",1519 hdrs = [1520 "src/__support/OSUtil/linux/vdso.h",1521 "src/__support/OSUtil/linux/vdso_sym.h",1522 ],1523 target_compatible_with = select({1524 "@platforms//os:linux": [],1525 "//conditions:default": ["@platforms//:incompatible"],1526 }),1527 textual_hdrs = [1528 "src/__support/OSUtil/linux/riscv/vdso.h",1529 "src/__support/OSUtil/linux/arm/vdso.h",1530 "src/__support/OSUtil/linux/x86_64/vdso.h",1531 "src/__support/OSUtil/linux/aarch64/vdso.h",1532 ],1533 deps = [1534 ":__support_cpp_array",1535 ":__support_cpp_optional",1536 ":__support_cpp_string_view",1537 ":__support_threads_callonce",1538 ":types_clock_t",1539 ":types_clockid_t",1540 ":types_struct_timeval",1541 ],1542)1543 1544libc_support_library(1545 name = "__support_osutil_io",1546 hdrs = ["src/__support/OSUtil/io.h"],1547 textual_hdrs = select({1548 "@platforms//os:macos": ["src/__support/OSUtil/darwin/io.h"],1549 "@platforms//os:linux": ["src/__support/OSUtil/linux/io.h"],1550 "@platforms//os:windows": ["src/__support/OSUtil/windows/io.h"],1551 }),1552 deps = [1553 ":__support_common",1554 ":__support_cpp_string_view",1555 ":__support_osutil_syscall",1556 ":string_utils",1557 ],1558)1559 1560libc_support_library(1561 name = "__support_osutil_fcntl",1562 srcs = ["src/__support/OSUtil/linux/fcntl.cpp"],1563 hdrs = ["src/__support/OSUtil/fcntl.h"],1564 target_compatible_with = select({1565 "@platforms//os:linux": [],1566 "//conditions:default": ["@platforms//:incompatible"],1567 }),1568 deps = [1569 ":__support_common",1570 ":__support_error_or",1571 ":__support_osutil_syscall",1572 ":hdr_errno_macros",1573 ":hdr_fcntl_macros",1574 ":types_mode_t",1575 ":types_off_t",1576 ":types_struct_f_owner_ex",1577 ":types_struct_flock",1578 ":types_struct_flock64",1579 ],1580)1581 1582libc_support_library(1583 name = "__support_osutil_exit",1584 srcs = ["src/__support/OSUtil/linux/exit.cpp"],1585 hdrs = ["src/__support/OSUtil/exit.h"],1586 target_compatible_with = select({1587 "@platforms//os:linux": [],1588 "//conditions:default": ["@platforms//:incompatible"],1589 }),1590 deps = [1591 ":__support_osutil_syscall",1592 ],1593)1594 1595libc_support_library(1596 name = "__support_stringutil",1597 srcs = glob(["src/__support/StringUtil/tables/**/*.h"]) + [1598 "src/__support/StringUtil/error_to_string.cpp",1599 "src/__support/StringUtil/message_mapper.h",1600 "src/__support/StringUtil/platform_errors.h",1601 "src/__support/StringUtil/platform_signals.h",1602 "src/__support/StringUtil/signal_to_string.cpp",1603 ],1604 hdrs = [1605 "src/__support/StringUtil/error_to_string.h",1606 "src/__support/StringUtil/signal_to_string.h",1607 ],1608 target_compatible_with = select({1609 "@platforms//os:linux": [],1610 "//conditions:default": ["@platforms//:incompatible"],1611 }),1612 deps = [1613 ":__support_cpp_array",1614 ":__support_cpp_span",1615 ":__support_cpp_string_view",1616 ":__support_cpp_stringstream",1617 ":__support_integer_to_string",1618 ":__support_macros_attributes",1619 ":errno",1620 ],1621)1622 1623libc_support_library(1624 name = "__support_threads_linux_futex_word_type",1625 hdrs = [1626 "src/__support/threads/linux/futex_word.h",1627 ],1628 target_compatible_with = select({1629 "@platforms//os:linux": [],1630 "//conditions:default": ["@platforms//:incompatible"],1631 }),1632 deps = [1633 ":__support_osutil_syscall",1634 ],1635)1636 1637libc_support_library(1638 name = "__support_threads_linux_futex_utils",1639 hdrs = [1640 "src/__support/threads/linux/futex_utils.h",1641 ],1642 target_compatible_with = select({1643 "@platforms//os:linux": [],1644 "//conditions:default": ["@platforms//:incompatible"],1645 }),1646 deps = [1647 ":__support_cpp_atomic",1648 ":__support_cpp_optional",1649 ":__support_osutil_syscall",1650 ":__support_threads_linux_futex_word_type",1651 ":__support_time_linux_abs_timeout",1652 ":types_struct_timespec",1653 ],1654)1655 1656libc_support_library(1657 name = "__support_threads_sleep",1658 hdrs = ["src/__support/threads/sleep.h"],1659 deps = [1660 ":__support_macros_attributes",1661 ":__support_macros_config",1662 ],1663)1664 1665libc_support_library(1666 name = "__support_threads_raw_mutex",1667 hdrs = [1668 "src/__support/threads/linux/raw_mutex.h",1669 ],1670 target_compatible_with = select({1671 "@platforms//os:linux": [],1672 "//conditions:default": ["@platforms//:incompatible"],1673 }),1674 deps = [1675 ":__support_cpp_expected",1676 ":__support_cpp_optional",1677 ":__support_threads_linux_futex_utils",1678 ":__support_threads_sleep",1679 ":__support_time_linux_abs_timeout",1680 ":__support_time_linux_monotonicity",1681 ":types_pid_t",1682 ],1683)1684 1685libc_support_library(1686 name = "__support_threads_mutex",1687 hdrs = [1688 "src/__support/threads/mutex.h",1689 "src/__support/threads/mutex_common.h",1690 ],1691 target_compatible_with = select({1692 "@platforms//os:linux": [],1693 "//conditions:default": ["@platforms//:incompatible"],1694 }),1695 textual_hdrs = [1696 "src/__support/threads/linux/mutex.h",1697 ],1698 deps = [1699 ":__support_cpp_atomic",1700 ":__support_osutil_syscall",1701 ":__support_threads_linux_futex_utils",1702 ":__support_threads_raw_mutex",1703 ":types_pid_t",1704 ],1705)1706 1707libc_support_library(1708 name = "__support_threads_callonce",1709 hdrs = [1710 "src/__support/threads/callonce.h",1711 ],1712 target_compatible_with = select({1713 "@platforms//os:linux": [],1714 "//conditions:default": ["@platforms//:incompatible"],1715 }),1716 textual_hdrs = [1717 "src/__support/threads/linux/callonce.h",1718 ],1719 deps = [1720 ":__support_macros_config",1721 ":__support_macros_optimization",1722 ":__support_threads_linux_futex_utils",1723 ],1724)1725 1726libc_support_library(1727 name = "__support_time",1728 hdrs = glob(["src/__support/time/*.h"]),1729 deps = [1730 ":__support_common",1731 ":__support_error_or",1732 ":hdr_time_macros",1733 ":types_clockid_t",1734 ":types_struct_timespec",1735 ":types_time_t",1736 ],1737)1738 1739libc_support_library(1740 name = "__support_time_linux_abs_timeout",1741 hdrs = ["src/__support/time/linux/abs_timeout.h"],1742 target_compatible_with = select({1743 "@platforms//os:linux": [],1744 "//conditions:default": ["@platforms//:incompatible"],1745 }),1746 deps = [1747 ":__support_cpp_expected",1748 ":__support_time",1749 ":hdr_time_macros",1750 ":types_struct_timespec",1751 ],1752)1753 1754libc_support_library(1755 name = "__support_time_linux_clock_conversion",1756 hdrs = ["src/__support/time/linux/clock_conversion.h"],1757 target_compatible_with = select({1758 "@platforms//os:linux": [],1759 "//conditions:default": ["@platforms//:incompatible"],1760 }),1761 deps = [1762 ":__support_time",1763 ":__support_time_clock_gettime",1764 ],1765)1766 1767libc_support_library(1768 name = "__support_time_clock_gettime",1769 hdrs = ["src/__support/time/clock_gettime.h"],1770 target_compatible_with = select({1771 "@platforms//os:linux": [],1772 "//conditions:default": ["@platforms//:incompatible"],1773 }),1774 deps = [1775 ":__support_common",1776 ":__support_error_or",1777 ":__support_osutil_vdso",1778 ":types_clockid_t",1779 ":types_struct_timespec",1780 ],1781)1782 1783libc_support_library(1784 name = "__support_time_linux_monotonicity",1785 hdrs = ["src/__support/time/linux/monotonicity.h"],1786 target_compatible_with = select({1787 "@platforms//os:linux": [],1788 "//conditions:default": ["@platforms//:incompatible"],1789 }),1790 deps = [1791 ":__support_libc_assert",1792 ":__support_time_linux_abs_timeout",1793 ":__support_time_linux_clock_conversion",1794 ":hdr_time_macros",1795 ],1796)1797 1798libc_support_library(1799 name = "__support_wctype_utils",1800 hdrs = ["src/__support/wctype_utils.h"],1801 deps = [1802 ":__support_macros_attributes",1803 ":__support_macros_config",1804 ":types_wchar_t",1805 ],1806)1807 1808########################## externally shared targets ###########################1809 1810libc_header_library(1811 name = "libcxx_shared_headers",1812 hdrs = [1813 "shared/fp_bits.h",1814 "shared/libc_common.h",1815 "shared/str_to_float.h",1816 "shared/str_to_integer.h",1817 ],1818 deps = [1819 ":__support_common",1820 ":__support_fputil_fp_bits",1821 ":__support_str_to_float",1822 ":__support_str_to_integer",1823 ],1824)1825 1826############################### errno ########################################1827 1828libc_support_library(1829 name = "__support_libc_errno",1830 hdrs = ["src/__support/libc_errno.h"],1831 deps = [1832 ":__support_macros_config",1833 ":hdr_errno_macros",1834 ],1835)1836 1837libc_support_library(1838 name = "errno",1839 srcs = ["src/errno/libc_errno.cpp"],1840 deps = [1841 ":__support_common",1842 ":__support_cpp_atomic",1843 ":__support_libc_errno",1844 ":__support_macros_attributes",1845 ":__support_macros_properties_architectures",1846 ":hdr_errno_macros",1847 ],1848)1849 1850################################# ctype targets ################################1851 1852libc_function(1853 name = "isalnum",1854 srcs = ["src/ctype/isalnum.cpp"],1855 hdrs = ["src/ctype/isalnum.h"],1856 deps = [1857 ":__support_common",1858 ":__support_cpp_limits",1859 ":__support_ctype_utils",1860 ],1861)1862 1863libc_function(1864 name = "isalpha",1865 srcs = ["src/ctype/isalpha.cpp"],1866 hdrs = ["src/ctype/isalpha.h"],1867 deps = [1868 ":__support_common",1869 ":__support_cpp_limits",1870 ":__support_ctype_utils",1871 ],1872)1873 1874libc_function(1875 name = "isascii",1876 srcs = ["src/ctype/isascii.cpp"],1877 hdrs = ["src/ctype/isascii.h"],1878 deps = [1879 ":__support_common",1880 ":__support_ctype_utils",1881 ],1882)1883 1884libc_function(1885 name = "isblank",1886 srcs = ["src/ctype/isblank.cpp"],1887 hdrs = ["src/ctype/isblank.h"],1888 deps = [1889 ":__support_common",1890 ":__support_ctype_utils",1891 ],1892)1893 1894libc_function(1895 name = "iscntrl",1896 srcs = ["src/ctype/iscntrl.cpp"],1897 hdrs = ["src/ctype/iscntrl.h"],1898 deps = [1899 ":__support_common",1900 ":__support_ctype_utils",1901 ],1902)1903 1904libc_function(1905 name = "isdigit",1906 srcs = ["src/ctype/isdigit.cpp"],1907 hdrs = ["src/ctype/isdigit.h"],1908 deps = [1909 ":__support_common",1910 ":__support_cpp_limits",1911 ":__support_ctype_utils",1912 ],1913)1914 1915libc_function(1916 name = "isgraph",1917 srcs = ["src/ctype/isgraph.cpp"],1918 hdrs = ["src/ctype/isgraph.h"],1919 deps = [1920 ":__support_common",1921 ":__support_cpp_limits",1922 ":__support_ctype_utils",1923 ],1924)1925 1926libc_function(1927 name = "islower",1928 srcs = ["src/ctype/islower.cpp"],1929 hdrs = ["src/ctype/islower.h"],1930 deps = [1931 ":__support_common",1932 ":__support_cpp_limits",1933 ":__support_ctype_utils",1934 ],1935)1936 1937libc_function(1938 name = "isprint",1939 srcs = ["src/ctype/isprint.cpp"],1940 hdrs = ["src/ctype/isprint.h"],1941 deps = [1942 ":__support_common",1943 ":__support_ctype_utils",1944 ],1945)1946 1947libc_function(1948 name = "ispunct",1949 srcs = ["src/ctype/ispunct.cpp"],1950 hdrs = ["src/ctype/ispunct.h"],1951 deps = [1952 ":__support_common",1953 ":__support_cpp_limits",1954 ":__support_ctype_utils",1955 ],1956)1957 1958libc_function(1959 name = "isspace",1960 srcs = ["src/ctype/isspace.cpp"],1961 hdrs = ["src/ctype/isspace.h"],1962 deps = [1963 ":__support_common",1964 ":__support_cpp_limits",1965 ":__support_ctype_utils",1966 ],1967)1968 1969libc_function(1970 name = "isupper",1971 srcs = ["src/ctype/isupper.cpp"],1972 hdrs = ["src/ctype/isupper.h"],1973 deps = [1974 ":__support_common",1975 ":__support_cpp_limits",1976 ":__support_ctype_utils",1977 ],1978)1979 1980libc_function(1981 name = "isxdigit",1982 srcs = ["src/ctype/isxdigit.cpp"],1983 hdrs = ["src/ctype/isxdigit.h"],1984 deps = [1985 ":__support_common",1986 ":__support_cpp_limits",1987 ":__support_ctype_utils",1988 ],1989)1990 1991libc_function(1992 name = "toascii",1993 srcs = ["src/ctype/toascii.cpp"],1994 hdrs = ["src/ctype/toascii.h"],1995 deps = [1996 ":__support_common",1997 ":__support_ctype_utils",1998 ],1999)2000 2001libc_function(2002 name = "tolower",2003 srcs = ["src/ctype/tolower.cpp"],2004 hdrs = ["src/ctype/tolower.h"],2005 deps = [2006 ":__support_common",2007 ":__support_cpp_limits",2008 ":__support_ctype_utils",2009 ],2010)2011 2012libc_function(2013 name = "toupper",2014 srcs = ["src/ctype/toupper.cpp"],2015 hdrs = ["src/ctype/toupper.h"],2016 deps = [2017 ":__support_common",2018 ":__support_cpp_limits",2019 ":__support_ctype_utils",2020 ],2021)2022 2023################################ fenv targets ################################2024 2025libc_function(2026 name = "fetestexcept",2027 srcs = ["src/fenv/fetestexcept.cpp"],2028 hdrs = ["src/fenv/fetestexcept.h"],2029 deps = [2030 ":__support_common",2031 ":__support_fputil_fenv_impl",2032 ],2033)2034 2035libc_function(2036 name = "fetestexceptflag",2037 srcs = ["src/fenv/fetestexceptflag.cpp"],2038 hdrs = ["src/fenv/fetestexceptflag.h"],2039 deps = [2040 ":__support_common",2041 ":__support_fputil_fenv_impl",2042 ":types_fexcept_t",2043 ],2044)2045 2046libc_function(2047 name = "feclearexcept",2048 srcs = ["src/fenv/feclearexcept.cpp"],2049 hdrs = ["src/fenv/feclearexcept.h"],2050 deps = [2051 ":__support_common",2052 ":__support_fputil_fenv_impl",2053 ],2054)2055 2056libc_function(2057 name = "feraiseexcept",2058 srcs = ["src/fenv/feraiseexcept.cpp"],2059 hdrs = ["src/fenv/feraiseexcept.h"],2060 deps = [2061 ":__support_common",2062 ":__support_fputil_fenv_impl",2063 ],2064)2065 2066libc_function(2067 name = "fegetround",2068 srcs = ["src/fenv/fegetround.cpp"],2069 hdrs = ["src/fenv/fegetround.h"],2070 deps = [2071 ":__support_common",2072 ":__support_fputil_fenv_impl",2073 ],2074)2075 2076libc_function(2077 name = "fesetround",2078 srcs = ["src/fenv/fesetround.cpp"],2079 hdrs = ["src/fenv/fesetround.h"],2080 deps = [2081 ":__support_common",2082 ":__support_fputil_fenv_impl",2083 ],2084)2085 2086libc_function(2087 name = "fedisableexcept",2088 srcs = ["src/fenv/fedisableexcept.cpp"],2089 hdrs = ["src/fenv/fedisableexcept.h"],2090 deps = [2091 ":__support_common",2092 ":__support_fputil_fenv_impl",2093 ],2094)2095 2096libc_function(2097 name = "feenableexcept",2098 srcs = ["src/fenv/feenableexcept.cpp"],2099 hdrs = ["src/fenv/feenableexcept.h"],2100 deps = [2101 ":__support_common",2102 ":__support_fputil_fenv_impl",2103 ],2104)2105 2106libc_function(2107 name = "fegetexcept",2108 srcs = ["src/fenv/fegetexcept.cpp"],2109 hdrs = ["src/fenv/fegetexcept.h"],2110 deps = [2111 ":__support_common",2112 ":__support_fputil_fenv_impl",2113 ],2114)2115 2116libc_function(2117 name = "fegetenv",2118 srcs = ["src/fenv/fegetenv.cpp"],2119 hdrs = ["src/fenv/fegetenv.h"],2120 deps = [2121 ":__support_common",2122 ":__support_fputil_fenv_impl",2123 ],2124)2125 2126libc_function(2127 name = "fesetenv",2128 srcs = ["src/fenv/fesetenv.cpp"],2129 hdrs = ["src/fenv/fesetenv.h"],2130 deps = [2131 ":__support_common",2132 ":__support_fputil_fenv_impl",2133 ],2134)2135 2136libc_function(2137 name = "feupdateenv",2138 srcs = ["src/fenv/feupdateenv.cpp"],2139 hdrs = ["src/fenv/feupdateenv.h"],2140 deps = [2141 ":__support_common",2142 ":__support_fputil_fenv_impl",2143 ],2144)2145 2146libc_function(2147 name = "fesetexcept",2148 srcs = ["src/fenv/fesetexcept.cpp"],2149 hdrs = ["src/fenv/fesetexcept.h"],2150 deps = [2151 ":__support_common",2152 ":__support_fputil_fenv_impl",2153 ],2154)2155 2156libc_function(2157 name = "fegetexceptflag",2158 srcs = ["src/fenv/fegetexceptflag.cpp"],2159 hdrs = ["src/fenv/fegetexceptflag.h"],2160 deps = [2161 ":__support_common",2162 ":__support_fputil_fenv_impl",2163 ":types_fexcept_t",2164 ],2165)2166 2167libc_function(2168 name = "fesetexceptflag",2169 srcs = ["src/fenv/fesetexceptflag.cpp"],2170 hdrs = ["src/fenv/fesetexceptflag.h"],2171 deps = [2172 ":__support_common",2173 ":__support_fputil_fenv_impl",2174 ":types_fexcept_t",2175 ],2176)2177 2178libc_function(2179 name = "feholdexcept",2180 srcs = ["src/fenv/feholdexcept.cpp"],2181 hdrs = ["src/fenv/feholdexcept.h"],2182 deps = [2183 ":__support_common",2184 ":__support_fputil_fenv_impl",2185 ],2186)2187 2188########################### math support library ###############################2189 2190libc_support_library(2191 name = "log_range_reduction",2192 hdrs = ["src/math/generic/log_range_reduction.h"],2193 deps = [2194 ":__support_common",2195 ":__support_fputil_dyadic_float",2196 ":__support_math_common_constants",2197 ":__support_uint128",2198 ],2199)2200 2201libc_support_library(2202 name = "__support_math_acos",2203 hdrs = ["src/__support/math/acos.h"],2204 deps = [2205 ":__support_fputil_double_double",2206 ":__support_fputil_dyadic_float",2207 ":__support_fputil_fenv_impl",2208 ":__support_fputil_fp_bits",2209 ":__support_fputil_multiply_add",2210 ":__support_fputil_polyeval",2211 ":__support_fputil_sqrt",2212 ":__support_macros_optimization",2213 ":__support_macros_properties_cpu_features",2214 ":__support_macros_properties_types",2215 ":__support_math_asin_utils",2216 ],2217)2218 2219libc_support_library(2220 name = "__support_math_acosf",2221 hdrs = ["src/__support/math/acosf.h"],2222 deps = [2223 ":__support_fputil_except_value_utils",2224 ":__support_fputil_fp_bits",2225 ":__support_fputil_multiply_add",2226 ":__support_fputil_polyeval",2227 ":__support_fputil_sqrt",2228 ":__support_macros_optimization",2229 ":__support_math_inv_trigf_utils",2230 ],2231)2232 2233libc_support_library(2234 name = "__support_math_acosf16",2235 hdrs = ["src/__support/math/acosf16.h"],2236 deps = [2237 ":__support_fputil_cast",2238 ":__support_fputil_except_value_utils",2239 ":__support_fputil_fma",2240 ":__support_fputil_multiply_add",2241 ":__support_fputil_nearest_integer",2242 ":__support_fputil_polyeval",2243 ":__support_fputil_sqrt",2244 ":__support_macros_optimization",2245 ],2246)2247 2248libc_support_library(2249 name = "__support_math_acosh_float_constants",2250 hdrs = ["src/__support/math/acosh_float_constants.h"],2251 deps = [2252 ":__support_macros_config",2253 ],2254)2255 2256libc_support_library(2257 name = "__support_math_acoshf_utils",2258 hdrs = ["src/__support/math/acoshf_utils.h"],2259 deps = [2260 ":__support_fputil_fp_bits",2261 ":__support_fputil_multiply_add",2262 ":__support_fputil_polyeval",2263 ":__support_math_acosh_float_constants",2264 ],2265)2266 2267libc_support_library(2268 name = "__support_math_acoshf",2269 hdrs = ["src/__support/math/acoshf.h"],2270 deps = [2271 ":__support_fputil_fenv_impl",2272 ":__support_fputil_fp_bits",2273 ":__support_fputil_multiply_add",2274 ":__support_fputil_sqrt",2275 ":__support_macros_optimization",2276 ":__support_math_acoshf_utils",2277 ],2278)2279 2280libc_support_library(2281 name = "__support_math_acoshf16",2282 hdrs = ["src/__support/math/acoshf16.h"],2283 deps = [2284 ":__support_fputil_cast",2285 ":__support_fputil_except_value_utils",2286 ":__support_fputil_fenv_impl",2287 ":__support_fputil_fp_bits",2288 ":__support_fputil_multiply_add",2289 ":__support_fputil_polyeval",2290 ":__support_fputil_sqrt",2291 ":__support_macros_optimization",2292 ":__support_math_acoshf_utils",2293 ],2294)2295 2296libc_support_library(2297 name = "__support_math_acospif16",2298 hdrs = ["src/__support/math/acospif16.h"],2299 deps = [2300 ":__support_fputil_cast",2301 ":__support_fputil_fenv_impl",2302 ":__support_fputil_fp_bits",2303 ":__support_fputil_multiply_add",2304 ":__support_fputil_polyeval",2305 ":__support_fputil_sqrt",2306 ":__support_macros_optimization",2307 ":__support_macros_properties_types",2308 ],2309)2310 2311libc_support_library(2312 name = "__support_math_rsqrtf",2313 hdrs = ["src/__support/math/rsqrtf.h"],2314 deps = [2315 ":__support_fputil_cast",2316 ":__support_fputil_fenv_impl",2317 ":__support_fputil_fp_bits",2318 ":__support_fputil_sqrt",2319 ":__support_macros_optimization",2320 ":hdr_errno_macros",2321 ":hdr_fenv_macros",2322 ],2323)2324 2325libc_support_library(2326 name = "__support_math_rsqrtf16",2327 hdrs = ["src/__support/math/rsqrtf16.h"],2328 deps = [2329 ":__support_fputil_cast",2330 ":__support_fputil_fenv_impl",2331 ":__support_fputil_fp_bits",2332 ":__support_fputil_manipulation_functions",2333 ":__support_fputil_sqrt",2334 ":__support_macros_optimization",2335 ":hdr_errno_macros",2336 ":hdr_fenv_macros",2337 ],2338)2339 2340libc_support_library(2341 name = "__support_math_asin_utils",2342 hdrs = ["src/__support/math/asin_utils.h"],2343 deps = [2344 ":__support_fputil_double_double",2345 ":__support_fputil_dyadic_float",2346 ":__support_fputil_multiply_add",2347 ":__support_fputil_nearest_integer",2348 ":__support_fputil_polyeval",2349 ":__support_integer_literals",2350 ":__support_macros_optimization",2351 ],2352)2353 2354libc_support_library(2355 name = "__support_math_asin",2356 hdrs = ["src/__support/math/asin.h"],2357 deps = [2358 ":__support_fputil_double_double",2359 ":__support_fputil_dyadic_float",2360 ":__support_fputil_fenv_impl",2361 ":__support_fputil_fp_bits",2362 ":__support_fputil_multiply_add",2363 ":__support_fputil_polyeval",2364 ":__support_fputil_sqrt",2365 ":__support_macros_optimization",2366 ":__support_macros_properties_cpu_features",2367 ":__support_math_asin_utils",2368 ],2369)2370 2371libc_support_library(2372 name = "__support_math_asinhf",2373 hdrs = ["src/__support/math/asinhf.h"],2374 deps = [2375 ":__support_fputil_fp_bits",2376 ":__support_fputil_multiply_add",2377 ":__support_fputil_polyeval",2378 ":__support_fputil_sqrt",2379 ":__support_macros_config",2380 ":__support_macros_optimization",2381 ":__support_math_acoshf_utils",2382 ],2383)2384 2385libc_support_library(2386 name = "__support_math_asinhf16",2387 hdrs = ["src/__support/math/asinhf16.h"],2388 deps = [2389 ":__support_fputil_cast",2390 ":__support_fputil_except_value_utils",2391 ":__support_fputil_fenv_impl",2392 ":__support_fputil_fp_bits",2393 ":__support_fputil_multiply_add",2394 ":__support_fputil_polyeval",2395 ":__support_fputil_rounding_mode",2396 ":__support_fputil_sqrt",2397 ":__support_macros_config",2398 ":__support_macros_optimization",2399 ":__support_math_acoshf_utils",2400 ],2401)2402 2403libc_support_library(2404 name = "__support_math_atan_utils",2405 hdrs = ["src/__support/math/atan_utils.h"],2406 deps = [2407 ":__support_fputil_double_double",2408 ":__support_fputil_dyadic_float",2409 ":__support_fputil_multiply_add",2410 ":__support_fputil_polyeval",2411 ":__support_integer_literals",2412 ":__support_macros_optimization",2413 ],2414)2415 2416libc_support_library(2417 name = "__support_math_atan",2418 hdrs = ["src/__support/math/atan.h"],2419 deps = [2420 ":__support_fputil_double_double",2421 ":__support_fputil_nearest_integer",2422 ":__support_macros_optimization",2423 ":__support_math_atan_utils",2424 ],2425)2426 2427libc_support_library(2428 name = "__support_math_atan2",2429 hdrs = ["src/__support/math/atan2.h"],2430 deps = [2431 ":__support_fputil_double_double",2432 ":__support_fputil_nearest_integer",2433 ":__support_math_atan_utils",2434 ],2435)2436 2437libc_support_library(2438 name = "__support_math_atan2f",2439 hdrs = ["src/__support/math/atan2f.h"],2440 deps = [2441 ":__support_fputil_double_double",2442 ":__support_fputil_fenv_impl",2443 ":__support_fputil_fp_bits",2444 ":__support_fputil_multiply_add",2445 ":__support_fputil_nearest_integer",2446 ":__support_fputil_polyeval",2447 ":__support_macros_config",2448 ":__support_macros_optimization",2449 ":__support_math_inv_trigf_utils",2450 ],2451)2452 2453libc_support_library(2454 name = "__support_math_atan2f128",2455 hdrs = ["src/__support/math/atan2f128.h"],2456 deps = [2457 ":__support_fputil_dyadic_float",2458 ":__support_fputil_fp_bits",2459 ":__support_fputil_nearest_integer",2460 ":__support_integer_literals",2461 ":__support_macros_config",2462 ":__support_macros_optimization",2463 ":__support_math_atan_utils",2464 ":__support_uint128",2465 ],2466)2467 2468libc_support_library(2469 name = "__support_math_atanf",2470 hdrs = ["src/__support/math/atanf.h"],2471 deps = [2472 ":__support_fputil_except_value_utils",2473 ":__support_fputil_multiply_add",2474 ":__support_fputil_nearest_integer",2475 ":__support_fputil_polyeval",2476 ":__support_fputil_rounding_mode",2477 ":__support_macros_optimization",2478 ":__support_math_inv_trigf_utils",2479 ],2480)2481 2482libc_support_library(2483 name = "__support_math_atanf16",2484 hdrs = ["src/__support/math/atanf16.h"],2485 deps = [2486 ":__support_fputil_cast",2487 ":__support_fputil_except_value_utils",2488 ":__support_fputil_fenv_impl",2489 ":__support_fputil_fp_bits",2490 ":__support_fputil_multiply_add",2491 ":__support_fputil_polyeval",2492 ":__support_fputil_sqrt",2493 ":__support_macros_optimization",2494 ],2495)2496 2497libc_support_library(2498 name = "__support_math_asinf",2499 hdrs = ["src/__support/math/asinf.h"],2500 deps = [2501 ":__support_fputil_except_value_utils",2502 ":__support_fputil_fenv_impl",2503 ":__support_fputil_fp_bits",2504 ":__support_fputil_multiply_add",2505 ":__support_fputil_sqrt",2506 ":__support_macros_config",2507 ":__support_macros_optimization",2508 ":__support_macros_properties_cpu_features",2509 ":__support_math_inv_trigf_utils",2510 ],2511)2512 2513libc_support_library(2514 name = "__support_math_asinf16",2515 hdrs = ["src/__support/math/asinf16.h"],2516 deps = [2517 ":__support_fputil_fenv_impl",2518 ":__support_fputil_fp_bits",2519 ":__support_fputil_multiply_add",2520 ":__support_fputil_polyeval",2521 ":__support_fputil_sqrt",2522 ":__support_macros_optimization",2523 ],2524)2525 2526libc_support_library(2527 name = "__support_math_atanhf",2528 hdrs = ["src/__support/math/atanhf.h"],2529 deps = [2530 ":__support_fputil_fenv_impl",2531 ":__support_fputil_fp_bits",2532 ":__support_macros_config",2533 ":__support_macros_optimization",2534 ":__support_math_acoshf_utils",2535 ],2536)2537 2538libc_support_library(2539 name = "__support_math_atanhf16",2540 hdrs = ["src/__support/math/atanhf16.h"],2541 deps = [2542 ":__support_fputil_cast",2543 ":__support_fputil_except_value_utils",2544 ":__support_fputil_fenv_impl",2545 ":__support_fputil_fp_bits",2546 ":__support_fputil_multiply_add",2547 ":__support_fputil_polyeval",2548 ":__support_macros_config",2549 ":__support_macros_optimization",2550 ],2551)2552 2553libc_support_library(2554 name = "__support_math_cbrt",2555 hdrs = ["src/__support/math/cbrt.h"],2556 deps = [2557 ":__support_fputil_double_double",2558 ":__support_fputil_dyadic_float",2559 ":__support_fputil_fenv_impl",2560 ":__support_fputil_polyeval",2561 ":__support_integer_literals",2562 ],2563)2564 2565libc_support_library(2566 name = "__support_math_cbrtf",2567 hdrs = ["src/__support/math/cbrtf.h"],2568 deps = [2569 ":__support_fputil_double_double",2570 ":__support_fputil_dyadic_float",2571 ":__support_fputil_fenv_impl",2572 ":__support_fputil_polyeval",2573 ":__support_integer_literals",2574 ],2575)2576 2577libc_support_library(2578 name = "__support_math_common_constants",2579 hdrs = ["src/__support/math/common_constants.h"],2580 deps = [2581 ":__support_math_acosh_float_constants",2582 ":__support_math_exp_constants",2583 ":__support_number_pair",2584 ],2585)2586 2587libc_support_library(2588 name = "__support_math_cos",2589 hdrs = ["src/__support/math/cos.h"],2590 deps = [2591 ":__support_fputil_except_value_utils",2592 ":__support_fputil_multiply_add",2593 ":__support_macros_optimization",2594 ":__support_macros_properties_cpu_features",2595 ":__support_range_reduction_double",2596 ":__support_sincos_eval",2597 ],2598)2599 2600libc_support_library(2601 name = "__support_math_cosf",2602 hdrs = ["src/__support/math/cosf.h"],2603 deps = [2604 ":__support_fputil_except_value_utils",2605 ":__support_macros_optimization",2606 ":__support_macros_properties_cpu_features",2607 ":__support_sincosf_utils",2608 ":errno",2609 ],2610)2611 2612libc_support_library(2613 name = "__support_math_cosf16",2614 hdrs = ["src/__support/math/cosf16.h"],2615 deps = [2616 ":__support_fputil_cast",2617 ":__support_fputil_except_value_utils",2618 ":__support_fputil_fenv_impl",2619 ":__support_fputil_multiply_add",2620 ":__support_macros_optimization",2621 ":__support_math_sincosf16_utils",2622 ":errno",2623 ],2624)2625 2626libc_support_library(2627 name = "__support_math_coshf",2628 hdrs = ["src/__support/math/coshf.h"],2629 deps = [2630 ":__support_fputil_fp_bits",2631 ":__support_fputil_multiply_add",2632 ":__support_fputil_rounding_mode",2633 ":__support_macros_optimization",2634 ":__support_math_sinhfcoshf_utils",2635 ],2636)2637 2638libc_support_library(2639 name = "__support_math_coshf16",2640 hdrs = ["src/__support/math/coshf16.h"],2641 deps = [2642 ":__support_fputil_except_value_utils",2643 ":__support_fputil_fenv_impl",2644 ":__support_fputil_fp_bits",2645 ":__support_fputil_rounding_mode",2646 ":__support_macros_config",2647 ":__support_macros_optimization",2648 ":__support_math_expxf16_utils",2649 ],2650)2651 2652libc_support_library(2653 name = "__support_math_cospif",2654 hdrs = ["src/__support/math/cospif.h"],2655 deps = [2656 ":__support_fputil_fma",2657 ":__support_fputil_multiply_add",2658 ":__support_fputil_nearest_integer",2659 ":__support_fputil_polyeval",2660 ":__support_fputil_rounding_mode",2661 ":__support_macros_optimization",2662 ":__support_math_common_constants",2663 ":__support_sincosf_utils",2664 ],2665)2666 2667libc_support_library(2668 name = "__support_math_cospif16",2669 hdrs = ["src/__support/math/cospif16.h"],2670 deps = [2671 ":__support_fputil_cast",2672 ":__support_fputil_fenv_impl",2673 ":__support_fputil_multiply_add",2674 ":__support_macros_optimization",2675 ":__support_math_sincosf16_utils",2676 ],2677)2678 2679libc_support_library(2680 name = "__support_math_dsqrtl",2681 hdrs = ["src/__support/math/dsqrtl.h"],2682 deps = [2683 ":__support_fputil_sqrt",2684 ],2685)2686 2687libc_support_library(2688 name = "__support_math_exp10m1f",2689 hdrs = ["src/__support/math/exp10m1f.h"],2690 deps = [2691 ":__support_fputil_except_value_utils",2692 ":__support_fputil_fenv_impl",2693 ":__support_fputil_fp_bits",2694 ":__support_fputil_multiply_add",2695 ":__support_fputil_polyeval",2696 ":__support_fputil_rounding_mode",2697 ":__support_macros_optimization",2698 ":__support_math_exp10f_utils",2699 ":errno",2700 ],2701)2702 2703libc_support_library(2704 name = "__support_math_exp10m1f16",2705 hdrs = ["src/__support/math/exp10m1f16.h"],2706 deps = [2707 ":__support_fputil_except_value_utils",2708 ":__support_fputil_fenv_impl",2709 ":__support_fputil_fp_bits",2710 ":__support_fputil_multiply_add",2711 ":__support_fputil_polyeval",2712 ":__support_fputil_rounding_mode",2713 ":__support_macros_optimization",2714 ":__support_math_exp10f16_utils",2715 ":errno",2716 ],2717)2718 2719libc_support_library(2720 name = "__support_math_erff",2721 hdrs = ["src/__support/math/erff.h"],2722 deps = [2723 ":__support_fputil_except_value_utils",2724 ":__support_fputil_fp_bits",2725 ":__support_fputil_multiply_add",2726 ":__support_fputil_polyeval",2727 ":__support_macros_optimization",2728 ],2729)2730 2731libc_support_library(2732 name = "__support_math_exp_float_constants",2733 hdrs = ["src/__support/math/exp_float_constants.h"],2734 deps = [2735 ":__support_macros_config",2736 ],2737)2738 2739libc_support_library(2740 name = "__support_math_expf",2741 hdrs = ["src/__support/math/expf.h"],2742 deps = [2743 ":__support_common",2744 ":__support_fputil_fenv_impl",2745 ":__support_fputil_fp_bits",2746 ":__support_fputil_multiply_add",2747 ":__support_fputil_nearest_integer",2748 ":__support_fputil_polyeval",2749 ":__support_fputil_rounding_mode",2750 ":__support_libc_errno",2751 ":__support_macros_config",2752 ":__support_macros_optimization",2753 ":__support_math_exp_float_constants",2754 ],2755)2756 2757libc_support_library(2758 name = "__support_math_expf16_utils",2759 hdrs = ["src/__support/math/expf16_utils.h"],2760 deps = [2761 ":__support_cpp_array",2762 ":__support_fputil_nearest_integer",2763 ":__support_fputil_polyeval",2764 ":__support_macros_attributes",2765 ":llvm_libc_macros_float16_macros",2766 ],2767)2768 2769libc_support_library(2770 name = "__support_math_expf16",2771 hdrs = ["src/__support/math/expf16.h"],2772 deps = [2773 ":__support_common",2774 ":__support_cpp_array",2775 ":__support_fputil_cast",2776 ":__support_fputil_except_value_utils",2777 ":__support_fputil_fenv_impl",2778 ":__support_fputil_fp_bits",2779 ":__support_fputil_multiply_add",2780 ":__support_fputil_nearest_integer",2781 ":__support_fputil_polyeval",2782 ":__support_fputil_rounding_mode",2783 ":__support_libc_errno",2784 ":__support_macros_optimization",2785 ":__support_math_expf16_utils",2786 ":llvm_libc_macros_float16_macros",2787 ],2788)2789 2790libc_support_library(2791 name = "__support_math_expxf16_utils",2792 hdrs = ["src/__support/math/expxf16_utils.h"],2793 deps = [2794 ":__support_fputil_cast",2795 ":__support_fputil_fp_bits",2796 ":__support_fputil_nearest_integer",2797 ":__support_math_exp10_float16_constants",2798 ":__support_math_expf16_utils",2799 ],2800)2801 2802libc_support_library(2803 name = "__support_math_frexpf128",2804 hdrs = ["src/__support/math/frexpf128.h"],2805 deps = [2806 ":__support_fputil_manipulation_functions",2807 ":__support_macros_properties_types",2808 ],2809)2810 2811libc_support_library(2812 name = "__support_math_inv_trigf_utils",2813 hdrs = ["src/__support/math/inv_trigf_utils.h"],2814 deps = [2815 ":__support_common",2816 ":__support_fputil_multiply_add",2817 ":__support_fputil_polyeval",2818 ],2819)2820 2821libc_support_library(2822 name = "__support_math_frexpf16",2823 hdrs = ["src/__support/math/frexpf16.h"],2824 deps = [2825 ":__support_fputil_manipulation_functions",2826 ":__support_macros_config",2827 ":__support_macros_properties_types",2828 ":llvm_libc_macros_float16_macros",2829 ],2830)2831 2832libc_support_library(2833 name = "__support_math_frexpf",2834 hdrs = ["src/__support/math/frexpf.h"],2835 deps = [2836 ":__support_fputil_manipulation_functions",2837 ],2838)2839 2840libc_support_library(2841 name = "__support_math_ldexpf128",2842 hdrs = ["src/__support/math/ldexpf128.h"],2843 deps = [2844 ":__support_fputil_manipulation_functions",2845 ":__support_macros_properties_types",2846 ":llvm_libc_types_float128",2847 ],2848)2849 2850libc_support_library(2851 name = "__support_math_ldexpf16",2852 hdrs = ["src/__support/math/ldexpf16.h"],2853 deps = [2854 ":__support_fputil_manipulation_functions",2855 ":__support_macros_properties_types",2856 ":llvm_libc_macros_float16_macros",2857 ],2858)2859 2860libc_support_library(2861 name = "__support_math_ldexpf",2862 hdrs = ["src/__support/math/ldexpf.h"],2863 deps = [2864 ":__support_fputil_manipulation_functions",2865 ],2866)2867 2868libc_support_library(2869 name = "__support_math_exp_constants",2870 hdrs = ["src/__support/math/exp_constants.h"],2871 deps = [2872 ":__support_fputil_triple_double",2873 ],2874)2875 2876libc_support_library(2877 name = "__support_math_exp_utils",2878 hdrs = ["src/__support/math/exp_utils.h"],2879 deps = [2880 ":__support_cpp_bit",2881 ":__support_cpp_optional",2882 ":__support_fputil_fp_bits",2883 ],2884)2885 2886libc_support_library(2887 name = "__support_math_exp",2888 hdrs = ["src/__support/math/exp.h"],2889 deps = [2890 ":__support_cpp_bit",2891 ":__support_cpp_optional",2892 ":__support_fputil_double_double",2893 ":__support_fputil_dyadic_float",2894 ":__support_fputil_fenv_impl",2895 ":__support_fputil_fp_bits",2896 ":__support_fputil_multiply_add",2897 ":__support_fputil_nearest_integer",2898 ":__support_fputil_polyeval",2899 ":__support_fputil_rounding_mode",2900 ":__support_fputil_triple_double",2901 ":__support_integer_literals",2902 ":__support_macros_optimization",2903 ":__support_math_exp_constants",2904 ":__support_math_exp_utils",2905 ],2906)2907 2908libc_support_library(2909 name = "__support_math_exp2",2910 hdrs = ["src/__support/math/exp2.h"],2911 deps = [2912 ":__support_fputil_double_double",2913 ":__support_fputil_dyadic_float",2914 ":__support_fputil_multiply_add",2915 ":__support_fputil_nearest_integer",2916 ":__support_fputil_polyeval",2917 ":__support_fputil_rounding_mode",2918 ":__support_fputil_triple_double",2919 ":__support_integer_literals",2920 ":__support_macros_optimization",2921 ":__support_math_common_constants",2922 ":__support_math_exp_utils",2923 ],2924)2925 2926libc_support_library(2927 name = "__support_math_exp2f",2928 hdrs = ["src/__support/math/exp2f.h"],2929 deps = [2930 ":__support_fputil_except_value_utils",2931 ":__support_fputil_fma",2932 ":__support_fputil_multiply_add",2933 ":__support_fputil_nearest_integer",2934 ":__support_fputil_polyeval",2935 ":__support_fputil_rounding_mode",2936 ":__support_macros_optimization",2937 ":__support_math_common_constants",2938 ":__support_math_exp10f_utils",2939 ],2940)2941 2942libc_support_library(2943 name = "__support_math_exp2f16",2944 hdrs = ["src/__support/math/exp2f16.h"],2945 deps = [2946 ":__support_fputil_except_value_utils",2947 ":__support_fputil_fma",2948 ":__support_fputil_multiply_add",2949 ":__support_fputil_nearest_integer",2950 ":__support_fputil_polyeval",2951 ":__support_fputil_rounding_mode",2952 ":__support_macros_optimization",2953 ":__support_math_common_constants",2954 ":__support_math_expxf16_utils",2955 ],2956)2957 2958libc_support_library(2959 name = "__support_math_exp2m1f",2960 hdrs = ["src/__support/math/exp2m1f.h"],2961 deps = [2962 ":__support_fputil_except_value_utils",2963 ":__support_fputil_fma",2964 ":__support_fputil_multiply_add",2965 ":__support_fputil_nearest_integer",2966 ":__support_fputil_polyeval",2967 ":__support_fputil_rounding_mode",2968 ":__support_macros_optimization",2969 ":__support_math_common_constants",2970 ":__support_math_exp10f_utils",2971 ],2972)2973 2974libc_support_library(2975 name = "__support_math_exp2m1f16",2976 hdrs = ["src/__support/math/exp2m1f16.h"],2977 deps = [2978 ":__support_fputil_except_value_utils",2979 ":__support_fputil_fma",2980 ":__support_fputil_multiply_add",2981 ":__support_fputil_nearest_integer",2982 ":__support_fputil_polyeval",2983 ":__support_fputil_rounding_mode",2984 ":__support_macros_optimization",2985 ":__support_math_common_constants",2986 ":__support_math_expxf16_utils",2987 ],2988)2989 2990libc_support_library(2991 name = "__support_math_exp10",2992 hdrs = ["src/__support/math/exp10.h"],2993 deps = [2994 ":__support_fputil_double_double",2995 ":__support_fputil_dyadic_float",2996 ":__support_fputil_multiply_add",2997 ":__support_fputil_nearest_integer",2998 ":__support_fputil_polyeval",2999 ":__support_fputil_rounding_mode",3000 ":__support_fputil_triple_double",3001 ":__support_integer_literals",3002 ":__support_macros_optimization",3003 ":__support_math_exp_constants",3004 ":__support_math_exp_utils",3005 ],3006)3007 3008libc_support_library(3009 name = "__support_math_exp10f_utils",3010 hdrs = ["src/__support/math/exp10f_utils.h"],3011 deps = [3012 ":__support_common",3013 ":__support_fputil_basic_operations",3014 ":__support_fputil_fenv_impl",3015 ":__support_fputil_multiply_add",3016 ":__support_fputil_nearest_integer",3017 ":__support_fputil_polyeval",3018 ":__support_math_exp_utils",3019 ],3020)3021 3022libc_support_library(3023 name = "__support_math_exp10f",3024 hdrs = ["src/__support/math/exp10f.h"],3025 deps = [3026 ":__support_fputil_fenv_impl",3027 ":__support_fputil_fp_bits",3028 ":__support_fputil_multiply_add",3029 ":__support_fputil_rounding_mode",3030 ":__support_macros_optimization",3031 ":__support_math_exp10f_utils",3032 ],3033)3034 3035libc_support_library(3036 name = "__support_math_exp10_float16_constants",3037 hdrs = ["src/__support/math/exp10_float16_constants.h"],3038 deps = [3039 ":__support_cpp_array",3040 ],3041)3042 3043libc_support_library(3044 name = "__support_math_exp10f16_utils",3045 hdrs = ["src/__support/math/exp10f16_utils.h"],3046 deps = [3047 ":__support_fputil_fp_bits",3048 ":__support_math_exp10_float16_constants",3049 ":__support_math_expf16_utils",3050 ],3051)3052 3053libc_support_library(3054 name = "__support_math_exp10f16",3055 hdrs = ["src/__support/math/exp10f16.h"],3056 deps = [3057 ":__support_fputil_cast",3058 ":__support_fputil_except_value_utils",3059 ":__support_fputil_fp_bits",3060 ":__support_fputil_rounding_mode",3061 ":__support_macros_optimization",3062 ":__support_macros_properties_cpu_features",3063 ":__support_math_exp10f16_utils",3064 ],3065)3066 3067libc_support_library(3068 name = "__support_range_reduction_double",3069 hdrs = [3070 "src/__support/math/range_reduction_double_common.h",3071 "src/__support/math/range_reduction_double_fma.h",3072 "src/__support/math/range_reduction_double_nofma.h",3073 ],3074 deps = [3075 ":__support_common",3076 ":__support_fputil_double_double",3077 ":__support_fputil_dyadic_float",3078 ":__support_fputil_fp_bits",3079 ":__support_fputil_multiply_add",3080 ":__support_fputil_nearest_integer",3081 ":__support_fputil_rounding_mode",3082 ":__support_integer_literals",3083 ],3084)3085 3086libc_support_library(3087 name = "__support_range_reduction",3088 hdrs = [3089 "src/__support/math/range_reduction.h",3090 "src/__support/math/range_reduction_fma.h",3091 ],3092 deps = [3093 ":__support_common",3094 ":__support_fputil_fma",3095 ":__support_fputil_fp_bits",3096 ":__support_fputil_multiply_add",3097 ":__support_fputil_nearest_integer",3098 ],3099)3100 3101libc_support_library(3102 name = "__support_sincos_eval",3103 hdrs = [3104 "src/__support/math/sincos_eval.h",3105 ],3106 deps = [3107 ":__support_common",3108 ":__support_fputil_double_double",3109 ":__support_fputil_dyadic_float",3110 ":__support_fputil_fp_bits",3111 ":__support_fputil_multiply_add",3112 ":__support_fputil_polyeval",3113 ":__support_integer_literals",3114 ],3115)3116 3117libc_support_library(3118 name = "__support_sincosf_utils",3119 hdrs = [3120 "src/__support/math/sincosf_float_eval.h",3121 "src/__support/math/sincosf_utils.h",3122 ],3123 deps = [3124 ":__support_fputil_double_double",3125 ":__support_fputil_fp_bits",3126 ":__support_fputil_polyeval",3127 ":__support_range_reduction",3128 ],3129)3130 3131libc_support_library(3132 name = "__support_math_sincosf16_utils",3133 hdrs = ["src/__support/math/sincosf16_utils.h"],3134 deps = [3135 ":__support_common",3136 ":__support_fputil_nearest_integer",3137 ":__support_fputil_polyeval",3138 ],3139)3140 3141libc_support_library(3142 name = "__support_math_sinhfcoshf_utils",3143 hdrs = ["src/__support/math/sinhfcoshf_utils.h"],3144 deps = [3145 ":__support_fputil_multiply_add",3146 ":__support_math_exp10f_utils",3147 ],3148)3149 3150############################### complex targets ################################3151 3152libc_function(3153 name = "cimag",3154 srcs = ["src/complex/generic/cimag.cpp"],3155 hdrs = ["src/complex/cimag.h"],3156 deps = [3157 ":__support_common",3158 ":__support_complex_type",3159 ":__support_cpp_bit",3160 ":__support_macros_config",3161 ],3162)3163 3164libc_function(3165 name = "cimagf",3166 srcs = ["src/complex/generic/cimagf.cpp"],3167 hdrs = ["src/complex/cimagf.h"],3168 deps = [3169 ":__support_common",3170 ":__support_complex_type",3171 ":__support_cpp_bit",3172 ":__support_macros_config",3173 ],3174)3175 3176libc_function(3177 name = "cimagf128",3178 srcs = ["src/complex/generic/cimagf128.cpp"],3179 hdrs = ["src/complex/cimagf128.h"],3180 deps = [3181 ":__support_common",3182 ":__support_complex_type",3183 ":__support_cpp_bit",3184 ":__support_macros_config",3185 ":__support_macros_properties_complex_types",3186 ":__support_macros_properties_types",3187 ],3188)3189 3190libc_function(3191 name = "cimagf16",3192 srcs = ["src/complex/generic/cimagf16.cpp"],3193 hdrs = ["src/complex/cimagf16.h"],3194 deps = [3195 ":__support_common",3196 ":__support_complex_type",3197 ":__support_cpp_bit",3198 ":__support_macros_config",3199 ":__support_macros_properties_complex_types",3200 ":__support_macros_properties_types",3201 ],3202)3203 3204libc_function(3205 name = "cimagl",3206 srcs = ["src/complex/generic/cimagl.cpp"],3207 hdrs = ["src/complex/cimagl.h"],3208 deps = [3209 ":__support_common",3210 ":__support_complex_type",3211 ":__support_cpp_bit",3212 ":__support_macros_config",3213 ],3214)3215 3216libc_function(3217 name = "conj",3218 srcs = ["src/complex/generic/conj.cpp"],3219 hdrs = ["src/complex/conj.h"],3220 deps = [3221 ":__support_common",3222 ":__support_complex_basic_ops",3223 ":__support_macros_config",3224 ],3225)3226 3227libc_function(3228 name = "conjf",3229 srcs = ["src/complex/generic/conjf.cpp"],3230 hdrs = ["src/complex/conjf.h"],3231 deps = [3232 ":__support_common",3233 ":__support_complex_basic_ops",3234 ":__support_macros_config",3235 ],3236)3237 3238libc_function(3239 name = "conjf128",3240 srcs = ["src/complex/generic/conjf128.cpp"],3241 hdrs = ["src/complex/conjf128.h"],3242 deps = [3243 ":__support_common",3244 ":__support_complex_basic_ops",3245 ":__support_macros_config",3246 ":__support_macros_properties_complex_types",3247 ],3248)3249 3250libc_function(3251 name = "conjf16",3252 srcs = ["src/complex/generic/conjf16.cpp"],3253 hdrs = ["src/complex/conjf16.h"],3254 deps = [3255 ":__support_common",3256 ":__support_complex_basic_ops",3257 ":__support_cpp_bit",3258 ":__support_macros_config",3259 ":__support_macros_properties_complex_types",3260 ],3261)3262 3263libc_function(3264 name = "conjl",3265 srcs = ["src/complex/generic/conjl.cpp"],3266 hdrs = ["src/complex/conjl.h"],3267 deps = [3268 ":__support_common",3269 ":__support_complex_basic_ops",3270 ":__support_macros_config",3271 ],3272)3273 3274libc_function(3275 name = "cproj",3276 srcs = ["src/complex/generic/cproj.cpp"],3277 hdrs = ["src/complex/cproj.h"],3278 deps = [3279 ":__support_common",3280 ":__support_complex_basic_ops",3281 ":__support_macros_config",3282 ],3283)3284 3285libc_function(3286 name = "cprojf",3287 srcs = ["src/complex/generic/cprojf.cpp"],3288 hdrs = ["src/complex/cprojf.h"],3289 deps = [3290 ":__support_common",3291 ":__support_complex_basic_ops",3292 ":__support_macros_config",3293 ],3294)3295 3296libc_function(3297 name = "cprojf128",3298 srcs = ["src/complex/generic/cprojf128.cpp"],3299 hdrs = ["src/complex/cprojf128.h"],3300 deps = [3301 ":__support_common",3302 ":__support_complex_basic_ops",3303 ":__support_macros_config",3304 ":__support_macros_properties_complex_types",3305 ],3306)3307 3308libc_function(3309 name = "cprojf16",3310 srcs = ["src/complex/generic/cprojf16.cpp"],3311 hdrs = ["src/complex/cprojf16.h"],3312 deps = [3313 ":__support_common",3314 ":__support_complex_basic_ops",3315 ":__support_macros_config",3316 ":__support_macros_properties_complex_types",3317 ],3318)3319 3320libc_function(3321 name = "cprojl",3322 srcs = ["src/complex/generic/cprojl.cpp"],3323 hdrs = ["src/complex/cprojl.h"],3324 deps = [3325 ":__support_common",3326 ":__support_complex_basic_ops",3327 ":__support_macros_config",3328 ],3329)3330 3331libc_function(3332 name = "creal",3333 srcs = ["src/complex/generic/creal.cpp"],3334 hdrs = ["src/complex/creal.h"],3335 deps = [3336 ":__support_common",3337 ":__support_complex_type",3338 ":__support_cpp_bit",3339 ":__support_macros_config",3340 ],3341)3342 3343libc_function(3344 name = "crealf",3345 srcs = ["src/complex/generic/crealf.cpp"],3346 hdrs = ["src/complex/crealf.h"],3347 deps = [3348 ":__support_common",3349 ":__support_complex_type",3350 ":__support_cpp_bit",3351 ":__support_macros_config",3352 ],3353)3354 3355libc_function(3356 name = "crealf128",3357 srcs = ["src/complex/generic/crealf128.cpp"],3358 hdrs = ["src/complex/crealf128.h"],3359 deps = [3360 ":__support_common",3361 ":__support_complex_type",3362 ":__support_cpp_bit",3363 ":__support_macros_config",3364 ":__support_macros_properties_complex_types",3365 ],3366)3367 3368libc_function(3369 name = "crealf16",3370 srcs = ["src/complex/generic/crealf16.cpp"],3371 hdrs = ["src/complex/crealf16.h"],3372 deps = [3373 ":__support_common",3374 ":__support_complex_type",3375 ":__support_cpp_bit",3376 ":__support_macros_config",3377 ":__support_macros_properties_complex_types",3378 ],3379)3380 3381libc_function(3382 name = "creall",3383 srcs = ["src/complex/generic/creall.cpp"],3384 hdrs = ["src/complex/creall.h"],3385 deps = [3386 ":__support_common",3387 ":__support_complex_type",3388 ":__support_cpp_bit",3389 ":__support_macros_config",3390 ],3391)3392 3393################################ math targets ##################################3394 3395libc_math_function(3396 name = "acos",3397 additional_deps = [3398 ":__support_math_acos",3399 ],3400)3401 3402libc_math_function(3403 name = "acosf",3404 additional_deps = [3405 ":__support_math_acosf",3406 ],3407)3408 3409libc_math_function(3410 name = "acosf16",3411 additional_deps = [3412 ":__support_math_acosf16",3413 ":errno",3414 ],3415)3416 3417libc_math_function(3418 name = "acoshf",3419 additional_deps = [3420 ":__support_math_acoshf",3421 ],3422)3423 3424libc_math_function(3425 name = "acoshf16",3426 additional_deps = [3427 ":__support_math_acoshf16",3428 ":errno",3429 ],3430)3431 3432libc_math_function(3433 name = "acospif16",3434 additional_deps = [3435 ":__support_math_acospif16",3436 ":errno",3437 ],3438)3439 3440libc_math_function(3441 name = "asin",3442 additional_deps = [3443 ":__support_math_asin",3444 ],3445)3446 3447libc_math_function(3448 name = "asinf",3449 additional_deps = [3450 ":__support_math_asinf",3451 ],3452)3453 3454libc_math_function(3455 name = "asinf16",3456 additional_deps = [3457 ":__support_math_asinf16",3458 ],3459)3460 3461libc_math_function(3462 name = "asinhf",3463 additional_deps = [3464 ":__support_math_asinhf",3465 ],3466)3467 3468libc_math_function(3469 name = "asinhf16",3470 additional_deps = [3471 ":__support_math_asinhf16",3472 ],3473)3474 3475libc_math_function(3476 name = "atanf",3477 additional_deps = [3478 ":__support_math_atanf",3479 ],3480)3481 3482libc_math_function(3483 name = "atanf16",3484 additional_deps = [3485 ":__support_math_atanf16",3486 ],3487)3488 3489libc_math_function(3490 name = "atan",3491 additional_deps = [3492 ":__support_math_atan",3493 ],3494)3495 3496libc_math_function(3497 name = "atan2f",3498 additional_deps = [3499 ":__support_math_atan2f",3500 ],3501)3502 3503libc_math_function(3504 name = "atan2f128",3505 additional_deps = [3506 ":__support_math_atan2f128",3507 ],3508)3509 3510libc_math_function(3511 name = "atan2",3512 additional_deps = [3513 ":__support_math_atan2",3514 ],3515)3516 3517libc_math_function(3518 name = "atanhf",3519 additional_deps = [3520 ":__support_math_atanhf",3521 ],3522)3523 3524libc_math_function(3525 name = "atanhf16",3526 additional_deps = [3527 ":__support_math_atanhf16",3528 ],3529)3530 3531libc_math_function(name = "canonicalize")3532 3533libc_math_function(name = "canonicalizef")3534 3535libc_math_function(name = "canonicalizel")3536 3537libc_math_function(name = "canonicalizef128")3538 3539libc_math_function(name = "canonicalizef16")3540 3541libc_math_function(name = "iscanonical")3542 3543libc_math_function(name = "iscanonicalf")3544 3545libc_math_function(name = "iscanonicall")3546 3547libc_math_function(name = "iscanonicalf128")3548 3549libc_math_function(name = "iscanonicalf16")3550 3551libc_math_function(name = "issignaling")3552 3553libc_math_function(name = "issignalingf")3554 3555libc_math_function(name = "issignalingl")3556 3557libc_math_function(name = "issignalingf128")3558 3559libc_math_function(name = "issignalingf16")3560 3561libc_math_function(3562 name = "cbrt",3563 additional_deps = [3564 ":__support_math_cbrt",3565 ],3566)3567 3568libc_math_function(3569 name = "cbrtf",3570 additional_deps = [3571 ":__support_math_cbrtf",3572 ],3573)3574 3575libc_math_function(name = "ceil")3576 3577libc_math_function(name = "ceilf")3578 3579libc_math_function(name = "ceill")3580 3581libc_math_function(name = "ceilf128")3582 3583libc_math_function(name = "ceilf16")3584 3585libc_math_function(name = "copysign")3586 3587libc_math_function(name = "copysignf")3588 3589libc_math_function(name = "copysignl")3590 3591libc_math_function(name = "copysignf128")3592 3593libc_math_function(name = "copysignf16")3594 3595libc_math_function(3596 name = "cos",3597 additional_deps = [3598 ":__support_math_cos",3599 ],3600)3601 3602libc_math_function(3603 name = "cosf",3604 additional_deps = [3605 ":__support_math_cosf",3606 ],3607)3608 3609libc_math_function(3610 name = "cosf16",3611 additional_deps = [3612 ":__support_math_cosf16",3613 ],3614)3615 3616libc_math_function(3617 name = "coshf",3618 additional_deps = [3619 ":__support_math_coshf",3620 ],3621)3622 3623libc_math_function(3624 name = "coshf16",3625 additional_deps = [3626 ":__support_math_coshf16",3627 ],3628)3629 3630libc_math_function(3631 name = "cospif",3632 additional_deps = [3633 ":__support_math_cospif",3634 ],3635)3636 3637libc_math_function(3638 name = "cospif16",3639 additional_deps = [3640 ":__support_math_cospif16",3641 ],3642)3643 3644libc_math_function(name = "daddl")3645 3646libc_math_function(name = "daddf128")3647 3648libc_math_function(name = "ddivl")3649 3650libc_math_function(name = "ddivf128")3651 3652libc_math_function(3653 name = "dfmal",3654 additional_deps = [3655 ":__support_fputil_fma",3656 ],3657)3658 3659libc_math_function(3660 name = "dfmaf128",3661 additional_deps = [3662 ":__support_fputil_fma",3663 ],3664)3665 3666libc_math_function(name = "dmull")3667 3668libc_math_function(name = "dmulf128")3669 3670libc_math_function(3671 name = "dsqrtl",3672 additional_deps = [3673 ":__support_math_dsqrtl",3674 ],3675)3676 3677libc_math_function(3678 name = "dsqrtf128",3679 additional_deps = [3680 ":__support_fputil_sqrt",3681 ],3682)3683 3684libc_math_function(name = "dsubl")3685 3686libc_math_function(name = "dsubf128")3687 3688libc_math_function(3689 name = "erff",3690 additional_deps = [3691 ":__support_math_erff",3692 ],3693)3694 3695libc_math_function(3696 name = "exp",3697 additional_deps = [3698 ":__support_math_exp",3699 ":errno",3700 ],3701)3702 3703libc_math_function(3704 name = "expf",3705 additional_deps = [3706 ":__support_math_expf",3707 ":errno",3708 ],3709)3710 3711libc_math_function(3712 name = "expf16",3713 additional_deps = [3714 ":__support_math_expf16",3715 ":__support_math_expxf16_utils",3716 ],3717)3718 3719libc_math_function(3720 name = "exp10",3721 additional_deps = [3722 ":__support_math_exp10",3723 ":errno",3724 ],3725)3726 3727libc_math_function(3728 name = "exp10f",3729 additional_deps = [3730 ":__support_math_exp10f",3731 ":errno",3732 ],3733)3734 3735libc_math_function(3736 name = "exp10f16",3737 additional_deps = [3738 ":__support_math_exp10f16",3739 ":errno",3740 ],3741)3742 3743libc_math_function(3744 name = "exp10m1f16",3745 additional_deps = [3746 ":__support_math_exp10m1f16",3747 ],3748)3749 3750libc_math_function(3751 name = "exp10m1f",3752 additional_deps = [3753 ":__support_math_exp10m1f",3754 ],3755)3756 3757libc_math_function(3758 name = "exp2",3759 additional_deps = [3760 ":__support_math_exp2",3761 ],3762)3763 3764libc_math_function(3765 name = "exp2f",3766 additional_deps = [3767 ":__support_math_exp2f",3768 ],3769)3770 3771libc_math_function(3772 name = "exp2f16",3773 additional_deps = [3774 ":__support_math_exp2f16",3775 ],3776)3777 3778libc_math_function(3779 name = "exp2m1f",3780 additional_deps = [3781 ":__support_math_exp2m1f",3782 ],3783)3784 3785libc_math_function(3786 name = "exp2m1f16",3787 additional_deps = [3788 ":__support_math_exp2m1f16",3789 ],3790)3791 3792libc_math_function(3793 name = "expm1",3794 additional_deps = [3795 ":__support_fputil_double_double",3796 ":__support_fputil_dyadic_float",3797 ":__support_fputil_multiply_add",3798 ":__support_fputil_polyeval",3799 ":__support_fputil_rounding_mode",3800 ":__support_fputil_triple_double",3801 ":__support_integer_literals",3802 ":__support_macros_optimization",3803 ":__support_math_common_constants",3804 ],3805)3806 3807libc_math_function(3808 name = "expm1f",3809 additional_deps = [3810 ":__support_fputil_fma",3811 ":__support_fputil_multiply_add",3812 ":__support_fputil_nearest_integer",3813 ":__support_fputil_polyeval",3814 ":__support_fputil_rounding_mode",3815 ":__support_macros_optimization",3816 ":__support_macros_properties_cpu_features",3817 ":__support_math_common_constants",3818 ],3819)3820 3821libc_math_function(3822 name = "expm1f16",3823 additional_deps = [3824 ":__support_math_expxf16_utils",3825 ],3826)3827 3828libc_math_function(name = "f16add")3829 3830libc_math_function(name = "f16addf")3831 3832libc_math_function(name = "f16addf128")3833 3834libc_math_function(name = "f16addl")3835 3836libc_math_function(name = "f16div")3837 3838libc_math_function(name = "f16divf")3839 3840libc_math_function(name = "f16divf128")3841 3842libc_math_function(name = "f16divl")3843 3844libc_math_function(3845 name = "f16fma",3846 additional_deps = [3847 ":__support_fputil_fma",3848 ],3849)3850 3851libc_math_function(3852 name = "f16fmaf",3853 additional_deps = [3854 ":__support_fputil_fma",3855 ],3856)3857 3858libc_math_function(3859 name = "f16fmaf128",3860 additional_deps = [3861 ":__support_fputil_fma",3862 ],3863)3864 3865libc_math_function(3866 name = "f16fmal",3867 additional_deps = [3868 ":__support_fputil_fma",3869 ],3870)3871 3872libc_math_function(name = "f16mul")3873 3874libc_math_function(name = "f16mulf")3875 3876libc_math_function(name = "f16mulf128")3877 3878libc_math_function(name = "f16mull")3879 3880libc_math_function(3881 name = "f16sqrt",3882 additional_deps = [3883 ":__support_fputil_sqrt",3884 ],3885)3886 3887libc_math_function(3888 name = "f16sqrtf",3889 additional_deps = [3890 ":__support_fputil_sqrt",3891 ],3892)3893 3894libc_math_function(3895 name = "f16sqrtf128",3896 additional_deps = [3897 ":__support_fputil_sqrt",3898 ],3899)3900 3901libc_math_function(3902 name = "f16sqrtl",3903 additional_deps = [3904 ":__support_fputil_sqrt",3905 ],3906)3907 3908libc_math_function(name = "f16sub")3909 3910libc_math_function(name = "f16subf")3911 3912libc_math_function(name = "f16subf128")3913 3914libc_math_function(name = "f16subl")3915 3916libc_math_function(name = "fabs")3917 3918libc_math_function(name = "fabsf")3919 3920libc_math_function(name = "fabsl")3921 3922libc_math_function(name = "fabsf128")3923 3924libc_math_function(name = "fabsf16")3925 3926libc_math_function(name = "fadd")3927 3928libc_math_function(name = "faddl")3929 3930libc_math_function(name = "faddf128")3931 3932libc_math_function(name = "fdim")3933 3934libc_math_function(name = "fdimf")3935 3936libc_math_function(name = "fdiml")3937 3938libc_math_function(name = "fdimf128")3939 3940libc_math_function(name = "fdimf16")3941 3942libc_math_function(name = "fdiv")3943 3944libc_math_function(name = "fdivl")3945 3946libc_math_function(name = "fdivf128")3947 3948libc_math_function(3949 name = "ffma",3950 additional_deps = [3951 ":__support_fputil_fma",3952 ],3953)3954 3955libc_math_function(3956 name = "ffmal",3957 additional_deps = [3958 ":__support_fputil_fma",3959 ],3960)3961 3962libc_math_function(3963 name = "ffmaf128",3964 additional_deps = [3965 ":__support_fputil_fma",3966 ],3967)3968 3969libc_math_function(name = "floor")3970 3971libc_math_function(name = "floorf")3972 3973libc_math_function(name = "floorl")3974 3975libc_math_function(name = "floorf128")3976 3977libc_math_function(name = "floorf16")3978 3979libc_math_function(3980 name = "fma",3981 additional_deps = [3982 ":__support_fputil_fma",3983 ],3984)3985 3986libc_math_function(3987 name = "fmaf",3988 additional_deps = [3989 ":__support_fputil_fma",3990 ],3991)3992 3993libc_math_function(3994 name = "fmaf16",3995 additional_deps = [3996 ":__support_fputil_fma",3997 ],3998)3999 4000libc_math_function(name = "fmax")4001 4002libc_math_function(name = "fmaxf")4003 4004libc_math_function(name = "fmaxl")4005 4006libc_math_function(name = "fmaxf128")4007 4008libc_math_function(name = "fmaxf16")4009 4010libc_math_function(name = "fmaximum")4011 4012libc_math_function(name = "fmaximumf")4013 4014libc_math_function(name = "fmaximuml")4015 4016libc_math_function(name = "fmaximumf128")4017 4018libc_math_function(name = "fmaximumf16")4019 4020libc_math_function(name = "fmaximum_mag")4021 4022libc_math_function(name = "fmaximum_magf")4023 4024libc_math_function(name = "fmaximum_magl")4025 4026libc_math_function(name = "fmaximum_magf128")4027 4028libc_math_function(name = "fmaximum_magf16")4029 4030libc_math_function(name = "fmaximum_mag_num")4031 4032libc_math_function(name = "fmaximum_mag_numf")4033 4034libc_math_function(name = "fmaximum_mag_numl")4035 4036libc_math_function(name = "fmaximum_mag_numf128")4037 4038libc_math_function(name = "fmaximum_mag_numf16")4039 4040libc_math_function(name = "fmaximum_num")4041 4042libc_math_function(name = "fmaximum_numf")4043 4044libc_math_function(name = "fmaximum_numl")4045 4046libc_math_function(name = "fmaximum_numf128")4047 4048libc_math_function(name = "fmaximum_numf16")4049 4050libc_math_function(name = "fmin")4051 4052libc_math_function(name = "fminf")4053 4054libc_math_function(name = "fminl")4055 4056libc_math_function(name = "fminf128")4057 4058libc_math_function(name = "fminf16")4059 4060libc_math_function(name = "fminimum")4061 4062libc_math_function(name = "fminimumf")4063 4064libc_math_function(name = "fminimuml")4065 4066libc_math_function(name = "fminimumf128")4067 4068libc_math_function(name = "fminimumf16")4069 4070libc_math_function(name = "fminimum_mag")4071 4072libc_math_function(name = "fminimum_magf")4073 4074libc_math_function(name = "fminimum_magl")4075 4076libc_math_function(name = "fminimum_magf128")4077 4078libc_math_function(name = "fminimum_magf16")4079 4080libc_math_function(name = "fminimum_mag_num")4081 4082libc_math_function(name = "fminimum_mag_numf")4083 4084libc_math_function(name = "fminimum_mag_numl")4085 4086libc_math_function(name = "fminimum_mag_numf128")4087 4088libc_math_function(name = "fminimum_mag_numf16")4089 4090libc_math_function(name = "fminimum_num")4091 4092libc_math_function(name = "fminimum_numf")4093 4094libc_math_function(name = "fminimum_numl")4095 4096libc_math_function(name = "fminimum_numf128")4097 4098libc_math_function(name = "fminimum_numf16")4099 4100libc_math_function(4101 name = "fmod",4102 additional_deps = [4103 ":__support_fputil_generic_fmod",4104 ],4105)4106 4107libc_math_function(4108 name = "fmodbf16",4109 additional_deps = [4110 ":__support_fputil_bfloat16",4111 ":__support_fputil_generic_fmod",4112 ],4113)4114 4115libc_math_function(4116 name = "fmodf",4117 additional_deps = [4118 ":__support_fputil_generic_fmod",4119 ],4120)4121 4122libc_math_function(4123 name = "fmodl",4124 additional_deps = [4125 ":__support_fputil_generic_fmod",4126 ],4127)4128 4129libc_math_function(4130 name = "fmodf128",4131 additional_deps = [4132 ":__support_fputil_generic_fmod",4133 ],4134)4135 4136libc_math_function(4137 name = "fmodf16",4138 additional_deps = [4139 ":__support_fputil_generic_fmod",4140 ],4141)4142 4143libc_math_function(4144 name = "fmul",4145 additional_deps = [4146 ":__support_fputil_double_double",4147 ],4148)4149 4150libc_math_function(name = "fmull")4151 4152libc_math_function(name = "fmulf128")4153 4154libc_math_function(name = "frexp")4155 4156libc_math_function(4157 name = "frexpf",4158 additional_deps = [4159 ":__support_math_frexpf",4160 ],4161)4162 4163libc_math_function(name = "frexpl")4164 4165libc_math_function(4166 name = "frexpf128",4167 additional_deps = [4168 ":__support_math_frexpf128",4169 ],4170)4171 4172libc_math_function(4173 name = "frexpf16",4174 additional_deps = [4175 ":__support_math_frexpf16",4176 ],4177)4178 4179libc_math_function(name = "fromfp")4180 4181libc_math_function(name = "fromfpf")4182 4183libc_math_function(name = "fromfpl")4184 4185libc_math_function(name = "fromfpf128")4186 4187libc_math_function(name = "fromfpf16")4188 4189libc_math_function(name = "fromfpx")4190 4191libc_math_function(name = "fromfpxf")4192 4193libc_math_function(name = "fromfpxl")4194 4195libc_math_function(name = "fromfpxf128")4196 4197libc_math_function(name = "fromfpxf16")4198 4199libc_math_function(4200 name = "fsqrt",4201 additional_deps = [4202 ":__support_fputil_sqrt",4203 ],4204)4205 4206libc_math_function(4207 name = "fsqrtl",4208 additional_deps = [4209 ":__support_fputil_sqrt",4210 ],4211)4212 4213libc_math_function(4214 name = "fsqrtf128",4215 additional_deps = [4216 ":__support_fputil_sqrt",4217 ],4218)4219 4220libc_math_function(name = "fsub")4221 4222libc_math_function(name = "fsubl")4223 4224libc_math_function(name = "fsubf128")4225 4226libc_math_function(name = "getpayload")4227 4228libc_math_function(name = "getpayloadf")4229 4230libc_math_function(name = "getpayloadl")4231 4232libc_math_function(name = "getpayloadf128")4233 4234libc_math_function(name = "getpayloadf16")4235 4236libc_math_function(name = "hypot")4237 4238libc_math_function(4239 name = "hypotf",4240 additional_deps = [4241 ":__support_fputil_double_double",4242 ":__support_fputil_sqrt",4243 ],4244)4245 4246libc_math_function(4247 name = "hypotf16",4248 additional_deps = [4249 ":__support_fputil_multiply_add",4250 ":__support_fputil_sqrt",4251 ],4252)4253 4254libc_math_function(name = "ilogb")4255 4256libc_math_function(name = "ilogbf")4257 4258libc_math_function(name = "ilogbl")4259 4260libc_math_function(name = "ilogbf128")4261 4262libc_math_function(name = "ilogbf16")4263 4264libc_math_function(name = "ldexp")4265 4266libc_math_function(4267 name = "ldexpf",4268 additional_deps = [4269 ":__support_math_ldexpf",4270 ],4271)4272 4273libc_math_function(name = "ldexpl")4274 4275libc_math_function(4276 name = "ldexpf128",4277 additional_deps = [4278 ":__support_math_ldexpf128",4279 ],4280)4281 4282libc_math_function(4283 name = "ldexpf16",4284 additional_deps = [4285 ":__support_math_ldexpf16",4286 ],4287)4288 4289libc_math_function(name = "llogb")4290 4291libc_math_function(name = "llogbf")4292 4293libc_math_function(name = "llogbl")4294 4295libc_math_function(name = "llogbf128")4296 4297libc_math_function(name = "llogbf16")4298 4299libc_math_function(name = "llrint")4300 4301libc_math_function(name = "llrintf")4302 4303libc_math_function(name = "llrintl")4304 4305libc_math_function(name = "llrintf128")4306 4307libc_math_function(name = "llrintf16")4308 4309libc_math_function(name = "llround")4310 4311libc_math_function(name = "llroundf")4312 4313libc_math_function(name = "llroundl")4314 4315libc_math_function(name = "llroundf128")4316 4317libc_math_function(name = "llroundf16")4318 4319libc_math_function(4320 name = "log",4321 additional_deps = [4322 ":__support_fputil_double_double",4323 ":__support_fputil_dyadic_float",4324 ":__support_fputil_fma",4325 ":__support_fputil_multiply_add",4326 ":__support_fputil_polyeval",4327 ":__support_integer_literals",4328 ":__support_macros_optimization",4329 ":__support_macros_properties_cpu_features",4330 ":__support_math_common_constants",4331 ":log_range_reduction",4332 ],4333)4334 4335libc_math_function(4336 name = "logf",4337 additional_deps = [4338 ":__support_fputil_fma",4339 ":__support_fputil_multiply_add",4340 ":__support_fputil_polyeval",4341 ":__support_macros_optimization",4342 ":__support_macros_properties_cpu_features",4343 ":__support_math_common_constants",4344 ],4345)4346 4347libc_math_function(4348 name = "logf16",4349 additional_deps = [4350 ":__support_math_expxf16_utils",4351 ],4352)4353 4354libc_math_function(4355 name = "log10",4356 additional_deps = [4357 ":__support_fputil_double_double",4358 ":__support_fputil_dyadic_float",4359 ":__support_fputil_fma",4360 ":__support_fputil_multiply_add",4361 ":__support_fputil_polyeval",4362 ":__support_integer_literals",4363 ":__support_macros_optimization",4364 ":__support_macros_properties_cpu_features",4365 ":__support_math_common_constants",4366 ":log_range_reduction",4367 ],4368)4369 4370libc_math_function(4371 name = "log10f",4372 additional_deps = [4373 ":__support_fputil_fma",4374 ":__support_fputil_multiply_add",4375 ":__support_fputil_polyeval",4376 ":__support_macros_optimization",4377 ":__support_macros_properties_cpu_features",4378 ":__support_math_common_constants",4379 ],4380)4381 4382libc_math_function(4383 name = "log10f16",4384 additional_deps = [4385 ":__support_math_expxf16_utils",4386 ],4387)4388 4389libc_math_function(4390 name = "log1p",4391 additional_deps = [4392 ":__support_fputil_double_double",4393 ":__support_fputil_dyadic_float",4394 ":__support_fputil_fma",4395 ":__support_fputil_multiply_add",4396 ":__support_fputil_polyeval",4397 ":__support_integer_literals",4398 ":__support_macros_optimization",4399 ":__support_macros_properties_cpu_features",4400 ":__support_math_common_constants",4401 ],4402)4403 4404libc_math_function(4405 name = "log1pf",4406 additional_deps = [4407 ":__support_fputil_fma",4408 ":__support_fputil_multiply_add",4409 ":__support_fputil_polyeval",4410 ":__support_macros_optimization",4411 ":__support_macros_properties_cpu_features",4412 ":__support_math_common_constants",4413 ],4414)4415 4416libc_math_function(4417 name = "log2",4418 additional_deps = [4419 ":__support_fputil_double_double",4420 ":__support_fputil_dyadic_float",4421 ":__support_fputil_fma",4422 ":__support_fputil_multiply_add",4423 ":__support_fputil_polyeval",4424 ":__support_integer_literals",4425 ":__support_macros_optimization",4426 ":__support_macros_properties_cpu_features",4427 ":__support_math_common_constants",4428 ":log_range_reduction",4429 ],4430)4431 4432libc_math_function(4433 name = "log2f",4434 additional_deps = [4435 ":__support_fputil_fma",4436 ":__support_fputil_multiply_add",4437 ":__support_fputil_polyeval",4438 ":__support_macros_optimization",4439 ":__support_math_common_constants",4440 ],4441)4442 4443libc_math_function(4444 name = "log2f16",4445 additional_deps = [4446 ":__support_math_expxf16_utils",4447 ],4448)4449 4450libc_math_function(name = "logb")4451 4452libc_math_function(name = "logbf")4453 4454libc_math_function(name = "logbl")4455 4456libc_math_function(name = "logbf128")4457 4458libc_math_function(name = "logbf16")4459 4460libc_math_function(name = "lrint")4461 4462libc_math_function(name = "lrintf")4463 4464libc_math_function(name = "lrintl")4465 4466libc_math_function(name = "lrintf128")4467 4468libc_math_function(name = "lrintf16")4469 4470libc_math_function(name = "lround")4471 4472libc_math_function(name = "lroundf")4473 4474libc_math_function(name = "lroundl")4475 4476libc_math_function(name = "lroundf128")4477 4478libc_math_function(name = "lroundf16")4479 4480libc_math_function(name = "modf")4481 4482libc_math_function(name = "modff")4483 4484libc_math_function(name = "modfl")4485 4486libc_math_function(name = "modff128")4487 4488libc_math_function(name = "modff16")4489 4490libc_math_function(4491 name = "nan",4492 additional_deps = [4493 ":__support_str_to_float",4494 ":errno",4495 ],4496)4497 4498libc_math_function(4499 name = "nanf",4500 additional_deps = [4501 ":__support_str_to_float",4502 ":errno",4503 ],4504)4505 4506libc_math_function(4507 name = "nanl",4508 additional_deps = [4509 ":__support_str_to_float",4510 ":errno",4511 ],4512)4513 4514libc_math_function(4515 name = "nanf128",4516 additional_deps = [4517 ":__support_str_to_float",4518 ":errno",4519 ],4520)4521 4522libc_math_function(4523 name = "nanf16",4524 additional_deps = [4525 ":__support_str_to_float",4526 ":errno",4527 ],4528)4529 4530libc_math_function(name = "nearbyint")4531 4532libc_math_function(name = "nearbyintf")4533 4534libc_math_function(name = "nearbyintl")4535 4536libc_math_function(name = "nearbyintf128")4537 4538libc_math_function(name = "nearbyintf16")4539 4540libc_math_function(name = "nextafter")4541 4542libc_math_function(name = "nextafterf")4543 4544libc_math_function(name = "nextafterl")4545 4546libc_math_function(name = "nextafterf128")4547 4548libc_math_function(name = "nextafterf16")4549 4550libc_math_function(name = "nextdown")4551 4552libc_math_function(name = "nextdownf")4553 4554libc_math_function(name = "nextdownl")4555 4556libc_math_function(name = "nextdownf128")4557 4558libc_math_function(name = "nextdownf16")4559 4560libc_math_function(name = "nexttoward")4561 4562libc_math_function(name = "nexttowardf")4563 4564libc_math_function(name = "nexttowardf16")4565 4566libc_math_function(name = "nexttowardl")4567 4568libc_math_function(name = "nextup")4569 4570libc_math_function(name = "nextupf")4571 4572libc_math_function(name = "nextupl")4573 4574libc_math_function(name = "nextupf128")4575 4576libc_math_function(name = "nextupf16")4577 4578libc_math_function(4579 name = "pow",4580 additional_deps = [4581 ":__support_fputil_double_double",4582 ":__support_fputil_nearest_integer",4583 ":__support_fputil_polyeval",4584 ":__support_fputil_sqrt",4585 ":__support_math_common_constants",4586 ],4587)4588 4589libc_math_function(4590 name = "powf",4591 additional_deps = [4592 ":__support_fputil_double_double",4593 ":__support_fputil_multiply_add",4594 ":__support_fputil_nearest_integer",4595 ":__support_fputil_polyeval",4596 ":__support_fputil_sqrt",4597 ":__support_fputil_triple_double",4598 ":__support_macros_optimization",4599 ":__support_math_exp10f",4600 ":__support_math_common_constants",4601 ":__support_math_exp2f",4602 ],4603)4604 4605libc_math_function(name = "remainder")4606 4607libc_math_function(name = "remainderf")4608 4609libc_math_function(name = "remainderl")4610 4611libc_math_function(name = "remainderf128")4612 4613libc_math_function(name = "remainderf16")4614 4615libc_math_function(name = "remquo")4616 4617libc_math_function(name = "remquof")4618 4619libc_math_function(name = "remquol")4620 4621libc_math_function(name = "remquof128")4622 4623libc_math_function(name = "remquof16")4624 4625libc_math_function(name = "rint")4626 4627libc_math_function(name = "rintf")4628 4629libc_math_function(name = "rintl")4630 4631libc_math_function(name = "rintf128")4632 4633libc_math_function(name = "rintf16")4634 4635libc_math_function(name = "round")4636 4637libc_math_function(name = "roundf")4638 4639libc_math_function(name = "roundl")4640 4641libc_math_function(name = "roundf128")4642 4643libc_math_function(name = "roundf16")4644 4645libc_math_function(name = "roundeven")4646 4647libc_math_function(name = "roundevenf")4648 4649libc_math_function(name = "roundevenl")4650 4651libc_math_function(name = "roundevenf128")4652 4653libc_math_function(name = "roundevenf16")4654 4655libc_math_function(4656 name = "rsqrtf",4657 additional_deps = [4658 ":__support_math_rsqrtf",4659 ],4660)4661 4662libc_math_function(4663 name = "rsqrtf16",4664 additional_deps = [4665 ":__support_math_rsqrtf16",4666 ],4667)4668 4669libc_math_function(name = "scalbln")4670 4671libc_math_function(name = "scalblnf")4672 4673libc_math_function(name = "scalblnl")4674 4675libc_math_function(name = "scalblnf128")4676 4677libc_math_function(name = "scalblnf16")4678 4679libc_math_function(name = "scalbn")4680 4681libc_math_function(name = "scalbnf")4682 4683libc_math_function(name = "scalbnl")4684 4685libc_math_function(name = "scalbnf128")4686 4687libc_math_function(name = "scalbnf16")4688 4689libc_math_function(name = "setpayload")4690 4691libc_math_function(name = "setpayloadf")4692 4693libc_math_function(name = "setpayloadl")4694 4695libc_math_function(name = "setpayloadf128")4696 4697libc_math_function(name = "setpayloadf16")4698 4699libc_math_function(name = "setpayloadsig")4700 4701libc_math_function(name = "setpayloadsigf")4702 4703libc_math_function(name = "setpayloadsigl")4704 4705libc_math_function(name = "setpayloadsigf128")4706 4707libc_math_function(name = "setpayloadsigf16")4708 4709libc_math_function(4710 name = "sin",4711 additional_deps = [4712 ":__support_fputil_multiply_add",4713 ":__support_macros_optimization",4714 ":__support_macros_properties_cpu_features",4715 ":__support_range_reduction_double",4716 ":__support_sincos_eval",4717 ],4718)4719 4720libc_math_function(4721 name = "sinf",4722 additional_deps = [4723 ":__support_fputil_fma",4724 ":__support_fputil_polyeval",4725 ":__support_fputil_rounding_mode",4726 ":__support_macros_optimization",4727 ":__support_macros_properties_cpu_features",4728 ":__support_range_reduction",4729 ":__support_sincosf_utils",4730 ],4731)4732 4733libc_math_function(4734 name = "sinf16",4735 additional_deps = [4736 ":__support_fputil_nearest_integer",4737 ":__support_fputil_polyeval",4738 ":__support_math_sincosf16_utils",4739 ],4740)4741 4742libc_math_function(4743 name = "sincos",4744 additional_deps = [4745 ":__support_fputil_multiply_add",4746 ":__support_macros_optimization",4747 ":__support_macros_properties_cpu_features",4748 ":__support_range_reduction_double",4749 ":__support_sincos_eval",4750 ],4751)4752 4753libc_math_function(4754 name = "sincosf",4755 additional_deps = [4756 ":__support_fputil_fma",4757 ":__support_fputil_multiply_add",4758 ":__support_fputil_rounding_mode",4759 ":__support_macros_optimization",4760 ":__support_macros_properties_cpu_features",4761 ":__support_sincosf_utils",4762 ],4763)4764 4765libc_math_function(4766 name = "sinhf",4767 additional_deps = [4768 ":__support_fputil_fma",4769 ":__support_fputil_multiply_add",4770 ":__support_fputil_nearest_integer",4771 ":__support_fputil_polyeval",4772 ":__support_fputil_rounding_mode",4773 ":__support_macros_optimization",4774 ":__support_math_sinhfcoshf_utils",4775 ":__support_math_common_constants",4776 ],4777)4778 4779libc_math_function(4780 name = "sinhf16",4781 additional_deps = [4782 ":__support_math_expxf16_utils",4783 ],4784)4785 4786libc_math_function(4787 name = "sinpif",4788 additional_deps = [4789 ":__support_sincosf_utils",4790 ],4791)4792 4793libc_math_function(4794 name = "sinpif16",4795 additional_deps = [4796 ":__support_fputil_nearest_integer",4797 ":__support_fputil_polyeval",4798 ":__support_math_sincosf16_utils",4799 ],4800)4801 4802libc_math_function(4803 name = "sqrt",4804 additional_deps = [4805 ":__support_fputil_sqrt",4806 ],4807)4808 4809libc_math_function(4810 name = "sqrtf",4811 additional_deps = [4812 ":__support_fputil_sqrt",4813 ],4814)4815 4816libc_math_function(4817 name = "sqrtl",4818 additional_deps = [4819 ":__support_fputil_sqrt",4820 ],4821)4822 4823libc_math_function(4824 name = "sqrtf128",4825 additional_deps = [4826 ":__support_fputil_sqrt",4827 ],4828)4829 4830libc_math_function(4831 name = "sqrtf16",4832 additional_deps = [4833 ":__support_fputil_sqrt",4834 ],4835)4836 4837libc_math_function(4838 name = "tan",4839 additional_deps = [4840 ":__support_fputil_multiply_add",4841 ":__support_macros_optimization",4842 ":__support_macros_properties_cpu_features",4843 ":__support_range_reduction_double",4844 ":__support_sincos_eval",4845 ],4846)4847 4848libc_math_function(4849 name = "tanf",4850 additional_deps = [4851 ":__support_fputil_fma",4852 ":__support_fputil_multiply_add",4853 ":__support_fputil_nearest_integer",4854 ":__support_fputil_polyeval",4855 ":__support_macros_optimization",4856 ":__support_macros_properties_cpu_features",4857 ":__support_range_reduction",4858 ":__support_sincosf_utils",4859 ],4860)4861 4862libc_math_function(4863 name = "tanf16",4864 additional_deps = [4865 ":__support_fputil_nearest_integer",4866 ":__support_fputil_polyeval",4867 ":__support_math_sincosf16_utils",4868 ],4869)4870 4871libc_math_function(4872 name = "tanhf",4873 additional_deps = [4874 ":__support_fputil_fma",4875 ":__support_fputil_multiply_add",4876 ":__support_fputil_nearest_integer",4877 ":__support_fputil_polyeval",4878 ":__support_fputil_rounding_mode",4879 ":__support_macros_optimization",4880 ":__support_macros_properties_cpu_features",4881 ":__support_math_exp10f_utils",4882 ":__support_math_common_constants",4883 ],4884)4885 4886libc_math_function(4887 name = "tanhf16",4888 additional_deps = [4889 ":__support_math_expxf16_utils",4890 ],4891)4892 4893libc_math_function(4894 name = "tanpif",4895 additional_deps = [4896 ":__support_sincosf_utils",4897 ":hdr_fenv_macros",4898 ":__support_macros_config",4899 ":__support_macros_optimization",4900 ":__support_fputil_multiply_add",4901 ],4902)4903 4904libc_math_function(4905 name = "tanpif16",4906 additional_deps = [4907 ":__support_math_sincosf16_utils",4908 ":hdr_errno_macros",4909 ":hdr_fenv_macros",4910 ":__support_fputil_cast",4911 ":__support_fputil_multiply_add",4912 ],4913)4914 4915libc_math_function(name = "totalorder")4916 4917libc_math_function(name = "totalorderf")4918 4919libc_math_function(name = "totalorderl")4920 4921libc_math_function(name = "totalorderf128")4922 4923libc_math_function(name = "totalorderf16")4924 4925libc_math_function(name = "totalordermag")4926 4927libc_math_function(name = "totalordermagf")4928 4929libc_math_function(name = "totalordermagl")4930 4931libc_math_function(name = "totalordermagf128")4932 4933libc_math_function(name = "totalordermagf16")4934 4935libc_math_function(name = "trunc")4936 4937libc_math_function(name = "truncf")4938 4939libc_math_function(name = "truncl")4940 4941libc_math_function(name = "truncf128")4942 4943libc_math_function(name = "truncf16")4944 4945libc_math_function(name = "ufromfp")4946 4947libc_math_function(name = "ufromfpf")4948 4949libc_math_function(name = "ufromfpl")4950 4951libc_math_function(name = "ufromfpf128")4952 4953libc_math_function(name = "ufromfpf16")4954 4955libc_math_function(name = "ufromfpx")4956 4957libc_math_function(name = "ufromfpxf")4958 4959libc_math_function(name = "ufromfpxl")4960 4961libc_math_function(name = "ufromfpxf128")4962 4963libc_math_function(name = "ufromfpxf16")4964 4965############################## inttypes targets ##############################4966 4967libc_function(4968 name = "strtoimax",4969 srcs = ["src/inttypes/strtoimax.cpp"],4970 hdrs = ["src/inttypes/strtoimax.h"],4971 deps = [4972 ":__support_common",4973 ":__support_str_to_integer",4974 ":errno",4975 ],4976)4977 4978libc_function(4979 name = "strtoumax",4980 srcs = ["src/inttypes/strtoumax.cpp"],4981 hdrs = ["src/inttypes/strtoumax.h"],4982 deps = [4983 ":__support_common",4984 ":__support_str_to_integer",4985 ":errno",4986 ],4987)4988 4989libc_function(4990 name = "imaxabs",4991 srcs = ["src/inttypes/imaxabs.cpp"],4992 hdrs = ["src/inttypes/imaxabs.h"],4993 deps = [4994 ":__support_common",4995 ":__support_integer_operations",4996 ],4997)4998 4999libc_function(5000 name = "imaxdiv",5001 srcs = ["src/inttypes/imaxdiv.cpp"],5002 hdrs = ["src/inttypes/imaxdiv.h"],5003 deps = [5004 ":__support_common",5005 ":__support_integer_operations",5006 ],5007)5008 5009############################### stdbit targets ###############################5010 5011bit_suffix_list = [5012 "uc",5013 "us",5014 "ui",5015 "ul",5016 "ull",5017]5018 5019bit_prefix_list = [5020 "stdc_leading_zeros_",5021 "stdc_leading_ones_",5022 "stdc_trailing_zeros_",5023 "stdc_trailing_ones_",5024 "stdc_count_ones_",5025 "stdc_has_single_bit_",5026 "stdc_bit_width_",5027 "stdc_bit_floor_",5028 "stdc_bit_ceil_",5029]5030 5031bit_prefix_needs_math_list = [5032 "stdc_first_leading_zero_",5033 "stdc_first_leading_one_",5034 "stdc_first_trailing_zero_",5035 "stdc_first_trailing_one_",5036 "stdc_count_zeros_",5037]5038 5039[5040 libc_function(5041 name = bit_prefix + bit_suffix,5042 srcs = ["src/stdbit/" + bit_prefix + bit_suffix + ".cpp"],5043 hdrs = ["src/stdbit/" + bit_prefix + bit_suffix + ".h"],5044 deps = [5045 ":__support_common",5046 ":__support_cpp_bit",5047 ],5048 )5049 for bit_prefix in bit_prefix_list5050 for bit_suffix in bit_suffix_list5051]5052 5053[5054 libc_function(5055 name = bit_prefix + bit_suffix,5056 srcs = ["src/stdbit/" + bit_prefix + bit_suffix + ".cpp"],5057 hdrs = ["src/stdbit/" + bit_prefix + bit_suffix + ".h"],5058 deps = [5059 ":__support_common",5060 ":__support_math_extras",5061 ],5062 )5063 for bit_prefix in bit_prefix_needs_math_list5064 for bit_suffix in bit_suffix_list5065]5066 5067############################### stdlib targets ###############################5068 5069libc_function(5070 name = "abs",5071 srcs = ["src/stdlib/abs.cpp"],5072 hdrs = ["src/stdlib/abs.h"],5073 deps = [5074 ":__support_common",5075 ":__support_integer_operations",5076 ],5077)5078 5079libc_function(5080 name = "labs",5081 srcs = ["src/stdlib/labs.cpp"],5082 hdrs = ["src/stdlib/labs.h"],5083 deps = [5084 ":__support_common",5085 ":__support_integer_operations",5086 ],5087)5088 5089libc_function(5090 name = "llabs",5091 srcs = ["src/stdlib/llabs.cpp"],5092 hdrs = ["src/stdlib/llabs.h"],5093 deps = [5094 ":__support_common",5095 ":__support_integer_operations",5096 ],5097)5098 5099libc_function(5100 name = "div",5101 srcs = ["src/stdlib/div.cpp"],5102 hdrs = ["src/stdlib/div.h"],5103 deps = [5104 ":__support_common",5105 ":__support_integer_operations",5106 ":types_div_t",5107 ],5108)5109 5110libc_function(5111 name = "ldiv",5112 srcs = ["src/stdlib/ldiv.cpp"],5113 hdrs = ["src/stdlib/ldiv.h"],5114 deps = [5115 ":__support_common",5116 ":__support_integer_operations",5117 ":types_ldiv_t",5118 ],5119)5120 5121libc_function(5122 name = "lldiv",5123 srcs = ["src/stdlib/lldiv.cpp"],5124 hdrs = ["src/stdlib/lldiv.h"],5125 deps = [5126 ":__support_common",5127 ":__support_integer_operations",5128 ":types_lldiv_t",5129 ],5130)5131 5132libc_function(5133 name = "atoi",5134 srcs = ["src/stdlib/atoi.cpp"],5135 hdrs = ["src/stdlib/atoi.h"],5136 deps = [5137 ":__support_common",5138 ":__support_str_to_integer",5139 ":errno",5140 ],5141)5142 5143libc_function(5144 name = "atol",5145 srcs = ["src/stdlib/atol.cpp"],5146 hdrs = ["src/stdlib/atol.h"],5147 deps = [5148 ":__support_common",5149 ":__support_str_to_integer",5150 ":errno",5151 ],5152)5153 5154libc_function(5155 name = "atoll",5156 srcs = ["src/stdlib/atoll.cpp"],5157 hdrs = ["src/stdlib/atoll.h"],5158 deps = [5159 ":__support_common",5160 ":__support_str_to_integer",5161 ":errno",5162 ],5163)5164 5165libc_function(5166 name = "atof",5167 srcs = ["src/stdlib/atof.cpp"],5168 hdrs = ["src/stdlib/atof.h"],5169 deps = [5170 ":__support_common",5171 ":__support_str_to_float",5172 ":errno",5173 ],5174)5175 5176libc_function(5177 name = "bsearch",5178 srcs = ["src/stdlib/bsearch.cpp"],5179 hdrs = ["src/stdlib/bsearch.h"],5180 deps = [5181 ":__support_common",5182 ],5183)5184 5185libc_support_library(5186 name = "qsort_util",5187 hdrs = [5188 "src/stdlib/heap_sort.h",5189 "src/stdlib/qsort_data.h",5190 "src/stdlib/qsort_pivot.h",5191 "src/stdlib/qsort_util.h",5192 "src/stdlib/quick_sort.h",5193 ],5194 deps = [5195 ":__support_common",5196 ":__support_cpp_bit",5197 ":__support_cpp_cstddef",5198 ":__support_macros_attributes",5199 ":string_memory_utils",5200 ],5201)5202 5203libc_function(5204 name = "qsort",5205 srcs = ["src/stdlib/qsort.cpp"],5206 hdrs = ["src/stdlib/qsort.h"],5207 deps = [5208 ":__support_common",5209 ":qsort_util",5210 ":types_size_t",5211 ],5212)5213 5214libc_function(5215 name = "qsort_r",5216 srcs = ["src/stdlib/qsort_r.cpp"],5217 hdrs = ["src/stdlib/qsort_r.h"],5218 deps = [5219 ":__support_common",5220 ":qsort_util",5221 ":types_size_t",5222 ],5223)5224 5225libc_support_library(5226 name = "rand_util",5227 srcs = ["src/stdlib/rand_util.cpp"],5228 hdrs = ["src/stdlib/rand_util.h"],5229 deps = [5230 ":__support_cpp_atomic",5231 ":__support_macros_attributes",5232 ":__support_macros_config",5233 ],5234)5235 5236libc_function(5237 name = "rand",5238 srcs = ["src/stdlib/rand.cpp"],5239 hdrs = ["src/stdlib/rand.h"],5240 deps = [5241 ":__support_common",5242 ":__support_macros_config",5243 ":__support_threads_sleep",5244 ":hdr_stdlib_macros",5245 ":rand_util",5246 ],5247)5248 5249libc_function(5250 name = "srand",5251 srcs = ["src/stdlib/srand.cpp"],5252 hdrs = ["src/stdlib/srand.h"],5253 deps = [5254 ":__support_common",5255 ":__support_macros_config",5256 ":rand_util",5257 ],5258)5259 5260libc_support_library(5261 name = "str_from_util",5262 hdrs = ["src/stdlib/str_from_util.h"],5263 deps = [5264 ":__support_common",5265 ":__support_cpp_type_traits",5266 ":__support_str_to_integer",5267 ":printf_converter",5268 ":printf_core_structs",5269 ":printf_writer",5270 ],5271)5272 5273libc_function(5274 name = "strfromf",5275 srcs = ["src/stdlib/strfromf.cpp"],5276 hdrs = ["src/stdlib/strfromf.h"],5277 deps = [5278 ":__support_common",5279 ":printf_error_mapper",5280 ":str_from_util",5281 ],5282)5283 5284libc_function(5285 name = "strfromd",5286 srcs = ["src/stdlib/strfromd.cpp"],5287 hdrs = ["src/stdlib/strfromd.h"],5288 deps = [5289 ":__support_common",5290 ":printf_error_mapper",5291 ":str_from_util",5292 ],5293)5294 5295libc_function(5296 name = "strfroml",5297 srcs = ["src/stdlib/strfroml.cpp"],5298 hdrs = ["src/stdlib/strfroml.h"],5299 deps = [5300 ":__support_common",5301 ":printf_error_mapper",5302 ":str_from_util",5303 ],5304)5305 5306libc_function(5307 name = "strtol",5308 srcs = ["src/stdlib/strtol.cpp"],5309 hdrs = ["src/stdlib/strtol.h"],5310 deps = [5311 ":__support_common",5312 ":__support_str_to_integer",5313 ":errno",5314 ],5315)5316 5317libc_function(5318 name = "strtoll",5319 srcs = ["src/stdlib/strtoll.cpp"],5320 hdrs = ["src/stdlib/strtoll.h"],5321 deps = [5322 ":__support_common",5323 ":__support_str_to_integer",5324 ":errno",5325 ],5326)5327 5328libc_function(5329 name = "strtoul",5330 srcs = ["src/stdlib/strtoul.cpp"],5331 hdrs = ["src/stdlib/strtoul.h"],5332 deps = [5333 ":__support_common",5334 ":__support_str_to_integer",5335 ":errno",5336 ],5337)5338 5339libc_function(5340 name = "strtoull",5341 srcs = ["src/stdlib/strtoull.cpp"],5342 hdrs = ["src/stdlib/strtoull.h"],5343 deps = [5344 ":__support_common",5345 ":__support_str_to_integer",5346 ":errno",5347 ],5348)5349 5350libc_function(5351 name = "strtof",5352 srcs = ["src/stdlib/strtof.cpp"],5353 hdrs = ["src/stdlib/strtof.h"],5354 deps = [5355 ":__support_common",5356 ":__support_str_to_float",5357 ":errno",5358 ],5359)5360 5361libc_function(5362 name = "strtod",5363 srcs = ["src/stdlib/strtod.cpp"],5364 hdrs = ["src/stdlib/strtod.h"],5365 deps = [5366 ":__support_common",5367 ":__support_str_to_float",5368 ":errno",5369 ],5370)5371 5372libc_function(5373 name = "strtold",5374 srcs = ["src/stdlib/strtold.cpp"],5375 hdrs = ["src/stdlib/strtold.h"],5376 deps = [5377 ":__support_common",5378 ":__support_str_to_float",5379 ":errno",5380 ],5381)5382 5383############################### string targets ###############################5384 5385libc_support_library(5386 name = "string_memory_utils",5387 hdrs = [5388 "src/string/memory_utils/op_aarch64.h",5389 "src/string/memory_utils/op_builtin.h",5390 "src/string/memory_utils/op_generic.h",5391 "src/string/memory_utils/op_riscv.h",5392 "src/string/memory_utils/op_x86.h",5393 "src/string/memory_utils/utils.h",5394 ],5395 textual_hdrs = [5396 "src/string/memory_utils/aarch64/inline_bcmp.h",5397 "src/string/memory_utils/aarch64/inline_memcmp.h",5398 "src/string/memory_utils/aarch64/inline_memcpy.h",5399 "src/string/memory_utils/aarch64/inline_memmove.h",5400 "src/string/memory_utils/aarch64/inline_memset.h",5401 "src/string/memory_utils/aarch64/inline_strlen.h",5402 "src/string/memory_utils/arm/common.h",5403 "src/string/memory_utils/arm/inline_memcpy.h",5404 "src/string/memory_utils/arm/inline_memset.h",5405 "src/string/memory_utils/generic/aligned_access.h",5406 "src/string/memory_utils/generic/byte_per_byte.h",5407 "src/string/memory_utils/generic/inline_strlen.h",5408 "src/string/memory_utils/inline_bcmp.h",5409 "src/string/memory_utils/inline_bzero.h",5410 "src/string/memory_utils/inline_memcmp.h",5411 "src/string/memory_utils/inline_memcpy.h",5412 "src/string/memory_utils/inline_memmem.h",5413 "src/string/memory_utils/inline_memmove.h",5414 "src/string/memory_utils/inline_memset.h",5415 "src/string/memory_utils/inline_strcmp.h",5416 "src/string/memory_utils/inline_strstr.h",5417 "src/string/memory_utils/riscv/inline_bcmp.h",5418 "src/string/memory_utils/riscv/inline_memcmp.h",5419 "src/string/memory_utils/riscv/inline_memcpy.h",5420 "src/string/memory_utils/riscv/inline_memmove.h",5421 "src/string/memory_utils/riscv/inline_memset.h",5422 "src/string/memory_utils/x86_64/inline_bcmp.h",5423 "src/string/memory_utils/x86_64/inline_memcmp.h",5424 "src/string/memory_utils/x86_64/inline_memcpy.h",5425 "src/string/memory_utils/x86_64/inline_memmove.h",5426 "src/string/memory_utils/x86_64/inline_memset.h",5427 "src/string/memory_utils/x86_64/inline_strlen.h",5428 ],5429 deps = [5430 ":__support_common",5431 ":__support_cpp_array",5432 ":__support_cpp_bit",5433 ":__support_cpp_cstddef",5434 ":__support_cpp_simd",5435 ":__support_cpp_type_traits",5436 ":__support_macros_attributes",5437 ":__support_macros_optimization",5438 ":__support_macros_properties_architectures",5439 ":__support_macros_properties_cpu_features",5440 ],5441)5442 5443libc_support_library(5444 name = "string_utils",5445 hdrs = ["src/string/string_utils.h"],5446 deps = [5447 ":__support_common",5448 ":__support_cpp_bitset",5449 ":__support_cpp_type_traits",5450 ":__support_macros_attributes",5451 ":__support_macros_optimization",5452 ":hdr_limits_macros",5453 ":llvm_libc_types_size_t",5454 ":string_memory_utils",5455 ":types_size_t",5456 ],5457)5458 5459libc_function(5460 name = "index",5461 srcs = ["src/strings/index.cpp"],5462 hdrs = ["src/strings/index.h"],5463 deps = [5464 ":__support_common",5465 ":string_utils",5466 ],5467)5468 5469libc_function(5470 name = "rindex",5471 srcs = ["src/strings/rindex.cpp"],5472 hdrs = ["src/strings/rindex.h"],5473 deps = [5474 ":__support_common",5475 ":__support_macros_null_check",5476 ":string_utils",5477 ],5478)5479 5480libc_function(5481 name = "memchr",5482 srcs = ["src/string/memchr.cpp"],5483 hdrs = ["src/string/memchr.h"],5484 deps = [5485 ":__support_common",5486 ":__support_macros_null_check",5487 ":string_utils",5488 ],5489)5490 5491libc_function(5492 name = "memcpy",5493 srcs = ["src/string/memcpy.cpp"],5494 hdrs = ["src/string/memcpy.h"],5495 deps = [5496 ":__support_common",5497 ":__support_macros_null_check",5498 ":string_memory_utils",5499 ],5500)5501 5502libc_function(5503 name = "memccpy",5504 srcs = ["src/string/memccpy.cpp"],5505 hdrs = ["src/string/memccpy.h"],5506 deps = [5507 ":__support_common",5508 ":__support_macros_null_check",5509 ],5510)5511 5512libc_function(5513 name = "memset",5514 srcs = ["src/string/memset.cpp"],5515 hdrs = ["src/string/memset.h"],5516 deps = [5517 ":__support_common",5518 ":__support_macros_null_check",5519 ":string_memory_utils",5520 ],5521)5522 5523libc_function(5524 name = "memset_explicit",5525 srcs = ["src/string/memset_explicit.cpp"],5526 hdrs = ["src/string/memset_explicit.h"],5527 deps = [5528 ":__support_common",5529 ":__support_macros_null_check",5530 ":string_memory_utils",5531 ],5532)5533 5534libc_function(5535 name = "memmove",5536 srcs = ["src/string/memmove.cpp"],5537 hdrs = ["src/string/memmove.h"],5538 deps = [5539 ":__support_common",5540 ":__support_macros_null_check",5541 ":string_memory_utils",5542 ],5543)5544 5545libc_function(5546 name = "memmem",5547 srcs = ["src/string/memmem.cpp"],5548 hdrs = ["src/string/memmem.h"],5549 deps = [5550 ":__support_common",5551 ":__support_macros_null_check",5552 ":string_memory_utils",5553 ],5554)5555 5556libc_function(5557 name = "mempcpy",5558 srcs = ["src/string/mempcpy.cpp"],5559 hdrs = ["src/string/mempcpy.h"],5560 deps = [5561 ":__support_common",5562 ":__support_macros_null_check",5563 ":string_memory_utils",5564 ],5565)5566 5567libc_function(5568 name = "bcopy",5569 srcs = ["src/strings/bcopy.cpp"],5570 hdrs = ["src/strings/bcopy.h"],5571 deps = [5572 ":__support_common",5573 ":string_memory_utils",5574 ],5575)5576 5577libc_function(5578 name = "memcmp",5579 srcs = ["src/string/memcmp.cpp"],5580 hdrs = ["src/string/memcmp.h"],5581 deps = [5582 ":__support_common",5583 ":__support_integer_operations",5584 ":__support_macros_null_check",5585 ":string_memory_utils",5586 ],5587)5588 5589libc_function(5590 name = "bcmp",5591 srcs = ["src/strings/bcmp.cpp"],5592 hdrs = ["src/strings/bcmp.h"],5593 deps = [5594 ":__support_common",5595 ":string_memory_utils",5596 ],5597)5598 5599libc_function(5600 name = "bzero",5601 srcs = ["src/strings/bzero.cpp"],5602 hdrs = ["src/strings/bzero.h"],5603 deps = [5604 ":__support_common",5605 ":string_memory_utils",5606 ],5607)5608 5609libc_function(5610 name = "memrchr",5611 srcs = ["src/string/memrchr.cpp"],5612 hdrs = ["src/string/memrchr.h"],5613 deps = [5614 ":__support_common",5615 ":__support_macros_null_check",5616 ":string_utils",5617 ],5618)5619 5620libc_function(5621 name = "stpcpy",5622 srcs = ["src/string/stpcpy.cpp"],5623 hdrs = ["src/string/stpcpy.h"],5624 deps = [5625 ":__support_common",5626 ":__support_macros_null_check",5627 ":string_memory_utils",5628 ":string_utils",5629 ],5630)5631 5632libc_function(5633 name = "stpncpy",5634 srcs = ["src/string/stpncpy.cpp"],5635 hdrs = ["src/string/stpncpy.h"],5636 deps = [5637 ":__support_common",5638 ":__support_macros_null_check",5639 ":string_memory_utils",5640 ":string_utils",5641 ],5642)5643 5644libc_function(5645 name = "strlen",5646 srcs = ["src/string/strlen.cpp"],5647 hdrs = ["src/string/strlen.h"],5648 deps = [5649 ":__support_common",5650 ":__support_macros_null_check",5651 ":string_utils",5652 ],5653)5654 5655libc_function(5656 name = "strcpy",5657 srcs = ["src/string/strcpy.cpp"],5658 hdrs = ["src/string/strcpy.h"],5659 deps = [5660 ":__support_common",5661 ":__support_macros_null_check",5662 ":string_memory_utils",5663 ":string_utils",5664 ],5665)5666 5667libc_function(5668 name = "strlcpy",5669 srcs = ["src/string/strlcpy.cpp"],5670 hdrs = ["src/string/strlcpy.h"],5671 deps = [5672 ":__support_common",5673 ":llvm_libc_types_size_t",5674 ":string_utils",5675 ],5676)5677 5678libc_function(5679 name = "strncpy",5680 srcs = ["src/string/strncpy.cpp"],5681 hdrs = ["src/string/strncpy.h"],5682 deps = [5683 ":__support_common",5684 ":__support_macros_null_check",5685 ],5686)5687 5688libc_function(5689 name = "strcmp",5690 srcs = ["src/string/strcmp.cpp"],5691 hdrs = ["src/string/strcmp.h"],5692 deps = [5693 ":__support_common",5694 ":string_memory_utils",5695 ":string_utils",5696 ],5697)5698 5699libc_function(5700 name = "strncmp",5701 srcs = ["src/string/strncmp.cpp"],5702 hdrs = ["src/string/strncmp.h"],5703 deps = [5704 ":__support_common",5705 ":__support_macros_null_check",5706 ":string_memory_utils",5707 ":string_utils",5708 ],5709)5710 5711libc_function(5712 name = "strcasecmp",5713 srcs = ["src/strings/strcasecmp.cpp"],5714 hdrs = ["src/strings/strcasecmp.h"],5715 deps = [5716 ":__support_common",5717 ":__support_ctype_utils",5718 ":string_memory_utils",5719 ],5720)5721 5722libc_function(5723 name = "strncasecmp",5724 srcs = ["src/strings/strncasecmp.cpp"],5725 hdrs = ["src/strings/strncasecmp.h"],5726 deps = [5727 ":__support_common",5728 ":__support_ctype_utils",5729 ":string_memory_utils",5730 ],5731)5732 5733libc_function(5734 name = "strchr",5735 srcs = ["src/string/strchr.cpp"],5736 hdrs = ["src/string/strchr.h"],5737 deps = [5738 ":__support_common",5739 ":string_utils",5740 ],5741)5742 5743libc_function(5744 name = "strrchr",5745 srcs = ["src/string/strrchr.cpp"],5746 hdrs = ["src/string/strrchr.h"],5747 deps = [5748 ":__support_common",5749 ":string_utils",5750 ],5751)5752 5753libc_function(5754 name = "strchrnul",5755 srcs = ["src/string/strchrnul.cpp"],5756 hdrs = ["src/string/strchrnul.h"],5757 deps = [5758 ":__support_common",5759 ":string_utils",5760 ],5761)5762 5763libc_function(5764 name = "strsep",5765 srcs = ["src/string/strsep.cpp"],5766 hdrs = ["src/string/strsep.h"],5767 deps = [5768 ":__support_common",5769 ":__support_macros_null_check",5770 ":hdr_signal_macros",5771 ":string_memory_utils",5772 ":string_utils",5773 ],5774)5775 5776libc_function(5777 name = "strstr",5778 srcs = ["src/string/strstr.cpp"],5779 hdrs = ["src/string/strstr.h"],5780 deps = [5781 ":__support_common",5782 ":__support_macros_null_check",5783 ":string_memory_utils",5784 ":string_utils",5785 ],5786)5787 5788libc_function(5789 name = "strcasestr",5790 srcs = ["src/string/strcasestr.cpp"],5791 hdrs = ["src/string/strcasestr.h"],5792 deps = [5793 ":__support_common",5794 ":__support_ctype_utils",5795 ":__support_macros_null_check",5796 ":string_memory_utils",5797 ":string_utils",5798 ],5799)5800 5801libc_function(5802 name = "strcat",5803 srcs = ["src/string/strcat.cpp"],5804 hdrs = ["src/string/strcat.h"],5805 deps = [5806 ":__support_common",5807 ":__support_macros_null_check",5808 ":string_utils",5809 ],5810)5811 5812libc_function(5813 name = "strlcat",5814 srcs = ["src/string/strlcat.cpp"],5815 hdrs = ["src/string/strlcat.h"],5816 deps = [5817 ":__support_common",5818 ":string_utils",5819 ],5820)5821 5822libc_function(5823 name = "strncat",5824 srcs = ["src/string/strncat.cpp"],5825 hdrs = ["src/string/strncat.h"],5826 deps = [5827 ":__support_common",5828 ":__support_macros_null_check",5829 ":string_utils",5830 ],5831)5832 5833libc_function(5834 name = "strnlen",5835 srcs = ["src/string/strnlen.cpp"],5836 hdrs = ["src/string/strnlen.h"],5837 deps = [5838 ":__support_common",5839 ":string_utils",5840 ],5841)5842 5843libc_function(5844 name = "strcspn",5845 srcs = ["src/string/strcspn.cpp"],5846 hdrs = ["src/string/strcspn.h"],5847 deps = [5848 ":__support_common",5849 ":string_utils",5850 ],5851)5852 5853libc_function(5854 name = "strspn",5855 srcs = ["src/string/strspn.cpp"],5856 hdrs = ["src/string/strspn.h"],5857 deps = [5858 ":__support_common",5859 ":__support_cpp_bitset",5860 ":__support_macros_null_check",5861 ":string_utils",5862 ],5863)5864 5865libc_function(5866 name = "strpbrk",5867 srcs = ["src/string/strpbrk.cpp"],5868 hdrs = ["src/string/strpbrk.h"],5869 deps = [5870 ":__support_common",5871 ":string_utils",5872 ],5873)5874 5875libc_function(5876 name = "strtok",5877 srcs = ["src/string/strtok.cpp"],5878 hdrs = ["src/string/strtok.h"],5879 deps = [5880 ":__support_common",5881 ":string_utils",5882 ],5883)5884 5885libc_function(5886 name = "strtok_r",5887 srcs = ["src/string/strtok_r.cpp"],5888 hdrs = ["src/string/strtok_r.h"],5889 deps = [5890 ":__support_common",5891 ":string_utils",5892 ],5893)5894 5895################################ fcntl targets #################################5896 5897libc_function(5898 name = "open",5899 srcs = ["src/fcntl/linux/open.cpp"],5900 hdrs = ["src/fcntl/open.h"],5901 target_compatible_with = select({5902 "@platforms//os:linux": [],5903 "//conditions:default": ["@platforms//:incompatible"],5904 }),5905 deps = [5906 ":__support_common",5907 ":__support_osutil_fcntl",5908 ":errno",5909 ":hdr_fcntl_macros",5910 ":types_mode_t",5911 ],5912)5913 5914libc_function(5915 name = "fcntl",5916 srcs = ["src/fcntl/linux/fcntl.cpp"],5917 hdrs = ["src/fcntl/fcntl.h"],5918 target_compatible_with = select({5919 "@platforms//os:linux": [],5920 "//conditions:default": ["@platforms//:incompatible"],5921 }),5922 deps = [5923 ":__support_common",5924 ":__support_osutil_fcntl",5925 ":errno",5926 ],5927)5928 5929libc_function(5930 name = "openat",5931 srcs = ["src/fcntl/linux/openat.cpp"],5932 hdrs = ["src/fcntl/openat.h"],5933 target_compatible_with = select({5934 "@platforms//os:linux": [],5935 "//conditions:default": ["@platforms//:incompatible"],5936 }),5937 deps = [5938 ":__support_common",5939 ":__support_osutil_syscall",5940 ":errno",5941 ":hdr_fcntl_macros",5942 ":types_mode_t",5943 ],5944)5945 5946libc_function(5947 name = "creat",5948 srcs = ["src/fcntl/linux/creat.cpp"],5949 hdrs = ["src/fcntl/creat.h"],5950 deps = [5951 ":__support_common",5952 ":__support_osutil_syscall",5953 ":errno",5954 ":hdr_fcntl_macros",5955 ],5956)5957 5958################################ unistd targets ################################5959 5960libc_function(5961 name = "access",5962 srcs = ["src/unistd/linux/access.cpp"],5963 hdrs = ["src/unistd/access.h"],5964 deps = [5965 ":__support_common",5966 ":__support_osutil_syscall",5967 ":errno",5968 ":hdr_fcntl_macros",5969 ],5970)5971 5972libc_function(5973 name = "chdir",5974 srcs = ["src/unistd/linux/chdir.cpp"],5975 hdrs = ["src/unistd/chdir.h"],5976 deps = [5977 ":__support_common",5978 ":__support_osutil_syscall",5979 ":errno",5980 ],5981)5982 5983libc_function(5984 name = "close",5985 srcs = ["src/unistd/linux/close.cpp"],5986 hdrs = ["src/unistd/close.h"],5987 deps = [5988 ":__support_common",5989 ":__support_osutil_fcntl",5990 ":errno",5991 ],5992)5993 5994libc_function(5995 name = "dup",5996 srcs = ["src/unistd/linux/dup.cpp"],5997 hdrs = ["src/unistd/dup.h"],5998 deps = [5999 ":__support_common",6000 ":__support_osutil_syscall",6001 ":errno",6002 ":hdr_unistd_macros",6003 ],6004)6005 6006libc_function(6007 name = "dup2",6008 srcs = ["src/unistd/linux/dup2.cpp"],6009 hdrs = ["src/unistd/dup2.h"],6010 deps = [6011 ":__support_common",6012 ":__support_osutil_syscall",6013 ":errno",6014 ":hdr_fcntl_macros",6015 ":hdr_unistd_macros",6016 ],6017)6018 6019libc_function(6020 name = "dup3",6021 srcs = ["src/unistd/linux/dup3.cpp"],6022 hdrs = ["src/unistd/dup3.h"],6023 target_compatible_with = select({6024 "@platforms//os:linux": [],6025 "//conditions:default": ["@platforms//:incompatible"],6026 }),6027 deps = [6028 ":__support_common",6029 ":__support_osutil_syscall",6030 ":errno",6031 ":hdr_unistd_macros",6032 ],6033)6034 6035libc_function(6036 name = "environ",6037 srcs = ["src/unistd/environ.cpp"],6038 hdrs = ["src/unistd/environ.h"],6039 deps = [6040 ":__support_common",6041 ":__support_osutil_syscall",6042 ":errno",6043 ],6044)6045 6046libc_function(6047 name = "fchdir",6048 srcs = ["src/unistd/linux/fchdir.cpp"],6049 hdrs = ["src/unistd/fchdir.h"],6050 deps = [6051 ":__support_common",6052 ":__support_osutil_syscall",6053 ":errno",6054 ],6055)6056 6057libc_function(6058 name = "fsync",6059 srcs = ["src/unistd/linux/fsync.cpp"],6060 hdrs = ["src/unistd/fsync.h"],6061 deps = [6062 ":__support_common",6063 ":__support_osutil_syscall",6064 ":errno",6065 ],6066)6067 6068libc_function(6069 name = "ftruncate",6070 srcs = ["src/unistd/linux/ftruncate.cpp"],6071 hdrs = ["src/unistd/ftruncate.h"],6072 deps = [6073 ":__support_common",6074 ":__support_osutil_syscall",6075 ":errno",6076 ":hdr_unistd_macros",6077 ":types_off_t",6078 ],6079)6080 6081# libc_function(6082# name = "getcwd",6083# srcs = ["src/unistd/linux/getcwd.cpp"],6084# hdrs = ["src/unistd/getcwd.h"],6085# deps = [6086# ":__support_common",6087# ":__support_osutil_syscall",6088# ":errno",6089# ":hdr_unistd_macros",6090# ":types_size_t",6091# ],6092# )6093 6094libc_function(6095 name = "geteuid",6096 srcs = ["src/unistd/linux/geteuid.cpp"],6097 hdrs = ["src/unistd/geteuid.h"],6098 deps = [6099 ":__support_common",6100 ":__support_osutil_syscall",6101 ":errno",6102 ":hdr_unistd_macros",6103 ":types_size_t",6104 ":types_uid_t",6105 ],6106)6107 6108libc_function(6109 name = "getppid",6110 srcs = ["src/unistd/linux/getppid.cpp"],6111 hdrs = ["src/unistd/getppid.h"],6112 deps = [6113 ":__support_common",6114 ":__support_osutil_syscall",6115 ":errno",6116 ":hdr_unistd_macros",6117 ":types_pid_t",6118 ],6119)6120 6121libc_function(6122 name = "getuid",6123 srcs = ["src/unistd/linux/getuid.cpp"],6124 hdrs = ["src/unistd/getuid.h"],6125 deps = [6126 ":__support_common",6127 ":__support_osutil_syscall",6128 ":errno",6129 ":hdr_unistd_macros",6130 ":types_uid_t",6131 ],6132)6133 6134# libc_function(6135# name = "getopt",6136# srcs = ["src/unistd/getopt.cpp"],6137# hdrs = ["src/unistd/getopt.h"],6138# deps = [6139# ":__support_common",6140# ":__support_cpp_optional",6141# ":__support_cpp_string_view",6142# ":__support_file_file",6143# ":__support_osutil_syscall",6144# ":errno",6145# ":hdr_unistd_macros",6146# ],6147# )6148 6149libc_function(6150 name = "isatty",6151 srcs = ["src/unistd/linux/isatty.cpp"],6152 hdrs = ["src/unistd/isatty.h"],6153 deps = [6154 ":__support_common",6155 ":__support_osutil_syscall",6156 ":errno",6157 ":hdr_unistd_macros",6158 ],6159)6160 6161libc_function(6162 name = "link",6163 srcs = ["src/unistd/linux/link.cpp"],6164 hdrs = ["src/unistd/link.h"],6165 deps = [6166 ":__support_common",6167 ":__support_osutil_syscall",6168 ":errno",6169 ":hdr_fcntl_macros",6170 ":hdr_unistd_macros",6171 ],6172)6173 6174libc_function(6175 name = "linkat",6176 srcs = ["src/unistd/linux/linkat.cpp"],6177 hdrs = ["src/unistd/linkat.h"],6178 deps = [6179 ":__support_common",6180 ":__support_osutil_syscall",6181 ":errno",6182 ":hdr_fcntl_macros",6183 ":hdr_unistd_macros",6184 ],6185)6186 6187libc_function(6188 name = "pipe",6189 srcs = ["src/unistd/linux/pipe.cpp"],6190 hdrs = ["src/unistd/pipe.h"],6191 deps = [6192 ":__support_common",6193 ":__support_macros_sanitizer",6194 ":__support_osutil_syscall",6195 ":errno",6196 ],6197)6198 6199libc_function(6200 name = "lseek",6201 srcs = ["src/unistd/linux/lseek.cpp"],6202 hdrs = ["src/unistd/lseek.h"],6203 deps = [6204 ":__support_common",6205 ":__support_file_linux_lseekimpl",6206 ":__support_osutil_syscall",6207 ":errno",6208 ":hdr_unistd_macros",6209 ":types_off_t",6210 ],6211)6212 6213libc_function(6214 name = "pread",6215 srcs = ["src/unistd/linux/pread.cpp"],6216 hdrs = ["src/unistd/pread.h"],6217 target_compatible_with = select({6218 "@platforms//os:linux": [],6219 "//conditions:default": ["@platforms//:incompatible"],6220 }),6221 deps = [6222 ":__support_common",6223 ":__support_macros_sanitizer",6224 ":__support_osutil_syscall",6225 ":errno",6226 ":hdr_unistd_macros",6227 ":types_off_t",6228 ":types_size_t",6229 ":types_ssize_t",6230 ],6231)6232 6233libc_function(6234 name = "pwrite",6235 srcs = ["src/unistd/linux/pwrite.cpp"],6236 hdrs = ["src/unistd/pwrite.h"],6237 target_compatible_with = select({6238 "@platforms//os:linux": [],6239 "//conditions:default": ["@platforms//:incompatible"],6240 }),6241 deps = [6242 ":__support_common",6243 ":__support_osutil_syscall",6244 ":errno",6245 ":hdr_unistd_macros",6246 ":types_off_t",6247 ":types_size_t",6248 ":types_ssize_t",6249 ],6250)6251 6252libc_function(6253 name = "read",6254 srcs = ["src/unistd/linux/read.cpp"],6255 hdrs = ["src/unistd/read.h"],6256 deps = [6257 ":__support_common",6258 ":__support_macros_sanitizer",6259 ":__support_osutil_syscall",6260 ":errno",6261 ":hdr_unistd_macros",6262 ":types_size_t",6263 ":types_ssize_t",6264 ],6265)6266 6267libc_function(6268 name = "readlink",6269 srcs = ["src/unistd/linux/readlink.cpp"],6270 hdrs = ["src/unistd/readlink.h"],6271 deps = [6272 ":__support_common",6273 ":__support_osutil_syscall",6274 ":errno",6275 ":hdr_fcntl_macros",6276 ":hdr_unistd_macros",6277 ":types_size_t",6278 ":types_ssize_t",6279 ],6280)6281 6282libc_function(6283 name = "readlinkat",6284 srcs = ["src/unistd/linux/readlinkat.cpp"],6285 hdrs = ["src/unistd/readlinkat.h"],6286 deps = [6287 ":__support_common",6288 ":__support_osutil_syscall",6289 ":errno",6290 ":hdr_fcntl_macros",6291 ":hdr_unistd_macros",6292 ":types_size_t",6293 ":types_ssize_t",6294 ],6295)6296 6297libc_function(6298 name = "rmdir",6299 srcs = ["src/unistd/linux/rmdir.cpp"],6300 hdrs = ["src/unistd/rmdir.h"],6301 deps = [6302 ":__support_common",6303 ":__support_osutil_syscall",6304 ":errno",6305 ":hdr_fcntl_macros",6306 ],6307)6308 6309libc_function(6310 name = "symlink",6311 srcs = ["src/unistd/linux/symlink.cpp"],6312 hdrs = ["src/unistd/symlink.h"],6313 deps = [6314 ":__support_common",6315 ":__support_osutil_syscall",6316 ":errno",6317 ":hdr_fcntl_macros",6318 ":hdr_unistd_macros",6319 ],6320)6321 6322libc_function(6323 name = "symlinkat",6324 srcs = ["src/unistd/linux/symlinkat.cpp"],6325 hdrs = ["src/unistd/symlinkat.h"],6326 deps = [6327 ":__support_common",6328 ":__support_osutil_syscall",6329 ":errno",6330 ":hdr_fcntl_macros",6331 ":hdr_unistd_macros",6332 ],6333)6334 6335#TODO: Enable once fullbuild is added to bazel, since this depends on a macro6336# definition in the public header6337 6338# libc_function(6339# name = "syscall",6340# srcs = ["src/unistd/linux/syscall.cpp"],6341# hdrs = ["src/unistd/syscall.h"],6342# deps = [6343# ":__support_common",6344# ":__support_osutil_syscall",6345# ":errno",6346# ":hdr_unistd_macros",6347# ],6348# )6349 6350libc_function(6351 name = "swab",6352 srcs = ["src/unistd/swab.cpp"],6353 hdrs = ["src/unistd/swab.h"],6354 deps = [6355 ":__support_common",6356 ":__support_osutil_syscall",6357 ":errno",6358 ":hdr_unistd_macros",6359 ":types_ssize_t",6360 ],6361)6362 6363libc_function(6364 name = "truncate",6365 srcs = ["src/unistd/linux/truncate.cpp"],6366 hdrs = ["src/unistd/truncate.h"],6367 deps = [6368 ":__support_common",6369 ":__support_osutil_syscall",6370 ":errno",6371 ":hdr_unistd_macros",6372 ":types_off_t",6373 ],6374)6375 6376libc_function(6377 name = "unlink",6378 srcs = ["src/unistd/linux/unlink.cpp"],6379 hdrs = ["src/unistd/unlink.h"],6380 deps = [6381 ":__support_common",6382 ":__support_osutil_syscall",6383 ":errno",6384 ":hdr_fcntl_macros",6385 ],6386)6387 6388libc_function(6389 name = "unlinkat",6390 srcs = ["src/unistd/linux/unlinkat.cpp"],6391 hdrs = ["src/unistd/unlinkat.h"],6392 deps = [6393 ":__support_common",6394 ":__support_osutil_syscall",6395 ":errno",6396 ":hdr_fcntl_macros",6397 ],6398)6399 6400# WARNING: NOT FULLY IMPLEMENTED, FOR TESTING USE ONLY6401libc_function(6402 name = "sysconf",6403 srcs = ["src/unistd/linux/sysconf.cpp"],6404 hdrs = ["src/unistd/sysconf.h"],6405 deps = [6406 ":__support_common",6407 ":__support_osutil_linux_auxv",6408 ":errno",6409 ":hdr_unistd_macros",6410 ],6411)6412 6413libc_function(6414 name = "write",6415 srcs = ["src/unistd/linux/write.cpp"],6416 hdrs = ["src/unistd/write.h"],6417 deps = [6418 ":__support_common",6419 ":__support_osutil_syscall",6420 ":errno",6421 ":hdr_unistd_macros",6422 ":types_size_t",6423 ":types_ssize_t",6424 ],6425)6426 6427################################ stdio targets #################################6428 6429libc_support_library(6430 name = "printf_config",6431 hdrs = ["src/stdio/printf_core/printf_config.h"],6432 deps = [6433 ],6434)6435 6436libc_support_library(6437 name = "printf_core_structs",6438 hdrs = ["src/stdio/printf_core/core_structs.h"],6439 deps = [6440 ":__support_cpp_string_view",6441 ":__support_fputil_fp_bits",6442 ":printf_config",6443 ],6444)6445 6446libc_support_library(6447 name = "printf_parser",6448 hdrs = ["src/stdio/printf_core/parser.h"],6449 deps = [6450 ":__support_arg_list",6451 ":__support_common",6452 ":__support_cpp_algorithm",6453 ":__support_cpp_bit",6454 ":__support_cpp_optional",6455 ":__support_cpp_string_view",6456 ":__support_cpp_type_traits",6457 ":__support_ctype_utils",6458 ":__support_fputil_fp_bits",6459 ":__support_str_to_integer",6460 ":errno",6461 ":printf_config",6462 ":printf_core_structs",6463 ],6464)6465 6466libc_support_library(6467 name = "printf_writer",6468 hdrs = ["src/stdio/printf_core/writer.h"],6469 deps = [6470 ":__support_cpp_string_view",6471 ":__support_macros_optimization",6472 ":printf_core_structs",6473 ":string_memory_utils",6474 ],6475)6476 6477libc_support_library(6478 name = "printf_converter",6479 hdrs = [6480 "src/stdio/printf_core/char_converter.h",6481 "src/stdio/printf_core/converter.h",6482 "src/stdio/printf_core/converter_atlas.h",6483 "src/stdio/printf_core/converter_utils.h",6484 "src/stdio/printf_core/float_dec_converter.h",6485 "src/stdio/printf_core/float_hex_converter.h",6486 "src/stdio/printf_core/float_inf_nan_converter.h",6487 "src/stdio/printf_core/int_converter.h",6488 "src/stdio/printf_core/ptr_converter.h",6489 "src/stdio/printf_core/strerror_converter.h",6490 "src/stdio/printf_core/string_converter.h",6491 "src/stdio/printf_core/write_int_converter.h",6492 ],6493 deps = [6494 ":__support_big_int",6495 ":__support_common",6496 ":__support_cpp_limits",6497 ":__support_cpp_span",6498 ":__support_cpp_string_view",6499 ":__support_ctype_utils",6500 ":__support_float_to_string",6501 ":__support_fputil_fenv_impl",6502 ":__support_fputil_fp_bits",6503 ":__support_fputil_rounding_mode",6504 ":__support_integer_to_string",6505 ":__support_libc_assert",6506 ":__support_stringutil",6507 ":__support_uint128",6508 ":printf_config",6509 ":printf_core_structs",6510 ":printf_writer",6511 ],6512)6513 6514libc_support_library(6515 name = "printf_error_mapper",6516 hdrs = [6517 "src/stdio/printf_core/error_mapper.h",6518 ] + select({6519 "@platforms//os:linux": [6520 "src/stdio/printf_core/linux/error_mapper.h",6521 ],6522 "//conditions:default": [6523 "src/stdio/printf_core/generic/error_mapper.h",6524 ],6525 }),6526 deps = [6527 ":__support_cpp_type_traits",6528 ":__support_error_or",6529 ":__support_macros_properties_architectures",6530 ":hdr_errno_macros",6531 ":printf_core_structs",6532 ],6533)6534 6535libc_support_library(6536 name = "printf_main",6537 hdrs = ["src/stdio/printf_core/printf_main.h"],6538 deps = [6539 ":__support_arg_list",6540 ":printf_converter",6541 ":printf_core_structs",6542 ":printf_error_mapper",6543 ":printf_parser",6544 ":printf_writer",6545 ],6546)6547 6548libc_support_library(6549 name = "vfprintf_internal",6550 hdrs = ["src/stdio/printf_core/vfprintf_internal.h"],6551 deps = [6552 ":__support_arg_list",6553 ":__support_file_file",6554 ":__support_macros_attributes",6555 ":printf_main",6556 ":printf_writer",6557 ":types_FILE",6558 ],6559)6560 6561libc_support_library(6562 name = "vasprintf_internal",6563 hdrs = ["src/stdio/printf_core/vasprintf_internal.h"],6564 deps = [6565 ":__support_arg_list",6566 ":__support_macros_attributes",6567 ":func_free",6568 ":func_malloc",6569 ":func_realloc",6570 ":printf_main",6571 ":printf_writer",6572 ":types_FILE",6573 ],6574)6575 6576libc_function(6577 name = "asprintf",6578 srcs = ["src/stdio/asprintf.cpp"],6579 hdrs = ["src/stdio/asprintf.h"],6580 deps = [6581 ":__support_arg_list",6582 ":vasprintf_internal",6583 ],6584)6585 6586libc_function(6587 name = "sprintf",6588 srcs = ["src/stdio/sprintf.cpp"],6589 hdrs = ["src/stdio/sprintf.h"],6590 deps = [6591 ":__support_arg_list",6592 ":__support_cpp_limits",6593 ":errno",6594 ":printf_main",6595 ":printf_writer",6596 ],6597)6598 6599libc_function(6600 name = "snprintf",6601 srcs = ["src/stdio/snprintf.cpp"],6602 hdrs = ["src/stdio/snprintf.h"],6603 deps = [6604 ":__support_arg_list",6605 ":errno",6606 ":printf_main",6607 ":printf_writer",6608 ],6609)6610 6611libc_function(6612 name = "printf",6613 srcs = ["src/stdio/generic/printf.cpp"],6614 hdrs = ["src/stdio/printf.h"],6615 deps = [6616 ":__support_arg_list",6617 ":__support_file_file",6618 ":errno",6619 ":types_FILE",6620 ":vfprintf_internal",6621 ],6622)6623 6624libc_function(6625 name = "fprintf",6626 srcs = ["src/stdio/generic/fprintf.cpp"],6627 hdrs = ["src/stdio/fprintf.h"],6628 deps = [6629 ":__support_arg_list",6630 ":__support_file_file",6631 ":errno",6632 ":types_FILE",6633 ":vfprintf_internal",6634 ],6635)6636 6637libc_function(6638 name = "vasprintf",6639 srcs = ["src/stdio/vasprintf.cpp"],6640 hdrs = ["src/stdio/vasprintf.h"],6641 deps = [6642 ":__support_arg_list",6643 ":vasprintf_internal",6644 ],6645)6646 6647libc_function(6648 name = "vsprintf",6649 srcs = ["src/stdio/vsprintf.cpp"],6650 hdrs = ["src/stdio/vsprintf.h"],6651 deps = [6652 ":__support_arg_list",6653 ":__support_cpp_limits",6654 ":errno",6655 ":printf_main",6656 ":printf_writer",6657 ],6658)6659 6660libc_function(6661 name = "vsnprintf",6662 srcs = ["src/stdio/vsnprintf.cpp"],6663 hdrs = ["src/stdio/vsnprintf.h"],6664 deps = [6665 ":__support_arg_list",6666 ":errno",6667 ":printf_main",6668 ":printf_writer",6669 ],6670)6671 6672libc_function(6673 name = "vprintf",6674 srcs = ["src/stdio/generic/vprintf.cpp"],6675 hdrs = ["src/stdio/vprintf.h"],6676 deps = [6677 ":__support_arg_list",6678 ":__support_file_file",6679 ":errno",6680 ":types_FILE",6681 ":vfprintf_internal",6682 ],6683)6684 6685libc_function(6686 name = "vfprintf",6687 srcs = ["src/stdio/generic/vfprintf.cpp"],6688 hdrs = ["src/stdio/vfprintf.h"],6689 deps = [6690 ":__support_arg_list",6691 ":__support_file_file",6692 ":errno",6693 ":types_FILE",6694 ":vfprintf_internal",6695 ],6696)6697 6698libc_support_library(6699 name = "scanf_config",6700 hdrs = ["src/stdio/scanf_core/scanf_config.h"],6701)6702 6703libc_support_library(6704 name = "scanf_core_structs",6705 hdrs = ["src/stdio/scanf_core/core_structs.h"],6706 deps = [6707 ":__support_cpp_bitset",6708 ":__support_cpp_string_view",6709 ":__support_fputil_fp_bits",6710 ":scanf_config",6711 ],6712)6713 6714libc_support_library(6715 name = "scanf_parser",6716 hdrs = ["src/stdio/scanf_core/parser.h"],6717 deps = [6718 ":__support_arg_list",6719 ":__support_cpp_bitset",6720 ":__support_ctype_utils",6721 ":__support_str_to_integer",6722 ":scanf_config",6723 ":scanf_core_structs",6724 ],6725)6726 6727libc_support_library(6728 name = "scanf_reader",6729 hdrs = ["src/stdio/scanf_core/reader.h"],6730 deps = [6731 ":__support_cpp_string_view",6732 ":__support_macros_attributes",6733 ":types_FILE",6734 ],6735)6736 6737libc_support_library(6738 name = "scanf_string_reader",6739 hdrs = ["src/stdio/scanf_core/string_reader.h"],6740 deps = [6741 ":__support_macros_attributes",6742 ":scanf_reader",6743 ],6744)6745 6746libc_support_library(6747 name = "scanf_converter",6748 srcs = [6749 "src/stdio/scanf_core/converter_utils.h",6750 "src/stdio/scanf_core/current_pos_converter.h",6751 "src/stdio/scanf_core/float_converter.h",6752 "src/stdio/scanf_core/int_converter.h",6753 "src/stdio/scanf_core/ptr_converter.h",6754 "src/stdio/scanf_core/string_converter.h",6755 ],6756 hdrs = [6757 "src/stdio/scanf_core/converter.h",6758 ],6759 deps = [6760 ":__support_char_vector",6761 ":__support_cpp_bitset",6762 ":__support_cpp_limits",6763 ":__support_cpp_string_view",6764 ":__support_ctype_utils",6765 ":__support_str_to_float",6766 ":scanf_core_structs",6767 ":scanf_reader",6768 ],6769)6770 6771libc_support_library(6772 name = "scanf_main",6773 hdrs = ["src/stdio/scanf_core/scanf_main.h"],6774 deps = [6775 ":__support_arg_list",6776 ":scanf_config",6777 ":scanf_converter",6778 ":scanf_core_structs",6779 ":scanf_parser",6780 ":scanf_reader",6781 ],6782)6783 6784libc_support_library(6785 name = "vfscanf_internal",6786 hdrs = ["src/stdio/scanf_core/vfscanf_internal.h"],6787 deps = [6788 ":__support_arg_list",6789 ":__support_file_file",6790 ":__support_macros_attributes",6791 ":scanf_main",6792 ":scanf_reader",6793 ":types_FILE",6794 ],6795)6796 6797libc_function(6798 name = "scanf",6799 srcs = ["src/stdio/generic/scanf.cpp"],6800 hdrs = ["src/stdio/scanf.h"],6801 deps = [6802 ":__support_arg_list",6803 ":__support_file_file",6804 ":types_FILE",6805 ":vfscanf_internal",6806 ],6807)6808 6809libc_function(6810 name = "vscanf",6811 srcs = ["src/stdio/generic/vscanf.cpp"],6812 hdrs = ["src/stdio/vscanf.h"],6813 deps = [6814 ":__support_arg_list",6815 ":__support_file_file",6816 ":types_FILE",6817 ":vfscanf_internal",6818 ],6819)6820 6821libc_function(6822 name = "fscanf",6823 srcs = ["src/stdio/generic/fscanf.cpp"],6824 hdrs = ["src/stdio/fscanf.h"],6825 deps = [6826 ":__support_arg_list",6827 ":__support_file_file",6828 ":types_FILE",6829 ":vfscanf_internal",6830 ],6831)6832 6833libc_function(6834 name = "vfscanf",6835 srcs = ["src/stdio/generic/vfscanf.cpp"],6836 hdrs = ["src/stdio/vfscanf.h"],6837 deps = [6838 ":__support_arg_list",6839 ":__support_file_file",6840 ":types_FILE",6841 ":vfscanf_internal",6842 ],6843)6844 6845libc_function(6846 name = "sscanf",6847 srcs = ["src/stdio/sscanf.cpp"],6848 hdrs = ["src/stdio/sscanf.h"],6849 deps = [6850 ":__support_arg_list",6851 ":__support_file_file",6852 ":scanf_main",6853 ":scanf_string_reader",6854 ":types_FILE",6855 ],6856)6857 6858libc_function(6859 name = "vsscanf",6860 srcs = ["src/stdio/vsscanf.cpp"],6861 hdrs = ["src/stdio/vsscanf.h"],6862 deps = [6863 ":__support_arg_list",6864 ":__support_file_file",6865 ":scanf_main",6866 ":scanf_string_reader",6867 ":types_FILE",6868 ],6869)6870 6871libc_function(6872 name = "remove",6873 srcs = ["src/stdio/linux/remove.cpp"],6874 hdrs = ["src/stdio/remove.h"],6875 deps = [6876 ":__support_common",6877 ":__support_osutil_syscall",6878 ":errno",6879 ":hdr_fcntl_macros",6880 ":hdr_stdio_overlay",6881 ":types_FILE",6882 ],6883)6884 6885libc_function(6886 name = "rename",6887 srcs = ["src/stdio/linux/rename.cpp"],6888 hdrs = ["src/stdio/rename.h"],6889 target_compatible_with = select({6890 "@platforms//os:linux": [],6891 "//conditions:default": ["@platforms//:incompatible"],6892 }),6893 deps = [6894 ":__support_common",6895 ":__support_osutil_syscall",6896 ":errno",6897 ":hdr_fcntl_macros",6898 ":llvm_libc_macros_fcntl_macros",6899 ],6900)6901 6902############################### sys/mman targets ###############################6903 6904libc_function(6905 name = "madvise",6906 srcs = ["src/sys/mman/linux/madvise.cpp"],6907 hdrs = ["src/sys/mman/madvise.h"],6908 deps = [6909 ":__support_common",6910 ":__support_osutil_syscall",6911 ":errno",6912 ],6913)6914 6915libc_function(6916 name = "mincore",6917 srcs = ["src/sys/mman/linux/mincore.cpp"],6918 hdrs = ["src/sys/mman/mincore.h"],6919 deps = [6920 ":__support_common",6921 ":__support_osutil_syscall",6922 ":errno",6923 ],6924)6925 6926libc_function(6927 name = "mlock",6928 srcs = ["src/sys/mman/linux/mlock.cpp"],6929 hdrs = ["src/sys/mman/mlock.h"],6930 deps = [6931 ":__support_common",6932 ":__support_osutil_syscall",6933 ":errno",6934 ],6935)6936 6937libc_function(6938 name = "mlock2",6939 srcs = ["src/sys/mman/linux/mlock2.cpp"],6940 hdrs = ["src/sys/mman/mlock2.h"],6941 deps = [6942 ":__support_common",6943 ":__support_osutil_syscall",6944 ":errno",6945 ],6946)6947 6948libc_function(6949 name = "mlockall",6950 srcs = ["src/sys/mman/linux/mlockall.cpp"],6951 hdrs = ["src/sys/mman/mlockall.h"],6952 deps = [6953 ":__support_common",6954 ":__support_osutil_syscall",6955 ":errno",6956 ],6957)6958 6959libc_function(6960 name = "mmap",6961 srcs = ["src/sys/mman/linux/mmap.cpp"],6962 hdrs = ["src/sys/mman/mmap.h"],6963 deps = [6964 ":__support_common",6965 ":__support_osutil_syscall",6966 ":errno",6967 ],6968)6969 6970libc_support_library(6971 name = "mprotect_common",6972 hdrs = ["src/sys/mman/linux/mprotect_common.h"],6973 deps = [6974 ":__support_common",6975 ":__support_error_or",6976 ":__support_osutil_syscall",6977 ":errno",6978 ],6979)6980 6981libc_function(6982 name = "mprotect",6983 srcs = ["src/sys/mman/linux/mprotect.cpp"],6984 hdrs = ["src/sys/mman/mprotect.h"],6985 deps = [6986 ":__support_common",6987 ":__support_osutil_syscall",6988 ":errno",6989 ":mprotect_common",6990 ],6991)6992 6993libc_function(6994 name = "mremap",6995 srcs = ["src/sys/mman/linux/mremap.cpp"],6996 hdrs = ["src/sys/mman/mremap.h"],6997 deps = [6998 ":__support_common",6999 ":__support_osutil_syscall",7000 ":errno",7001 ],7002)7003 7004libc_function(7005 name = "msync",7006 srcs = ["src/sys/mman/linux/msync.cpp"],7007 hdrs = ["src/sys/mman/msync.h"],7008 deps = [7009 ":__support_common",7010 ":__support_osutil_syscall",7011 ":errno",7012 ],7013)7014 7015libc_function(7016 name = "munlock",7017 srcs = ["src/sys/mman/linux/munlock.cpp"],7018 hdrs = ["src/sys/mman/munlock.h"],7019 deps = [7020 ":__support_common",7021 ":__support_osutil_syscall",7022 ":errno",7023 ],7024)7025 7026libc_function(7027 name = "munlockall",7028 srcs = ["src/sys/mman/linux/munlockall.cpp"],7029 hdrs = ["src/sys/mman/munlockall.h"],7030 deps = [7031 ":__support_common",7032 ":__support_osutil_syscall",7033 ":errno",7034 ],7035)7036 7037libc_function(7038 name = "munmap",7039 srcs = ["src/sys/mman/linux/munmap.cpp"],7040 hdrs = ["src/sys/mman/munmap.h"],7041 deps = [7042 ":__support_common",7043 ":__support_osutil_syscall",7044 ":errno",7045 ],7046)7047 7048libc_function(7049 name = "pkey_alloc",7050 srcs = ["src/sys/mman/linux/pkey_alloc.cpp"],7051 hdrs = ["src/sys/mman/pkey_alloc.h"],7052 deps = [7053 ":__support_common",7054 ":__support_osutil_syscall",7055 ":errno",7056 ],7057)7058 7059libc_function(7060 name = "pkey_free",7061 srcs = ["src/sys/mman/linux/pkey_free.cpp"],7062 hdrs = ["src/sys/mman/pkey_free.h"],7063 deps = [7064 ":__support_common",7065 ":__support_osutil_syscall",7066 ":errno",7067 ],7068)7069 7070libc_function(7071 name = "pkey_get",7072 srcs = ["src/sys/mman/linux/pkey_get.cpp"],7073 hdrs = ["src/sys/mman/pkey_get.h"],7074 deps = [7075 ":__support_common",7076 ":__support_error_or",7077 ":__support_osutil_syscall",7078 ":errno",7079 ":pkey_common",7080 ],7081)7082 7083libc_function(7084 name = "pkey_mprotect",7085 srcs = ["src/sys/mman/linux/pkey_mprotect.cpp"],7086 hdrs = ["src/sys/mman/pkey_mprotect.h"],7087 deps = [7088 ":__support_common",7089 ":__support_osutil_syscall",7090 ":errno",7091 ":mprotect",7092 ":mprotect_common",7093 ":types_size_t",7094 ],7095)7096 7097libc_function(7098 name = "pkey_set",7099 srcs = ["src/sys/mman/linux/pkey_set.cpp"],7100 hdrs = ["src/sys/mman/pkey_set.h"],7101 deps = [7102 ":__support_common",7103 ":__support_error_or",7104 ":__support_osutil_syscall",7105 ":errno",7106 ":pkey_common",7107 ],7108)7109 7110libc_support_library(7111 name = "pkey_common",7112 hdrs = [7113 "src/sys/mman/linux/pkey_common.h",7114 ] + selects.with_or({7115 PLATFORM_CPU_X86_64: ["src/sys/mman/linux/x86_64/pkey_common.h"],7116 "//conditions:default": ["src/sys/mman/linux/generic/pkey_common.h"],7117 }),7118 deps = [7119 ":__support_common",7120 ":__support_error_or",7121 ":__support_macros_properties_architectures",7122 ":hdr_errno_macros",7123 ":hdr_stdint_proxy",7124 ],7125)7126 7127libc_function(7128 name = "posix_madvise",7129 srcs = ["src/sys/mman/linux/posix_madvise.cpp"],7130 hdrs = ["src/sys/mman/posix_madvise.h"],7131 deps = [7132 ":__support_common",7133 ":__support_osutil_syscall",7134 ":errno",7135 ],7136)7137 7138libc_function(7139 name = "remap_file_pages",7140 srcs = ["src/sys/mman/linux/remap_file_pages.cpp"],7141 hdrs = ["src/sys/mman/remap_file_pages.h"],7142 deps = [7143 ":__support_common",7144 ":__support_osutil_syscall",7145 ":errno",7146 ],7147)7148 7149libc_support_library(7150 name = "shm_common",7151 hdrs = ["src/sys/mman/linux/shm_common.h"],7152 deps = [7153 ":__support_common",7154 ":__support_cpp_array",7155 ":__support_cpp_string_view",7156 ":__support_error_or",7157 ":__support_macros_config",7158 ":errno",7159 ":string_memory_utils",7160 ],7161)7162 7163libc_function(7164 name = "shm_open",7165 srcs = ["src/sys/mman/linux/shm_open.cpp"],7166 hdrs = ["src/sys/mman/shm_open.h"],7167 deps = [7168 ":__support_common",7169 ":__support_osutil_fcntl",7170 ":errno",7171 ":hdr_fcntl_macros",7172 ":shm_common",7173 ":types_mode_t",7174 ],7175)7176 7177libc_function(7178 name = "shm_unlink",7179 srcs = ["src/sys/mman/linux/shm_unlink.cpp"],7180 hdrs = ["src/sys/mman/shm_unlink.h"],7181 deps = [7182 ":__support_common",7183 ":__support_osutil_syscall",7184 ":errno",7185 ":hdr_fcntl_macros",7186 ":shm_common",7187 ":types_mode_t",7188 ],7189)7190 7191############################# sys/resource targets #############################7192 7193libc_function(7194 name = "getrlimit",7195 srcs = ["src/sys/resource/linux/getrlimit.cpp"],7196 hdrs = ["src/sys/resource/getrlimit.h"],7197 deps = [7198 ":__support_common",7199 ":__support_osutil_syscall",7200 ":errno",7201 ":types_struct_rlimit",7202 ],7203)7204 7205libc_function(7206 name = "setrlimit",7207 srcs = ["src/sys/resource/linux/setrlimit.cpp"],7208 hdrs = ["src/sys/resource/setrlimit.h"],7209 deps = [7210 ":__support_common",7211 ":__support_osutil_syscall",7212 ":errno",7213 ":types_struct_rlimit",7214 ],7215)7216 7217############################### sys/stat targets ###############################7218 7219libc_function(7220 name = "mkdir",7221 srcs = ["src/sys/stat/linux/mkdir.cpp"],7222 hdrs = ["src/sys/stat/mkdir.h"],7223 deps = [7224 ":__support_common",7225 ":__support_osutil_syscall",7226 ":errno",7227 ":hdr_fcntl_macros",7228 ":types_mode_t",7229 ],7230)7231 7232libc_function(7233 name = "mkdirat",7234 srcs = ["src/sys/stat/linux/mkdirat.cpp"],7235 hdrs = ["src/sys/stat/mkdirat.h"],7236 deps = [7237 ":__support_common",7238 ":__support_osutil_syscall",7239 ":errno",7240 ],7241)7242 7243############################## sys/socket targets ##############################7244 7245libc_function(7246 name = "socket",7247 srcs = ["src/sys/socket/linux/socket.cpp"],7248 hdrs = ["src/sys/socket/socket.h"],7249 deps = [7250 ":__support_common",7251 ":__support_osutil_syscall",7252 ":errno",7253 ],7254)7255 7256libc_function(7257 name = "socketpair",7258 srcs = ["src/sys/socket/linux/socketpair.cpp"],7259 hdrs = ["src/sys/socket/socketpair.h"],7260 deps = [7261 ":__support_common",7262 ":__support_osutil_syscall",7263 ":errno",7264 ],7265)7266 7267libc_function(7268 name = "send",7269 srcs = ["src/sys/socket/linux/send.cpp"],7270 hdrs = ["src/sys/socket/send.h"],7271 deps = [7272 ":__support_common",7273 ":__support_osutil_syscall",7274 ":errno",7275 ":types_socklen_t",7276 ":types_ssize_t",7277 ":types_struct_sockaddr",7278 ],7279)7280 7281libc_function(7282 name = "sendto",7283 srcs = ["src/sys/socket/linux/sendto.cpp"],7284 hdrs = ["src/sys/socket/sendto.h"],7285 deps = [7286 ":__support_common",7287 ":__support_osutil_syscall",7288 ":errno",7289 ":types_socklen_t",7290 ":types_ssize_t",7291 ":types_struct_sockaddr",7292 ],7293)7294 7295libc_function(7296 name = "sendmsg",7297 srcs = ["src/sys/socket/linux/sendmsg.cpp"],7298 hdrs = ["src/sys/socket/sendmsg.h"],7299 deps = [7300 ":__support_common",7301 ":__support_osutil_syscall",7302 ":errno",7303 ":types_ssize_t",7304 ":types_struct_msghdr",7305 ],7306)7307 7308libc_function(7309 name = "recv",7310 srcs = ["src/sys/socket/linux/recv.cpp"],7311 hdrs = ["src/sys/socket/recv.h"],7312 deps = [7313 ":__support_common",7314 ":__support_osutil_syscall",7315 ":errno",7316 ":types_socklen_t",7317 ":types_ssize_t",7318 ":types_struct_sockaddr",7319 ],7320)7321 7322libc_function(7323 name = "recvfrom",7324 srcs = ["src/sys/socket/linux/recvfrom.cpp"],7325 hdrs = ["src/sys/socket/recvfrom.h"],7326 deps = [7327 ":__support_common",7328 ":__support_osutil_syscall",7329 ":errno",7330 ":types_socklen_t",7331 ":types_ssize_t",7332 ":types_struct_sockaddr",7333 ],7334)7335 7336libc_function(7337 name = "recvmsg",7338 srcs = ["src/sys/socket/linux/recvmsg.cpp"],7339 hdrs = ["src/sys/socket/recvmsg.h"],7340 deps = [7341 ":__support_common",7342 ":__support_osutil_syscall",7343 ":errno",7344 ":types_ssize_t",7345 ":types_struct_msghdr",7346 ],7347)7348 7349############################## sys/epoll targets ###############################7350 7351libc_function(7352 name = "epoll_create",7353 srcs = ["src/sys/epoll/linux/epoll_create.cpp"],7354 hdrs = ["src/sys/epoll/epoll_create.h"],7355 target_compatible_with = select({7356 "@platforms//os:linux": [],7357 "//conditions:default": ["@platforms//:incompatible"],7358 }),7359 deps = [7360 ":__support_osutil_syscall",7361 ":errno",7362 ],7363)7364 7365libc_function(7366 name = "epoll_create1",7367 srcs = ["src/sys/epoll/linux/epoll_create1.cpp"],7368 hdrs = ["src/sys/epoll/epoll_create1.h"],7369 target_compatible_with = select({7370 "@platforms//os:linux": [],7371 "//conditions:default": ["@platforms//:incompatible"],7372 }),7373 deps = [7374 ":__support_osutil_syscall",7375 ":errno",7376 ],7377)7378 7379libc_function(7380 name = "epoll_ctl",7381 srcs = ["src/sys/epoll/linux/epoll_ctl.cpp"],7382 hdrs = ["src/sys/epoll/epoll_ctl.h"],7383 target_compatible_with = select({7384 "@platforms//os:linux": [],7385 "//conditions:default": ["@platforms//:incompatible"],7386 }),7387 deps = [7388 ":__support_osutil_syscall",7389 ":errno",7390 ":hdr_sys_epoll_macros",7391 ":types_struct_epoll_event",7392 ],7393)7394 7395libc_function(7396 name = "epoll_wait",7397 srcs = ["src/sys/epoll/linux/epoll_wait.cpp"],7398 hdrs = ["src/sys/epoll/epoll_wait.h"],7399 target_compatible_with = select({7400 "@platforms//os:linux": [],7401 "//conditions:default": ["@platforms//:incompatible"],7402 }),7403 deps = [7404 ":__support_macros_sanitizer",7405 ":__support_osutil_syscall",7406 ":errno",7407 ":hdr_signal_macros",7408 ":hdr_sys_epoll_macros",7409 ":types_sigset_t",7410 ":types_struct_epoll_event",7411 ],7412)7413 7414libc_function(7415 name = "epoll_pwait",7416 srcs = ["src/sys/epoll/linux/epoll_pwait.cpp"],7417 hdrs = ["src/sys/epoll/epoll_pwait.h"],7418 target_compatible_with = select({7419 "@platforms//os:linux": [],7420 "//conditions:default": ["@platforms//:incompatible"],7421 }),7422 deps = [7423 ":__support_macros_sanitizer",7424 ":__support_osutil_syscall",7425 ":errno",7426 ":hdr_signal_macros",7427 ":hdr_sys_epoll_macros",7428 ":types_sigset_t",7429 ":types_struct_epoll_event",7430 ],7431)7432 7433libc_function(7434 name = "epoll_pwait2",7435 srcs = ["src/sys/epoll/linux/epoll_pwait2.cpp"],7436 hdrs = ["src/sys/epoll/epoll_pwait2.h"],7437 target_compatible_with = select({7438 "@platforms//os:linux": [],7439 "//conditions:default": ["@platforms//:incompatible"],7440 }),7441 deps = [7442 ":__support_macros_sanitizer",7443 ":__support_osutil_syscall",7444 ":errno",7445 ":hdr_signal_macros",7446 ":hdr_sys_epoll_macros",7447 ":types_sigset_t",7448 ":types_struct_epoll_event",7449 ":types_struct_timespec",7450 ],7451)7452 7453############################## wchar targets ###############################7454 7455libc_support_library(7456 name = "wchar_utils",7457 hdrs = ["src/wchar/wchar_utils.h"],7458 deps = [7459 ":__support_common",7460 ":__support_macros_attributes",7461 ":types_size_t",7462 ":types_wchar_t",7463 ],7464)7465 7466libc_function(7467 name = "btowc",7468 srcs = ["src/wchar/btowc.cpp"],7469 hdrs = ["src/wchar/btowc.h"],7470 deps = [7471 ":__support_common",7472 ":__support_macros_config",7473 ":hdr_wchar_macros",7474 ":types_wint_t",7475 ],7476)7477 7478libc_function(7479 name = "wcpcpy",7480 srcs = ["src/wchar/wcpcpy.cpp"],7481 hdrs = ["src/wchar/wcpcpy.h"],7482 deps = [7483 ":__support_common",7484 ":__support_macros_config",7485 ":string_utils",7486 ":types_size_t",7487 ":types_wchar_t",7488 ],7489)7490 7491libc_function(7492 name = "wcpncpy",7493 srcs = ["src/wchar/wcpncpy.cpp"],7494 hdrs = ["src/wchar/wcpncpy.h"],7495 deps = [7496 ":__support_common",7497 ":__support_macros_config",7498 ":__support_macros_null_check",7499 ":types_size_t",7500 ":types_wchar_t",7501 ],7502)7503 7504libc_function(7505 name = "wcscat",7506 srcs = ["src/wchar/wcscat.cpp"],7507 hdrs = ["src/wchar/wcscat.h"],7508 deps = [7509 ":__support_common",7510 ":__support_macros_config",7511 ":string_utils",7512 ":types_size_t",7513 ":types_wchar_t",7514 ],7515)7516 7517libc_function(7518 name = "wcschr",7519 srcs = ["src/wchar/wcschr.cpp"],7520 hdrs = ["src/wchar/wcschr.h"],7521 deps = [7522 ":__support_common",7523 ":__support_macros_config",7524 ":__support_macros_null_check",7525 ":types_wchar_t",7526 ":wchar_utils",7527 ],7528)7529 7530libc_function(7531 name = "wcscmp",7532 srcs = ["src/wchar/wcscmp.cpp"],7533 hdrs = ["src/wchar/wcscmp.h"],7534 deps = [7535 ":__support_common",7536 ":__support_macros_null_check",7537 ":types_size_t",7538 ":types_wchar_t",7539 ],7540)7541 7542libc_function(7543 name = "wcscpy",7544 srcs = ["src/wchar/wcscpy.cpp"],7545 hdrs = ["src/wchar/wcscpy.h"],7546 deps = [7547 ":__support_common",7548 ":__support_macros_config",7549 ":string_utils",7550 ":types_size_t",7551 ":types_wchar_t",7552 ],7553)7554 7555libc_function(7556 name = "wcscspn",7557 srcs = ["src/wchar/wcscspn.cpp"],7558 hdrs = ["src/wchar/wcscspn.h"],7559 deps = [7560 ":__support_common",7561 ":__support_macros_config",7562 ":__support_macros_null_check",7563 ":types_size_t",7564 ":types_wchar_t",7565 ":wchar_utils",7566 ],7567)7568 7569libc_function(7570 name = "wcslcat",7571 srcs = ["src/wchar/wcslcat.cpp"],7572 hdrs = ["src/wchar/wcslcat.h"],7573 deps = [7574 ":__support_common",7575 ":__support_macros_config",7576 ":string_utils",7577 ":types_size_t",7578 ":types_wchar_t",7579 ],7580)7581 7582libc_function(7583 name = "wcslcpy",7584 srcs = ["src/wchar/wcslcpy.cpp"],7585 hdrs = ["src/wchar/wcslcpy.h"],7586 deps = [7587 ":__support_common",7588 ":__support_macros_config",7589 ":string_utils",7590 ":types_size_t",7591 ":types_wchar_t",7592 ],7593)7594 7595libc_function(7596 name = "wcslen",7597 srcs = ["src/wchar/wcslen.cpp"],7598 hdrs = ["src/wchar/wcslen.h"],7599 deps = [7600 ":__support_common",7601 ":__support_macros_config",7602 ":string_utils",7603 ":types_size_t",7604 ":types_wchar_t",7605 ],7606)7607 7608libc_function(7609 name = "wcsncat",7610 srcs = ["src/wchar/wcsncat.cpp"],7611 hdrs = ["src/wchar/wcsncat.h"],7612 deps = [7613 ":__support_common",7614 ":__support_macros_config",7615 ":string_utils",7616 ":types_size_t",7617 ":types_wchar_t",7618 ],7619)7620 7621libc_function(7622 name = "wcsncmp",7623 srcs = ["src/wchar/wcsncmp.cpp"],7624 hdrs = ["src/wchar/wcsncmp.h"],7625 deps = [7626 ":__support_common",7627 ":__support_macros_null_check",7628 ":types_size_t",7629 ":types_wchar_t",7630 ],7631)7632 7633libc_function(7634 name = "wcsncpy",7635 srcs = ["src/wchar/wcsncpy.cpp"],7636 hdrs = ["src/wchar/wcsncpy.h"],7637 deps = [7638 ":__support_common",7639 ":__support_macros_config",7640 ":types_size_t",7641 ":types_wchar_t",7642 ],7643)7644 7645libc_function(7646 name = "wcspbrk",7647 srcs = ["src/wchar/wcspbrk.cpp"],7648 hdrs = ["src/wchar/wcspbrk.h"],7649 deps = [7650 ":__support_common",7651 ":__support_macros_null_check",7652 ":types_wchar_t",7653 ":wchar_utils",7654 ],7655)7656 7657libc_function(7658 name = "wcsrchr",7659 srcs = ["src/wchar/wcsrchr.cpp"],7660 hdrs = ["src/wchar/wcsrchr.h"],7661 deps = [7662 ":__support_common",7663 ":__support_macros_config",7664 ":__support_macros_null_check",7665 ":types_wchar_t",7666 ],7667)7668 7669libc_function(7670 name = "wcsspn",7671 srcs = ["src/wchar/wcsspn.cpp"],7672 hdrs = ["src/wchar/wcsspn.h"],7673 deps = [7674 ":__support_common",7675 ":__support_macros_config",7676 ":__support_macros_null_check",7677 ":types_size_t",7678 ":types_wchar_t",7679 ":wchar_utils",7680 ],7681)7682 7683libc_function(7684 name = "wcsstr",7685 srcs = ["src/wchar/wcsstr.cpp"],7686 hdrs = ["src/wchar/wcsstr.h"],7687 deps = [7688 ":__support_common",7689 ":__support_macros_config",7690 ":string_utils",7691 ":types_size_t",7692 ":types_wchar_t",7693 ],7694)7695 7696libc_function(7697 name = "wctob",7698 srcs = ["src/wchar/wctob.cpp"],7699 hdrs = ["src/wchar/wctob.h"],7700 deps = [7701 ":__support_common",7702 ":__support_macros_config",7703 ":__support_macros_null_check",7704 ":hdr_stdio_macros",7705 ":types_wint_t",7706 ],7707)7708 7709libc_function(7710 name = "wmemchr",7711 srcs = ["src/wchar/wmemchr.cpp"],7712 hdrs = ["src/wchar/wmemchr.h"],7713 deps = [7714 ":__support_common",7715 ":__support_macros_config",7716 ":types_size_t",7717 ":types_wchar_t",7718 ],7719)7720 7721libc_function(7722 name = "wmemcmp",7723 srcs = ["src/wchar/wmemcmp.cpp"],7724 hdrs = ["src/wchar/wmemcmp.h"],7725 deps = [7726 ":__support_common",7727 ":__support_macros_config",7728 ":__support_macros_null_check",7729 ":types_size_t",7730 ":types_wchar_t",7731 ],7732)7733 7734libc_function(7735 name = "wmemcpy",7736 srcs = ["src/wchar/wmemcpy.cpp"],7737 hdrs = ["src/wchar/wmemcpy.h"],7738 deps = [7739 ":__support_common",7740 ":__support_macros_config",7741 ":string_memory_utils",7742 ":types_size_t",7743 ":types_wchar_t",7744 ],7745)7746 7747libc_function(7748 name = "wmemmove",7749 srcs = ["src/wchar/wmemmove.cpp"],7750 hdrs = ["src/wchar/wmemmove.h"],7751 deps = [7752 ":__support_common",7753 ":__support_macros_null_check",7754 ":types_size_t",7755 ":types_wchar_t",7756 ],7757)7758 7759libc_function(7760 name = "wmempcpy",7761 srcs = ["src/wchar/wmempcpy.cpp"],7762 hdrs = ["src/wchar/wmempcpy.h"],7763 deps = [7764 ":__support_common",7765 ":string_memory_utils",7766 ":types_size_t",7767 ":types_wchar_t",7768 ],7769)7770 7771libc_function(7772 name = "wmemset",7773 srcs = ["src/wchar/wmemset.cpp"],7774 hdrs = ["src/wchar/wmemset.h"],7775 deps = [7776 ":__support_common",7777 ":types_size_t",7778 ":types_wchar_t",7779 ],7780)7781