Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move c/include/cccl/*.h files to c/include/cccl/c/*.h #2428

Merged
merged 7 commits into from
Sep 19, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 4 additions & 6 deletions c/include/cccl/reduce.h → c/include/cccl/c/reduce.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@
#pragma once

#ifndef CCCL_C_EXPERIMENTAL
# warning "C exposure is experimental and subject to change. Define CCCL_C_EXPERIMENTAL to acknowledge this warning."
#else // ^^^ !CCCL_C_EXPERIMENTAL ^^^ / vvv CCCL_C_EXPERIMENTAL vvv
# error "C exposure is experimental and subject to change. Define CCCL_C_EXPERIMENTAL to acknowledge this notice."
#endif

# include <cuda.h>
#include <cuda.h>

# include <cccl/types.h>
#include <cccl/c/types.h>

struct cccl_device_reduce_build_result_t
{
Expand Down Expand Up @@ -55,5 +55,3 @@ extern "C" CCCL_C_API CUresult cccl_device_reduce(
CUstream stream) noexcept;

extern "C" CCCL_C_API CUresult cccl_device_reduce_cleanup(cccl_device_reduce_build_result_t* bld_ptr);

#endif // CCCL_C_EXPERIMENTAL
16 changes: 7 additions & 9 deletions c/include/cccl/types.h → c/include/cccl/c/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@
#pragma once

#ifndef CCCL_C_EXPERIMENTAL
# warning "C exposure is experimental and subject to change. Define CCCL_C_EXPERIMENTAL to acknowledge this warning."
#else // ^^^ !CCCL_C_EXPERIMENTAL ^^^ / vvv CCCL_C_EXPERIMENTAL vvv
# error "C exposure is experimental and subject to change. Define CCCL_C_EXPERIMENTAL to acknowledge this notice."
#endif
rwgk marked this conversation as resolved.
Show resolved Hide resolved

# if defined(_WIN32)
# define CCCL_C_API __declspec(dllexport)
# else
# define CCCL_C_API __attribute__((visibility("default")))
# endif
#if defined(_WIN32)
# define CCCL_C_API __declspec(dllexport)
#else
# define CCCL_C_API __attribute__((visibility("default")))
#endif
rwgk marked this conversation as resolved.
Show resolved Hide resolved

enum class cccl_type_enum
{
Expand Down Expand Up @@ -81,5 +81,3 @@ struct cccl_iterator_t
cccl_type_info value_type;
void* state;
};

#endif // CCCL_C_EXPERIMENTAL
2 changes: 1 addition & 1 deletion c/src/reduce.cu
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include <iostream>
#include <memory>

#include <cccl/reduce.h>
#include <cccl/c/reduce.h>
#include <nvJitLink.h>
#include <nvrtc.h>

Expand Down
2 changes: 1 addition & 1 deletion c/test/c2h.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#include <vector>

#include <catch2/catch.hpp>
#include <cccl/reduce.h>
#include <cccl/c/reduce.h>
#include <nvrtc.h>

static std::string inspect_sass(const void* cubin, size_t cubin_size)
Expand Down
Loading