Skip to content

Commit 66603dd

Browse files
authored
[libc][NFC] Add stdint.h proxy header to fix dependency issue with <stdint.h> includes. (#150303)
#149993
1 parent c21e2a5 commit 66603dd

File tree

242 files changed

+357
-299
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

242 files changed

+357
-299
lines changed

libc/benchmarks/gpu/BenchmarkLogger.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
#include "benchmarks/gpu/BenchmarkLogger.h"
2+
#include "hdr/stdint_proxy.h"
23
#include "src/__support/CPP/string.h"
34
#include "src/__support/CPP/string_view.h"
45
#include "src/__support/OSUtil/io.h" // write_to_stderr
@@ -7,8 +8,6 @@
78
#include "src/__support/macros/properties/types.h" // LIBC_TYPES_HAS_INT128
89
#include "src/__support/uint128.h"
910

10-
#include <stdint.h>
11-
1211
namespace LIBC_NAMESPACE_DECL {
1312
namespace benchmarks {
1413

libc/benchmarks/gpu/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ add_unittest_framework_library(
4545
LibcGpuBenchmark.h
4646
BenchmarkLogger.h
4747
DEPENDS
48+
libc.hdr.stdint_proxy
4849
libc.src.__support.big_int
4950
libc.src.__support.c_string
5051
libc.src.__support.CPP.string

libc/benchmarks/gpu/LibcGpuBenchmark.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33

44
#include "benchmarks/gpu/BenchmarkLogger.h"
55
#include "benchmarks/gpu/timing/timing.h"
6+
#include "hdr/stdint_proxy.h"
67
#include "src/__support/CPP/array.h"
78
#include "src/__support/CPP/functional.h"
89
#include "src/__support/CPP/limits.h"
@@ -13,8 +14,6 @@
1314
#include "src/stdlib/rand.h"
1415
#include "src/time/clock.h"
1516

16-
#include <stdint.h>
17-
1817
namespace LIBC_NAMESPACE_DECL {
1918

2019
namespace benchmarks {

libc/benchmarks/gpu/src/math/CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ add_benchmark(
3131
SRCS
3232
sin_benchmark.cpp
3333
DEPENDS
34+
libc.hdr.stdint_proxy
3435
libc.src.math.sin
3536
libc.src.math.sinf
3637
libc.src.stdlib.srand
@@ -51,6 +52,7 @@ add_benchmark(
5152
SRCS
5253
atan2_benchmark.cpp
5354
DEPENDS
55+
libc.hdr.stdint_proxy
5456
libc.src.math.atan2
5557
libc.src.stdlib.srand
5658
libc.src.stdlib.rand

libc/benchmarks/gpu/src/math/platform.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,10 @@
77
//===----------------------------------------------------------------------===//
88
#ifndef LLVM_LIBC_SRC_MATH_AMDGPU_PLATFORM_H
99
#define LLVM_LIBC_SRC_MATH_AMDGPU_PLATFORM_H
10+
11+
#include "hdr/stdint_proxy.h"
1012
#include "src/__support/macros/attributes.h"
1113
#include "src/__support/macros/config.h"
12-
#include <stdint.h>
1314

1415
namespace LIBC_NAMESPACE_DECL {
1516

libc/benchmarks/gpu/timing/amdgpu/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ add_header_library(
33
HDRS
44
timing.h
55
DEPENDS
6+
libc.hdr.stdint_proxy
67
libc.src.__support.common
78
libc.src.__support.macros.config
89
libc.src.__support.macros.attributes

libc/benchmarks/gpu/timing/amdgpu/timing.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
#ifndef LLVM_LIBC_UTILS_GPU_TIMING_AMDGPU
1010
#define LLVM_LIBC_UTILS_GPU_TIMING_AMDGPU
1111

12+
#include "hdr/stdint_proxy.h"
1213
#include "src/__support/CPP/array.h"
1314
#include "src/__support/CPP/atomic.h"
1415
#include "src/__support/CPP/type_traits.h"
@@ -17,8 +18,6 @@
1718
#include "src/__support/macros/attributes.h"
1819
#include "src/__support/macros/config.h"
1920

20-
#include <stdint.h>
21-
2221
namespace LIBC_NAMESPACE_DECL {
2322

2423
// Returns the overhead associated with calling the profiling region. This

libc/benchmarks/gpu/timing/nvptx/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ add_header_library(
33
HDRS
44
timing.h
55
DEPENDS
6+
libc.hdr.stdint_proxy
67
libc.src.__support.common
78
libc.src.__support.macros.config
89
libc.src.__support.macros.attributes

libc/benchmarks/gpu/timing/nvptx/timing.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
#ifndef LLVM_LIBC_UTILS_GPU_TIMING_NVPTX
1010
#define LLVM_LIBC_UTILS_GPU_TIMING_NVPTX
1111

12+
#include "hdr/stdint_proxy.h"
1213
#include "src/__support/CPP/array.h"
1314
#include "src/__support/CPP/atomic.h"
1415
#include "src/__support/CPP/type_traits.h"
@@ -17,8 +18,6 @@
1718
#include "src/__support/macros/attributes.h"
1819
#include "src/__support/macros/config.h"
1920

20-
#include <stdint.h>
21-
2221
namespace LIBC_NAMESPACE_DECL {
2322

2423
// Returns the overhead associated with calling the profiling region. This

libc/config/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@ add_header_library(
33
HDRS
44
app.h
55
DEPENDS
6+
libc.hdr.stdint_proxy
67
libc.src.__support.common
78
)

0 commit comments

Comments
 (0)