diff --git a/paddle/fluid/platform/dynload/cusparse.cc b/paddle/fluid/platform/dynload/cusparse.cc index ea7c502e3e681c94cea76b7c3176c7de29adfc2b..998437997547bd81d33d853eafacc65fa8f9f5eb 100644 --- a/paddle/fluid/platform/dynload/cusparse.cc +++ b/paddle/fluid/platform/dynload/cusparse.cc @@ -24,13 +24,14 @@ namespace dynload { CUSPARSE_ROUTINE_EACH(DEFINE_WRAP); #endif -#ifdef CUBLAS_BLAS_ROUTINE_EACH_R2 -CUSPARSE_ROUTINE_EACH_R2(DEFINE_WRAP); -#endif - #ifdef CUSPARSE_ROUTINE_EACH_11020 CUSPARSE_ROUTINE_EACH_11020(DEFINE_WRAP); #endif + +#ifdef CUSPARSE_ROUTINE_EACH_R2 +CUSPARSE_ROUTINE_EACH_R2(DEFINE_WRAP); +#endif + } // namespace dynload } // namespace platform } // namespace paddle diff --git a/paddle/phi/backends/dynload/cusparse.cc b/paddle/phi/backends/dynload/cusparse.cc index a37fbf35a26e807148ae458128f541b41ab9fdac..326645726bbed2b246989fd3784274a6265a9068 100644 --- a/paddle/phi/backends/dynload/cusparse.cc +++ b/paddle/phi/backends/dynload/cusparse.cc @@ -26,12 +26,13 @@ void *cusparse_dso_handle; CUSPARSE_ROUTINE_EACH(DEFINE_WRAP); #endif -#ifdef CUBLAS_BLAS_ROUTINE_EACH_R2 -CUSPARSE_ROUTINE_EACH_R2(DEFINE_WRAP); -#endif - #ifdef CUSPARSE_ROUTINE_EACH_11020 CUSPARSE_ROUTINE_EACH_11020(DEFINE_WRAP); #endif + +#ifdef CUSPARSE_ROUTINE_EACH_R2 +CUSPARSE_ROUTINE_EACH_R2(DEFINE_WRAP); +#endif + } // namespace dynload } // namespace phi