Skip to content

Commit db6b7a8

Browse files
authored
[libc][NFC] Strip all training whitespace and missing newlines (llvm#124163)
1 parent 0290693 commit db6b7a8

File tree

40 files changed

+67
-67
lines changed

40 files changed

+67
-67
lines changed

libc/benchmarks/distributions/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,4 @@ As identified in the [automemcpy](https://research.google/pubs/pub50338/) paper:
3131

3232
## Note
3333

34-
Except for `GoogleD`, all distributions are gathered over one week worth of data.
34+
Except for `GoogleD`, all distributions are gathered over one week worth of data.

libc/benchmarks/gpu/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ function(add_benchmark benchmark_name)
1010
"LINK_LIBRARIES;DEPENDS" # Multi-value arguments
1111
${ARGN}
1212
)
13-
13+
1414
if(NOT libc.src.time.clock IN_LIST TARGET_LLVMLIBC_ENTRYPOINTS)
1515
message(FATAL_ERROR "target does not support clock")
1616
endif()

libc/config/baremetal/riscv/entrypoints.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -463,7 +463,7 @@ if(LIBC_COMPILER_HAS_FIXED_POINT)
463463
libc.src.stdfix.kbits
464464
libc.src.stdfix.ukbits
465465
libc.src.stdfix.lkbits
466-
libc.src.stdfix.ulkbits
466+
libc.src.stdfix.ulkbits
467467
)
468468
endif()
469469

