Skip to content

Commit 1cc63e2

Browse files
apwojcikjunliumeCAHEK7
authored
[Windows] add missing symbol export (#2556)
* add missing symbol export * more missing exports * fix format issues --------- Co-authored-by: Jun Liu <[email protected]> Co-authored-by: Alex Eremin <[email protected]>
1 parent 25a399f commit 1cc63e2

19 files changed

+37
-21
lines changed

src/activ_api.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ extern "C" miopenStatus_t miopenGetActivationDescriptor(miopenActivationDescript
7070
}
7171

7272
namespace miopen::debug {
73+
MIOPEN_EXPORT
7374
void LogCmdActivation(const miopen::TensorDescriptor& x_desc,
7475
const miopen::ActivationDescriptor& activ_desc,
7576
bool fwd)

src/execution_context.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,8 @@ MIOPEN_DECLARE_ENV_VAR_BOOL(MIOPEN_DEBUG_AMD_ROCM_METADATA_PREFER_OLDER)
4646
namespace miopen {
4747
namespace debug {
4848

49-
bool IsWarmupOngoing = false; // NOLINT (cppcoreguidelines-avoid-non-const-global-variables)
49+
// NOLINTNEXTLINE (cppcoreguidelines-avoid-non-const-global-variables)
50+
MIOPEN_EXPORT bool IsWarmupOngoing = false;
5051

5152
} // namespace debug
5253
} // namespace miopen

src/find_controls.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,8 @@ namespace miopen {
4848

4949
namespace debug {
5050

51-
bool FindEnforceDisable = false; // NOLINT (cppcoreguidelines-avoid-non-const-global-variables)
51+
// NOLINTNEXTLINE (cppcoreguidelines-avoid-non-const-global-variables)
52+
MIOPEN_EXPORT bool FindEnforceDisable = false;
5253

5354
} // namespace debug
5455

src/find_db.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,8 @@ namespace miopen {
4040

4141
namespace debug {
4242

43-
bool testing_find_db_enabled = true; // NOLINT (cppcoreguidelines-avoid-non-const-global-variables)
43+
// NOLINTNEXTLINE (cppcoreguidelines-avoid-non-const-global-variables)
44+
MIOPEN_EXPORT bool testing_find_db_enabled = true;
4445

4546
/// \todo Remove when #1723 is resolved.
4647
boost::optional<std::string>& testing_find_db_path_override()

src/include/miopen/conv_algo_name.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828

2929
#include <string>
3030
#include <miopen/errors.hpp>
31+
#include <miopen/export.h>
3132

3233
namespace miopen {
3334

@@ -46,6 +47,7 @@ miopenConvFwdAlgorithm_t StringToConvolutionFwdAlgo(const std::string& s);
4647
miopenConvBwdDataAlgorithm_t StringToConvolutionBwdDataAlgo(const std::string& s);
4748
miopenConvBwdWeightsAlgorithm_t StringToConvolutionBwdWeightsAlgo(const std::string& s);
4849

50+
MIOPEN_EXPORT
4951
std::string ConvolutionAlgoToString(miopenConvAlgorithm_t algo);
5052
std::string ConvolutionAlgoToDirectionalString(miopenConvAlgorithm_t algo, conv::Direction dir);
5153

src/include/miopen/convolution.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ struct ConvolutionAttribute
153153
friend void from_json(const nlohmann::json& json, ConvolutionAttribute& conv);
154154
};
155155

156-
struct ConvolutionDescriptor : miopenConvolutionDescriptor
156+
struct MIOPEN_EXPORT ConvolutionDescriptor : miopenConvolutionDescriptor
157157
{
158158
ConvolutionDescriptor(std::size_t spatial_dim,
159159
miopenConvolutionMode_t c_mode,

src/include/miopen/execution_context.hpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,8 @@ namespace debug {
7171
/// is in progress. The library can use this, for example, to disable some
7272
/// workarounds that would affect warm-up otherwise.
7373
/// WARNING: This switch is not intended for use in multi-threaded applications.
74-
extern bool IsWarmupOngoing; // NOLINT (cppcoreguidelines-avoid-non-const-global-variables)
74+
MIOPEN_EXPORT extern bool
75+
IsWarmupOngoing; // NOLINT (cppcoreguidelines-avoid-non-const-global-variables)
7576

7677
} // namespace debug
7778

src/include/miopen/find_controls.hpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,8 @@ namespace debug {
4141
/// Disable MIOPEN_FIND_ENFORCE. Intended for debugging/testing purposes.
4242
/// Currently used during warm-up phase in MIOpenDriver.
4343
/// WARNING: This switch is not intended for use in multi-threaded applications.
44-
extern bool FindEnforceDisable; // NOLINT (cppcoreguidelines-avoid-non-const-global-variables)
44+
MIOPEN_EXPORT extern bool
45+
FindEnforceDisable; // NOLINT (cppcoreguidelines-avoid-non-const-global-variables)
4546

4647
} // namespace debug
4748

src/include/miopen/find_db.hpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,9 @@ using UserFindDbRecord = FindDbRecord_t<UserFindDb>;
6666
namespace debug {
6767

6868
// For unit tests.
69-
extern bool testing_find_db_enabled; // NOLINT (cppcoreguidelines-avoid-non-const-global-variables)
70-
extern boost::optional<std::string>&
69+
MIOPEN_EXPORT extern bool
70+
testing_find_db_enabled; // NOLINT (cppcoreguidelines-avoid-non-const-global-variables)
71+
MIOPEN_EXPORT extern boost::optional<std::string>&
7172
testing_find_db_path_override(); /// \todo Remove when #1723 is resolved.
7273

7374
} // namespace debug

src/include/miopen/gemm_v2.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,7 @@ miopenStatus_t CallGemmTimeMeasure(const Handle& handle,
133133
CallGemmType_t call_gemm_type,
134134
GemmBackend_t gemm_backend = GemmBackend_t::rocblas);
135135

136+
MIOPEN_EXPORT
136137
miopenStatus_t CallGemm(const Handle& handle,
137138
GemmDescriptor gemm_desc,
138139
ConstData_t A,
@@ -143,6 +144,7 @@ miopenStatus_t CallGemm(const Handle& handle,
143144
std::size_t c_offset,
144145
GemmBackend_t gemm_backend = GemmBackend_t::rocblas);
145146

147+
MIOPEN_EXPORT
146148
miopenStatus_t CallGemmStridedBatched(const Handle& handle,
147149
GemmDescriptor gemm_desc,
148150
ConstData_t A,

0 commit comments

Comments
 (0)