libc/config/linux/aarch64/entrypoints.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -439,7 +439,7 @@ set(TARGET_LIBM_ENTRYPOINTS
439439
libc.src.math.fabs
440440
libc.src.math.fabsf
441441
libc.src.math.fabsl
442-
libc.src.math.fadd
442+
libc.src.math.fadd
443443
libc.src.math.faddl
444444
libc.src.math.fadd
445445
libc.src.math.fdim

libc/config/linux/arm/entrypoints.txt

+2-2
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ set(TARGET_LIBM_ENTRYPOINTS
215215
libc.src.complex.cproj
216216
libc.src.complex.cprojf
217217
libc.src.complex.cprojl
218-
218+
219219
# fenv.h entrypoints
220220
libc.src.fenv.feclearexcept
221221
libc.src.fenv.fedisableexcept
@@ -268,7 +268,7 @@ set(TARGET_LIBM_ENTRYPOINTS
268268
libc.src.math.fabs
269269
libc.src.math.fabsf
270270
libc.src.math.fabsl
271-
libc.src.math.fadd
271+
libc.src.math.fadd
272272
libc.src.math.faddl
273273
libc.src.math.fadd
274274
libc.src.math.fdim

libc/config/linux/riscv/entrypoints.txt

+2-2
Original file line numberDiff line numberDiff line change
@@ -432,7 +432,7 @@ set(TARGET_LIBM_ENTRYPOINTS
432432
libc.src.math.fabs
433433
libc.src.math.fabsf
434434
libc.src.math.fabsl
435-
libc.src.math.fadd
435+
libc.src.math.fadd
436436
libc.src.math.faddl
437437
libc.src.math.fadd
438438
libc.src.math.fdim
@@ -630,7 +630,7 @@ if(LIBC_TYPES_HAS_CFLOAT128)
630630
)
631631
endif()
632632

633-
if(LIBC_TYPES_HAS_FLOAT128)
633+
if(LIBC_TYPES_HAS_FLOAT128)
634634
list(APPEND TARGET_LIBM_ENTRYPOINTS
635635
# math.h C23 _Float128 entrypoints
636636
libc.src.math.canonicalizef128

libc/config/linux/x86_64/entrypoints.txt

+3-3
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,7 @@ set(TARGET_LIBM_ENTRYPOINTS
377377
libc.src.complex.cproj
378378
libc.src.complex.cprojf
379379
libc.src.complex.cprojl
380-
380+
381381
# fenv.h entrypoints
382382
libc.src.fenv.feclearexcept
383383
libc.src.fenv.fedisableexcept
@@ -440,7 +440,7 @@ set(TARGET_LIBM_ENTRYPOINTS
440440
libc.src.math.fabs
441441
libc.src.math.fabsf
442442
libc.src.math.fabsl
443-
libc.src.math.fadd
443+
libc.src.math.fadd
444444
libc.src.math.faddl
445445
libc.src.math.fadd
446446
libc.src.math.fdim
@@ -756,7 +756,7 @@ if(LIBC_TYPES_HAS_CFLOAT128)
756756
endif()
757757

758758
if(LIBC_TYPES_HAS_FLOAT128)
759-
list(APPEND TARGET_LIBM_ENTRYPOINTS
759+
list(APPEND TARGET_LIBM_ENTRYPOINTS
760760
# math.h C23 _Float128 entrypoints
761761
libc.src.math.canonicalizef128
762762
libc.src.math.ceilf128

libc/docs/dev/printf_behavior.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ If a number passed as a field width or precision value is out of range for an
173173
int, then it will be treated as the largest value in the int range
174174
(e.g. "%-999999999999.999999999999s" is the same as "%-2147483647.2147483647s").
175175

176-
If the field width is set to INT_MIN by using the '*' form,
176+
If the field width is set to INT_MIN by using the '*' form,
177177
e.g. printf("%*d", INT_MIN, 1), it will be treated as INT_MAX, since -INT_MIN is
178178
not representable as an int.
179179

libc/docs/dev/undefined_behavior.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,8 @@ POSIX.1 leaves that when the name of a shared memory object does not begin with
7878
Handling of NULL arguments to the 's' format specifier
7979
------------------------------------------------------
8080
The C standard does not specify behavior for ``printf("%s", NULL)``. We will
81-
print the string literal ``(null)`` unless using the
82-
``LIBC_COPT_PRINTF_NO_NULLPTR_CHECKS`` option described in :ref:`printf
81+
print the string literal ``(null)`` unless using the
82+
``LIBC_COPT_PRINTF_NO_NULLPTR_CHECKS`` option described in :ref:`printf
8383
behavior<printf_behavior>`.
8484

8585
Unknown Math Rounding Direction

libc/docs/gpu/rpc.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ linked in by forwarding the static library to the device-side link job.
253253
Extensions
254254
----------
255255

256-
The opcode is a 32-bit integer that must be unique to the requested operation.
257-
All opcodes used by ``libc`` internally have the character ``c`` in the most
256+
The opcode is a 32-bit integer that must be unique to the requested operation.
257+
All opcodes used by ``libc`` internally have the character ``c`` in the most
258258
significant byte. Any other opcode is available for use outside of the ``libc``
259259
implementation.

libc/docs/platform_support.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ For Linux, we support kernel versions as listed on
1212
date), ``stable``, and ``mainline`` versions. We actively adopt new features
1313
from ``linux-next``.
1414

15-
For Windows, we plan to support products within their lifecycle. Please refer to
15+
For Windows, we plan to support products within their lifecycle. Please refer to
1616
`Search Product and Services Lifecycle Information <https://learn.microsoft.com/en-us/lifecycle/products/?products=windows>`_ for more information.
1717

1818
LLVM-libc does not guarantee backward compatibility with operating systems that

libc/fuzzing/__support/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ add_libc_fuzzer(
2222
libc.src.__support.HashTable.table
2323
COMPILE_OPTIONS
2424
-D__LIBC_EXPLICIT_SIMD_OPT
25-
)
25+
)
2626

2727
# TODO: FreeListHeap uses the _end symbol which conflicts with the _end symbol
2828
# defined by GPU start.cpp files so for now we exclude this fuzzer on GPU.

libc/include/llvm-libc-types/CMakeLists.txt

+6-6
Original file line numberDiff line numberDiff line change
@@ -102,15 +102,15 @@ add_header(__getoptargv_t HDR __getoptargv_t.h)
102102
add_header(wchar_t HDR wchar_t.h)
103103
add_header(char8_t HDR char8_t.h)
104104
add_header(
105-
char16_t
106-
HDR
105+
char16_t
106+
HDR
107107
char16_t.h
108108
DEPENDS
109109
libc.include.llvm-libc-macros.stdint_macros
110110
)
111111
add_header(
112-
char32_t
113-
HDR
112+
char32_t
113+
HDR
114114
char32_t.h
115115
DEPENDS
116116
libc.include.llvm-libc-macros.stdint_macros
@@ -145,8 +145,8 @@ add_header(cfloat16 HDR cfloat16.h)
145145
add_header(fsblkcnt_t HDR fsblkcnt_t.h)
146146
add_header(fsfilcnt_t HDR fsfilcnt_t.h)
147147
add_header(
148-
struct_statvfs
149-
HDR
148+
struct_statvfs
149+
HDR
150150
struct_statvfs.h
151151
DEPENDS
152152
.fsblkcnt_t

libc/include/stdfix.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
header: stdfix.h
22
header_template: stdfix.h.def
33
macros: []
4-
types:
4+
types:
55
- type_name: stdfix-types
66
enums: []
77
objects: []

libc/include/sys/uio.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
header: sys/uio.h
22
header_template: uio.h.def
33
macros: []
4-
types:
4+
types:
55
- type_name: struct_iovec
66
- type_name: ssize_t
77
enums: []

libc/src/__support/CPP/CMakeLists.txt

+2-2
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ add_header_library(
8383
.string_view
8484
libc.hdr.func.free
8585
libc.hdr.func.malloc
86-
libc.hdr.func.realloc
86+
libc.hdr.func.realloc
8787
libc.src.__support.common
8888
libc.src.__support.integer_to_string
8989
libc.src.string.memory_utils.inline_memcpy
@@ -203,7 +203,7 @@ add_object_library(
203203
DEPENDS
204204
libc.hdr.func.free
205205
libc.hdr.func.malloc
206-
libc.hdr.func.aligned_alloc
206+
libc.hdr.func.aligned_alloc
207207
libc.src.__support.common
208208
libc.src.__support.macros.properties.os
209209
)

libc/src/__support/threads/linux/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ add_object_library(
7979
.futex_utils
8080
libc.config.app_h
8181
libc.include.sys_syscall
82-
libc.hdr.fcntl_macros
82+
libc.hdr.fcntl_macros
8383
libc.src.errno.errno
8484
libc.src.__support.CPP.atomic
8585
libc.src.__support.CPP.stringstream

libc/src/__support/threads/spin_lock.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class SpinLock {
3434
// .LBB0_2: | jmp .LBB0_4
3535
// isb | .LBB0_2:
3636
// .LBB0_3: | pause
37-
// ldrb w9, [x0] | .LBB0_3:
37+
// ldrb w9, [x0] | .LBB0_3:
3838
// tbnz w9, #0, .LBB0_2 | movzx eax, byte ptr [rdi]
3939
// b .LBB0_1 | test al, 1
4040
// .LBB0_4: | jne .LBB0_2

libc/src/__support/time/windows/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
add_header_library(
2-
performance_counter
2+
performance_counter
33
HDRS
44
performance_counter.h
55
DEPENDS

libc/src/math/nvptx/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ if(CUDAToolkit_FOUND)
99
if (EXISTS ${libdevice_path})
1010
message(STATUS "Found the CUDA device library. Implementations falling back "
1111
"to the vendor libraries will be resolved statically.")
12-
set(bitcode_link_flags
12+
set(bitcode_link_flags
1313
"SHELL:-Xclang -mlink-builtin-bitcode -Xclang ${libdevice_path}")
1414
endif()
1515
else()

libc/src/stdlib/CMakeLists.txt

+3-3
Original file line numberDiff line numberDiff line change
@@ -539,7 +539,7 @@ add_entrypoint_object(
539539
libc.src.__support.OSUtil.osutil
540540
)
541541

542-
# TODO: Move all exit functions to linux specific
542+
# TODO: Move all exit functions to linux specific
543543

544544
if(TARGET libc.src.__support.threads.mutex)
545545
add_header_library(
@@ -563,7 +563,7 @@ add_entrypoint_object(
563563
HDRS
564564
atexit.h
565565
CXX_STANDARD
566-
20 # For constinit
566+
20 # For constinit
567567
DEPENDS
568568
.exit_handler
569569
)
@@ -575,7 +575,7 @@ add_entrypoint_object(
575575
HDRS
576576
at_quick_exit.h
577577
CXX_STANDARD
578-
20 # For constinit
578+
20 # For constinit
579579
DEPENDS
580580
.exit_handler
581581
.atexit

libc/test/src/__support/File/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ add_libc_test(
1616
DEPENDS
1717
libc.include.stdio
1818
libc.hdr.types.size_t
19-
libc.src.errno.errno
19+
libc.src.errno.errno
2020
libc.src.__support.CPP.new
2121
libc.src.__support.File.file
2222
)

libc/test/src/math/CMakeLists.txt

+2-2
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ add_fp_unittest(
104104
SRCS
105105
sinf16_test.cpp
106106
DEPENDS
107-
libc.src.math.sinf16
107+
libc.src.math.sinf16
108108
)
109109

110110
add_fp_unittest(
@@ -198,7 +198,7 @@ add_fp_unittest(
198198
SRCS
199199
tanf16_test.cpp
200200
DEPENDS
201-
libc.src.math.tanf16
201+
libc.src.math.tanf16
202202
)
203203

204204
add_fp_unittest(

libc/test/src/math/smoke/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ add_fp_unittest(
129129
tanf16_test.cpp
130130
DEPENDS
131131
libc.src.errno.errno
132-
libc.src.math.tanf16
132+
libc.src.math.tanf16
133133
)
134134

135135
add_fp_unittest(

libc/test/src/signal/CMakeLists.txt

+3-3
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ add_libc_unittest(
6262
sigaddset_test.cpp
6363
DEPENDS
6464
libc.include.signal
65-
libc.src.errno.errno
65+
libc.src.errno.errno
6666
libc.src.signal.sigaddset
6767
libc.test.UnitTest.ErrnoSetterMatcher
6868
)
@@ -89,7 +89,7 @@ add_libc_unittest(
8989
sigfillset_test.cpp
9090
DEPENDS
9191
libc.include.signal
92-
libc.src.errno.errno
92+
libc.src.errno.errno
9393
libc.src.signal.raise
9494
libc.src.signal.sigfillset
9595
libc.src.signal.sigprocmask
@@ -104,7 +104,7 @@ add_libc_unittest(
104104
sigdelset_test.cpp
105105
DEPENDS
106106
libc.include.signal
107-
libc.src.errno.errno
107+
libc.src.errno.errno
108108
libc.src.signal.raise
109109
libc.src.signal.sigdelset
110110
libc.src.signal.sigfillset

libc/test/src/stdfix/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ foreach(suffix IN ITEMS hr r lr hk k lk uhr ur ulr uhk uk ulk)
5757
libc.src.stdfix.round${suffix}
5858
libc.src.__support.fixed_point.fx_bits
5959
)
60-
60+
6161
add_libc_test(
6262
${suffix}bits_test
6363
SUITE

libc/test/src/sys/resource/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ add_libc_unittest(
1111
DEPENDS
1212
libc.include.fcntl
1313
libc.include.sys_resource
14-
libc.src.errno.errno
14+
libc.src.errno.errno
1515
libc.src.fcntl.open
1616
libc.src.sys.resource.getrlimit
1717
libc.src.sys.resource.setrlimit

libc/test/src/sys/select/CMakeLists.txt

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ add_libc_unittest(
99
select_ui_test.cpp
1010
DEPENDS
1111
libc.include.unistd
12-
libc.src.errno.errno
12+
libc.src.errno.errno
1313
libc.src.sys.select.select
1414
libc.src.unistd.read
1515
)
@@ -22,7 +22,7 @@ add_libc_unittest(
2222
select_failure_test.cpp
2323
DEPENDS
2424
libc.include.unistd
25-
libc.src.errno.errno
25+
libc.src.errno.errno
2626
libc.src.sys.select.select
2727
libc.src.unistd.read
2828
libc.test.UnitTest.ErrnoSetterMatcher

libc/test/src/sys/sendfile/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ add_libc_unittest(
1111
DEPENDS
1212
libc.hdr.fcntl_macros
1313
libc.include.sys_stat
14-
libc.src.errno.errno
14+
libc.src.errno.errno
1515
libc.src.fcntl.open
1616
libc.src.sys.sendfile.sendfile
1717
libc.src.unistd.close

libc/test/src/sys/wait/CMakeLists.txt

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ add_libc_unittest(
88
waitpid_test.cpp
99
DEPENDS
1010
libc.include.sys_wait
11-
libc.src.errno.errno
11+
libc.src.errno.errno
1212
libc.src.sys.wait.waitpid
1313
)
1414

@@ -20,6 +20,6 @@ add_libc_unittest(
2020
wait4_test.cpp
2121
DEPENDS
2222
libc.include.sys_wait
23-
libc.src.errno.errno
23+
libc.src.errno.errno
2424
libc.src.sys.wait.wait4
2525
)

0 commit comments

Comments
 (0)