chore: import upstream snapshot with attribution
This commit is contained in:
+74
@@ -0,0 +1,74 @@
|
||||
/*
|
||||
* ******************************************************************************
|
||||
* *
|
||||
* *
|
||||
* * This program and the accompanying materials are made available under the
|
||||
* * terms of the Apache License, Version 2.0 which is available at
|
||||
* * https://www.apache.org/licenses/LICENSE-2.0.
|
||||
* *
|
||||
* * See the NOTICE file distributed with this work for additional
|
||||
* * information regarding copyright ownership.
|
||||
* * Unless required by applicable law or agreed to in writing, software
|
||||
* * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
* * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
* * License for the specific language governing permissions and limitations
|
||||
* * under the License.
|
||||
* *
|
||||
* * SPDX-License-Identifier: Apache-2.0
|
||||
* *****************************************************************************
|
||||
*/
|
||||
|
||||
//
|
||||
// Created by agibsonccc on 3/10/25.
|
||||
//
|
||||
|
||||
#include <loops/cuda/broadcasting.chpp>
|
||||
#include <system/type_boilerplate.h>
|
||||
#include <loops/pairwise_instantiations_single.h>
|
||||
|
||||
/*
|
||||
* Function instantiation for Broadcast::execBroadcast with dimension
|
||||
*/
|
||||
|
||||
ITERATE_COMBINATIONS_3(
|
||||
SD_SINGLE_TYPE_@COMB1@,
|
||||
SD_SINGLE_TYPE_@COMB2@,
|
||||
SD_SINGLE_TYPE_@COMB3@,
|
||||
INSTANT_PROCESS_COMBINATION_3,
|
||||
functions::broadcast::Broadcast,
|
||||
::execBroadcast(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
void const* x,
|
||||
sd::LongType const* xShapeInfo,
|
||||
void const* y,
|
||||
sd::LongType const* yShapeInfo,
|
||||
void* z,
|
||||
sd::LongType const* zShapeInfo,
|
||||
sd::LongType* dimension,
|
||||
sd::LongType dimensionLength,
|
||||
sd::LongType const* tadOnlyShapeInfo,
|
||||
sd::LongType const* tadOffsets,
|
||||
sd::LongType const* tadOnlyShapeInfoZ,
|
||||
sd::LongType const* tadOffsetsZ);
|
||||
);
|
||||
|
||||
ITERATE_COMBINATIONS_3(
|
||||
SD_SINGLE_TYPE_@COMB1@,
|
||||
SD_SINGLE_TYPE_@COMB2@,
|
||||
SD_SINGLE_TYPE_@COMB3@,
|
||||
INSTANT_PROCESS_COMBINATION_3,
|
||||
functions::broadcast::Broadcast,
|
||||
::execBroadcast(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
void const* x,
|
||||
sd::LongType const* xShapeInfo,
|
||||
void const* y,
|
||||
sd::LongType const* yShapeInfo,
|
||||
void* z,
|
||||
sd::LongType const* zShapeInfo);
|
||||
);
|
||||
|
||||
+55
@@ -0,0 +1,55 @@
|
||||
/*
|
||||
* ******************************************************************************
|
||||
* *
|
||||
* *
|
||||
* * This program and the accompanying materials are made available under the
|
||||
* * terms of the Apache License, Version 2.0 which is available at
|
||||
* * https://www.apache.org/licenses/LICENSE-2.0.
|
||||
* *
|
||||
* * See the NOTICE file distributed with this work for additional
|
||||
* * information regarding copyright ownership.
|
||||
* * Unless required by applicable law or agreed to in writing, software
|
||||
* * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
* * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
* * License for the specific language governing permissions and limitations
|
||||
* * under the License.
|
||||
* *
|
||||
* * SPDX-License-Identifier: Apache-2.0
|
||||
* *****************************************************************************
|
||||
*/
|
||||
|
||||
//
|
||||
// Created by agibsonccc on 3/10/25.
|
||||
//
|
||||
|
||||
#include <loops/cuda/broadcasting.chpp>
|
||||
#include <system/type_boilerplate.h>
|
||||
#include <loops/pairwise_instantiations_single.h>
|
||||
|
||||
/*
|
||||
* Function instantiation for Broadcast::execInverseBroadcast
|
||||
*/
|
||||
|
||||
ITERATE_COMBINATIONS_3(
|
||||
SD_SINGLE_TYPE_@COMB1@,
|
||||
SD_SINGLE_TYPE_@COMB2@,
|
||||
SD_SINGLE_TYPE_@COMB3@,
|
||||
INSTANT_PROCESS_COMBINATION_3,
|
||||
functions::broadcast::Broadcast,
|
||||
::execInverseBroadcast(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
void const* x,
|
||||
sd::LongType const* xShapeInfo,
|
||||
void const* y,
|
||||
sd::LongType const* yShapeInfo,
|
||||
void* z,
|
||||
sd::LongType const* zShapeInfo,
|
||||
sd::LongType* dimension,
|
||||
sd::LongType dimensionLength,
|
||||
sd::LongType const* tadOnlyShapeInfo,
|
||||
sd::LongType const* tadOffsets,
|
||||
sd::LongType const* tadOnlyShapeInfoZ,
|
||||
sd::LongType const* tadOffsetsZ);
|
||||
);
|
||||
+96
@@ -0,0 +1,96 @@
|
||||
/* ******************************************************************************
|
||||
*
|
||||
*
|
||||
* This program and the accompanying materials are made available under the
|
||||
* terms of the Apache License, Version 2.0 which is available at
|
||||
* https://www.apache.org/licenses/LICENSE-2.0.
|
||||
*
|
||||
* See the NOTICE file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
******************************************************************************/
|
||||
|
||||
//
|
||||
// Created by agibsonccc on 3/10/25.
|
||||
//
|
||||
|
||||
#include <loops/cuda/broadcasting.chpp>
|
||||
#include <system/type_boilerplate.h>
|
||||
#include <loops/pairwise_instantiations_single.h>
|
||||
|
||||
/*
|
||||
* Function Instantiation:
|
||||
* Broadcast::execBroadcast instantiated for types in @COMB1@, @COMB2@, @COMB3@
|
||||
*/
|
||||
|
||||
ITERATE_COMBINATIONS_3(
|
||||
SD_COMMON_TYPES_PART_@COMB1@,
|
||||
SD_COMMON_TYPES_PART_@COMB2@,
|
||||
SD_COMMON_TYPES_PART_@COMB3@,
|
||||
INSTANT_PROCESS_COMBINATION_3,
|
||||
functions::broadcast::Broadcast,
|
||||
::execBroadcast(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
void const* x,
|
||||
sd::LongType const* xShapeInfo,
|
||||
void const* y,
|
||||
sd::LongType const* yShapeInfo,
|
||||
void* z,
|
||||
sd::LongType const* zShapeInfo,
|
||||
sd::LongType* dimension,
|
||||
sd::LongType dimensionLength,
|
||||
sd::LongType const* tadOnlyShapeInfo,
|
||||
sd::LongType const* tadOffsets,
|
||||
sd::LongType const* tadOnlyShapeInfoZ,
|
||||
sd::LongType const* tadOffsetsZ);
|
||||
);
|
||||
|
||||
ITERATE_COMBINATIONS_3(
|
||||
SD_COMMON_TYPES_PART_@COMB1@,
|
||||
SD_COMMON_TYPES_PART_@COMB2@,
|
||||
SD_COMMON_TYPES_PART_@COMB3@,
|
||||
INSTANT_PROCESS_COMBINATION_3,
|
||||
functions::broadcast::Broadcast,
|
||||
::execBroadcast(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
void const* x,
|
||||
sd::LongType const* xShapeInfo,
|
||||
void const* y,
|
||||
sd::LongType const* yShapeInfo,
|
||||
void* z,
|
||||
sd::LongType const* zShapeInfo);
|
||||
);
|
||||
|
||||
ITERATE_COMBINATIONS_3(
|
||||
SD_COMMON_TYPES_PART_@COMB1@,
|
||||
SD_COMMON_TYPES_PART_@COMB2@,
|
||||
SD_COMMON_TYPES_PART_@COMB3@,
|
||||
INSTANT_PROCESS_COMBINATION_3,
|
||||
functions::broadcast::Broadcast,
|
||||
::execInverseBroadcast(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
void const* x,
|
||||
sd::LongType const* xShapeInfo,
|
||||
void const* y,
|
||||
sd::LongType const* yShapeInfo,
|
||||
void* z,
|
||||
sd::LongType const* zShapeInfo,
|
||||
sd::LongType* dimension,
|
||||
sd::LongType dimensionLength,
|
||||
sd::LongType const* tadOnlyShapeInfo,
|
||||
sd::LongType const* tadOffsets,
|
||||
sd::LongType const* tadOnlyShapeInfoZ,
|
||||
sd::LongType const* tadOffsetsZ);
|
||||
);
|
||||
+81
@@ -0,0 +1,81 @@
|
||||
/* ******************************************************************************
|
||||
*
|
||||
*
|
||||
* This program and the accompanying materials are made available under the
|
||||
* terms of the Apache License, Version 2.0 which is available at
|
||||
* https://www.apache.org/licenses/LICENSE-2.0.
|
||||
*
|
||||
* See the NOTICE file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
******************************************************************************/
|
||||
|
||||
//
|
||||
// Created by agibsonccc on 3/10/25.
|
||||
//
|
||||
|
||||
#include <loops/cuda/indexreduce.cu>
|
||||
#include <system/type_boilerplate.h>
|
||||
#include <loops/pairwise_instantiations_single.h>
|
||||
|
||||
/*
|
||||
* Function Instantiation:
|
||||
* IndexReduce::executeIndexReduce instantiated for types in @COMB1@, @COMB2@
|
||||
* Note: Using @COMB1@ for X type and @COMB2@ for Z type (2-type combinations)
|
||||
*/
|
||||
|
||||
ITERATE_COMBINATIONS(
|
||||
SD_COMMON_TYPES_PART_@COMB1@,
|
||||
SD_INDEXING_TYPES_PART_@COMB2@,
|
||||
INSTANT_PROCESS_COMBINATION,
|
||||
functions::indexreduce::IndexReduce,
|
||||
::executeIndexReduce(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
const int opNum,
|
||||
void const* dx,
|
||||
sd::LongType const* xShapeInfo,
|
||||
sd::LongType xRank,
|
||||
void* extraParams,
|
||||
void* result,
|
||||
sd::LongType const* zShapeInfo,
|
||||
sd::LongType zRank,
|
||||
sd::LongType* dimension,
|
||||
sd::LongType dimensionLength,
|
||||
int postProcessOrNot,
|
||||
sd::LongType* allocationBuffer,
|
||||
void* reductionBuffer,
|
||||
sd::LongType const* tadOnlyShapeInfo,
|
||||
sd::LongType const* tadOffsets);
|
||||
);
|
||||
|
||||
ITERATE_COMBINATIONS(
|
||||
SD_COMMON_TYPES_PART_@COMB1@,
|
||||
SD_INDEXING_TYPES_PART_@COMB2@,
|
||||
INSTANT_PROCESS_COMBINATION,
|
||||
functions::indexreduce::IndexReduce,
|
||||
::executeIndexReduceScalar(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
const int opNum,
|
||||
void const* dx,
|
||||
sd::LongType const* xShapeInfo,
|
||||
sd::LongType xRank,
|
||||
void* extraParams,
|
||||
void* result,
|
||||
sd::LongType const* zShapeInfo,
|
||||
sd::LongType zRank,
|
||||
sd::LongType* dimension,
|
||||
sd::LongType dimensionLength,
|
||||
int postProcessOrNot,
|
||||
sd::LongType* allocationBuffer,
|
||||
void* reductionBuffer,
|
||||
sd::LongType const* tadOnlyShapeInfo,
|
||||
sd::LongType const* tadOffsets);
|
||||
);
|
||||
@@ -0,0 +1,50 @@
|
||||
/*
|
||||
* ******************************************************************************
|
||||
* *
|
||||
* *
|
||||
* * This program and the accompanying materials are made available under the
|
||||
* * terms of the Apache License, Version 2.0 which is available at
|
||||
* * https://www.apache.org/licenses/LICENSE-2.0.
|
||||
* *
|
||||
* * See the NOTICE file distributed with this work for additional
|
||||
* * information regarding copyright ownership.
|
||||
* * Unless required by applicable law or agreed to in writing, software
|
||||
* * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
* * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
* * License for the specific language governing permissions and limitations
|
||||
* * under the License.
|
||||
* *
|
||||
* * SPDX-License-Identifier: Apache-2.0
|
||||
* *****************************************************************************
|
||||
*/
|
||||
|
||||
//
|
||||
// Created by agibsonccc on 3/10/25.
|
||||
//
|
||||
|
||||
#include <loops/cuda/pairwise.chpp>
|
||||
#include <system/type_boilerplate.h>
|
||||
#include <loops/pairwise_instantiations_single.h>
|
||||
|
||||
/*
|
||||
* Function instantiation for PairWiseTransform::executeCudaShaped
|
||||
*/
|
||||
|
||||
ITERATE_COMBINATIONS_3(
|
||||
SD_SINGLE_TYPE_@COMB1@,
|
||||
SD_SINGLE_TYPE_@COMB2@,
|
||||
SD_SINGLE_TYPE_@COMB3@,
|
||||
INSTANT_PROCESS_COMBINATION_3,
|
||||
functions::pairwise_transforms::PairWiseTransform,
|
||||
::executeCudaShaped(
|
||||
dim3& launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
const void *vx,
|
||||
const sd::LongType *xShapeInfo,
|
||||
const void *vy,
|
||||
const sd::LongType *yShapeInfo,
|
||||
void *vz,
|
||||
const sd::LongType *zShapeInfo,
|
||||
void *vextraParams);
|
||||
);
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
/* ******************************************************************************
|
||||
*
|
||||
*
|
||||
* This program and the accompanying materials are made available under the
|
||||
* terms of the Apache License, Version 2.0 which is available at
|
||||
* https://www.apache.org/licenses/LICENSE-2.0.
|
||||
*
|
||||
* See the NOTICE file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
******************************************************************************/
|
||||
|
||||
//
|
||||
// Created by agibsonccc on 3/10/25.
|
||||
//
|
||||
|
||||
#include <loops/cuda/pairwise.chpp>
|
||||
#include <system/type_boilerplate.h>
|
||||
#include <loops/pairwise_instantiations_single.h>
|
||||
|
||||
/*
|
||||
* Function Instantiation:
|
||||
* PairWiseTransform::executeCudaShaped instantiated for types in @COMB1@, @COMB2@, @COMB3@
|
||||
*/
|
||||
|
||||
ITERATE_COMBINATIONS_3(
|
||||
SD_COMMON_TYPES_PART_@COMB1@,
|
||||
SD_COMMON_TYPES_PART_@COMB2@,
|
||||
SD_COMMON_TYPES_PART_@COMB3@,
|
||||
INSTANT_PROCESS_COMBINATION_3,
|
||||
functions::pairwise_transforms::PairWiseTransform,
|
||||
::executeCudaShaped(
|
||||
dim3& launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
const void *vx,
|
||||
const sd::LongType *xShapeInfo,
|
||||
const void *vy,
|
||||
const sd::LongType *yShapeInfo,
|
||||
void *vz,
|
||||
const sd::LongType *zShapeInfo,
|
||||
void *vextraParams);
|
||||
);
|
||||
+104
@@ -0,0 +1,104 @@
|
||||
/* ******************************************************************************
|
||||
*
|
||||
*
|
||||
* This program and the accompanying materials are made available under the
|
||||
* terms of the Apache License, Version 2.0 which is available at
|
||||
* https://www.apache.org/licenses/LICENSE-2.0.
|
||||
*
|
||||
* See the NOTICE file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
******************************************************************************/
|
||||
|
||||
//
|
||||
// Created by agibsonccc on 3/10/25.
|
||||
//
|
||||
|
||||
#include <loops/cuda/reduce3.chpp>
|
||||
#include <system/type_boilerplate.h>
|
||||
#include <loops/pairwise_instantiations_single.h>
|
||||
|
||||
/*
|
||||
* Function Instantiation:
|
||||
* Reduce3::exec instantiated for types in @COMB1@, @COMB2@
|
||||
* Note: Using @COMB1@ for X type and @COMB2@ for Z type (2-type combinations)
|
||||
*/
|
||||
|
||||
ITERATE_COMBINATIONS(
|
||||
SD_COMMON_TYPES_PART_@COMB1@,
|
||||
SD_FLOAT_TYPES_PART_@COMB2@,
|
||||
INSTANT_PROCESS_COMBINATION,
|
||||
functions::reduce3::Reduce3,
|
||||
::exec(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
void const* vx,
|
||||
sd::LongType const* xShapeInfo,
|
||||
void const* vy,
|
||||
sd::LongType const* yShapeInfo,
|
||||
void* extraParams,
|
||||
void* vz,
|
||||
sd::LongType const* zShapeInfo,
|
||||
sd::LongType* dimension,
|
||||
sd::LongType dimensionLength,
|
||||
int postProcessOrNot,
|
||||
sd::LongType* allocationPointer,
|
||||
sd::LongType const* tadOnlyShapeInfo,
|
||||
sd::LongType const* tadOffsets,
|
||||
sd::LongType const* yTadOnlyShapeInfo,
|
||||
sd::LongType const* yTadOffsets);
|
||||
);
|
||||
|
||||
ITERATE_COMBINATIONS(
|
||||
SD_COMMON_TYPES_PART_@COMB1@,
|
||||
SD_FLOAT_TYPES_PART_@COMB2@,
|
||||
INSTANT_PROCESS_COMBINATION,
|
||||
functions::reduce3::Reduce3,
|
||||
::execAll(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
void const* vx,
|
||||
sd::LongType const* xShapeInfo,
|
||||
void const* vy,
|
||||
sd::LongType const* yShapeInfo,
|
||||
void* extraParams,
|
||||
void* vz,
|
||||
sd::LongType const* zShapeInfo,
|
||||
sd::LongType* dimension,
|
||||
long long int dimensionLength,
|
||||
int postProcessOrNot,
|
||||
sd::LongType* allocationPointer,
|
||||
sd::LongType const* tadOnlyShapeInfo,
|
||||
sd::LongType const* tadOffsets,
|
||||
sd::LongType const* yTadOnlyShapeInfo,
|
||||
sd::LongType const* yTadOffsets);
|
||||
);
|
||||
|
||||
ITERATE_COMBINATIONS(
|
||||
SD_COMMON_TYPES_PART_@COMB1@,
|
||||
SD_FLOAT_TYPES_PART_@COMB2@,
|
||||
INSTANT_PROCESS_COMBINATION,
|
||||
functions::reduce3::Reduce3,
|
||||
::execScalar(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
void const* vx,
|
||||
sd::LongType const* xShapeInfo,
|
||||
void const* vy,
|
||||
sd::LongType const* yShapeInfo,
|
||||
void* extraParams,
|
||||
void* vz,
|
||||
sd::LongType const* zShapeInfo,
|
||||
sd::LongType* allocationPointer,
|
||||
void* reductionBuffer,
|
||||
sd::LongType const* tadOnlyShapeInfo);
|
||||
);
|
||||
+73
@@ -0,0 +1,73 @@
|
||||
/* ******************************************************************************
|
||||
*
|
||||
*
|
||||
* This program and the accompanying materials are made available under the
|
||||
* terms of the Apache License, Version 2.0 which is available at
|
||||
* https://www.apache.org/licenses/LICENSE-2.0.
|
||||
*
|
||||
* See the NOTICE file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
******************************************************************************/
|
||||
|
||||
//
|
||||
// Created by agibsonccc on 3/10/25.
|
||||
//
|
||||
|
||||
#include <loops/cuda/reduce/reduce_float.chpp>
|
||||
#include <system/type_boilerplate.h>
|
||||
#include <loops/pairwise_instantiations_single.h>
|
||||
|
||||
/*
|
||||
* Function Instantiation:
|
||||
* ReduceFloatFunction::execReduce instantiated for types in @COMB1@, @COMB2@
|
||||
* Note: Using @COMB1@ for X type and @COMB2@ for Z type (2-type combinations)
|
||||
*/
|
||||
|
||||
ITERATE_COMBINATIONS(
|
||||
SD_NUMERIC_TYPES_PART_@COMB1@,
|
||||
SD_FLOAT_TYPES_PART_@COMB2@,
|
||||
INSTANT_PROCESS_COMBINATION,
|
||||
functions::reduce::ReduceFloatFunction,
|
||||
::execReduce(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
const int opNum,
|
||||
const void* x,
|
||||
const sd::LongType* dXShapeInfo,
|
||||
const sd::LongType* hXShapeInfo,
|
||||
void* extraParams,
|
||||
void* vreductionBuffer,
|
||||
void* z,
|
||||
const sd::LongType* dZShapeInfo,
|
||||
const sd::LongType* hZShapeInfo,
|
||||
const sd::LongType* dims);
|
||||
);
|
||||
|
||||
ITERATE_COMBINATIONS(
|
||||
SD_NUMERIC_TYPES_PART_@COMB1@,
|
||||
SD_FLOAT_TYPES_PART_@COMB2@,
|
||||
INSTANT_PROCESS_COMBINATION,
|
||||
functions::reduce::ReduceFloatFunction,
|
||||
::execReduceScalar(
|
||||
dim3 launchDims,
|
||||
cudaStream_t* stream,
|
||||
const int opNum,
|
||||
const void* x,
|
||||
const sd::LongType* xShapeInfo,
|
||||
const sd::LongType* hXShapeInfo,
|
||||
void* extraParams,
|
||||
void* z,
|
||||
const sd::LongType* dZShapeInfo,
|
||||
const sd::LongType* hZShapeInfo,
|
||||
sd::LongType* dimension,
|
||||
long long int dimensionLength,
|
||||
void* reductionBuffer,
|
||||
const sd::LongType* tadOnlyShapeInfo);
|
||||
);
|
||||
+55
@@ -0,0 +1,55 @@
|
||||
/*
|
||||
* ******************************************************************************
|
||||
* *
|
||||
* *
|
||||
* * This program and the accompanying materials are made available under the
|
||||
* * terms of the Apache License, Version 2.0 which is available at
|
||||
* * https://www.apache.org/licenses/LICENSE-2.0.
|
||||
* *
|
||||
* * See the NOTICE file distributed with this work for additional
|
||||
* * information regarding copyright ownership.
|
||||
* * Unless required by applicable law or agreed to in writing, software
|
||||
* * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
* * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
* * License for the specific language governing permissions and limitations
|
||||
* * under the License.
|
||||
* *
|
||||
* * SPDX-License-Identifier: Apache-2.0
|
||||
* *****************************************************************************
|
||||
*/
|
||||
|
||||
//
|
||||
// Created by agibsonccc on 3/10/25.
|
||||
//
|
||||
|
||||
#include <loops/cuda/scalar.chpp>
|
||||
#include <system/type_boilerplate.h>
|
||||
#include <loops/pairwise_instantiations_single.h>
|
||||
|
||||
/*
|
||||
* Function instantiation for ScalarTransform::executeCudaAlongDimension
|
||||
*/
|
||||
|
||||
ITERATE_COMBINATIONS_3(
|
||||
SD_SINGLE_TYPE_@COMB1@,
|
||||
SD_SINGLE_TYPE_@COMB2@,
|
||||
SD_SINGLE_TYPE_@COMB3@,
|
||||
INSTANT_PROCESS_COMBINATION_3,
|
||||
functions::scalar::ScalarTransform,
|
||||
::executeCudaAlongDimension(
|
||||
dim3& launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
const void *vx,
|
||||
const sd::LongType *xShapeInfo,
|
||||
void *vz,
|
||||
const sd::LongType *zShapeInfo,
|
||||
const void *vscalars,
|
||||
void *vextraParams,
|
||||
sd::LongType *dimension,
|
||||
sd::LongType dimensionLength,
|
||||
const sd::LongType *tadShapeInfo,
|
||||
const sd::LongType *tadOffsets,
|
||||
const sd::LongType *tadShapeInfoZ,
|
||||
const sd::LongType *tadOffsetsZ);
|
||||
);
|
||||
@@ -0,0 +1,51 @@
|
||||
/*
|
||||
* ******************************************************************************
|
||||
* *
|
||||
* *
|
||||
* * This program and the accompanying materials are made available under the
|
||||
* * terms of the Apache License, Version 2.0 which is available at
|
||||
* * https://www.apache.org/licenses/LICENSE-2.0.
|
||||
* *
|
||||
* * See the NOTICE file distributed with this work for additional
|
||||
* * information regarding copyright ownership.
|
||||
* * Unless required by applicable law or agreed to in writing, software
|
||||
* * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
* * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
* * License for the specific language governing permissions and limitations
|
||||
* * under the License.
|
||||
* *
|
||||
* * SPDX-License-Identifier: Apache-2.0
|
||||
* *****************************************************************************
|
||||
*/
|
||||
|
||||
//
|
||||
// Created by agibsonccc on 3/10/25.
|
||||
//
|
||||
|
||||
#include <loops/cuda/scalar.chpp>
|
||||
#include <system/type_boilerplate.h>
|
||||
#include <loops/pairwise_instantiations_single.h>
|
||||
|
||||
/*
|
||||
* Function instantiation for ScalarTransform::executeCudaShaped
|
||||
*/
|
||||
|
||||
ITERATE_COMBINATIONS_3(
|
||||
SD_SINGLE_TYPE_@COMB1@,
|
||||
SD_SINGLE_TYPE_@COMB2@,
|
||||
SD_SINGLE_TYPE_@COMB3@,
|
||||
INSTANT_PROCESS_COMBINATION_3,
|
||||
functions::scalar::ScalarTransform,
|
||||
::executeCudaShaped(
|
||||
dim3& launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
const void *vx,
|
||||
const sd::LongType *xShapeInfo,
|
||||
const sd::LongType *hxShapeInfo,
|
||||
void *vz,
|
||||
const sd::LongType *zShapeInfo,
|
||||
const sd::LongType *hzShapeInfo,
|
||||
const void *vscalar,
|
||||
void *vextraParams);
|
||||
);
|
||||
+74
@@ -0,0 +1,74 @@
|
||||
/* ******************************************************************************
|
||||
*
|
||||
*
|
||||
* This program and the accompanying materials are made available under the
|
||||
* terms of the Apache License, Version 2.0 which is available at
|
||||
* https://www.apache.org/licenses/LICENSE-2.0.
|
||||
*
|
||||
* See the NOTICE file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
******************************************************************************/
|
||||
|
||||
//
|
||||
// Created by agibsonccc on 3/10/25.
|
||||
//
|
||||
|
||||
#include <loops/cuda/scalar.chpp>
|
||||
#include <system/type_boilerplate.h>
|
||||
#include <loops/pairwise_instantiations_single.h>
|
||||
|
||||
/*
|
||||
* Function Instantiation:
|
||||
* ScalarTransform::executeCudaShaped instantiated for types in @COMB1@, @COMB2@, @COMB3@
|
||||
*/
|
||||
|
||||
ITERATE_COMBINATIONS_3(
|
||||
SD_COMMON_TYPES_PART_@COMB1@,
|
||||
SD_COMMON_TYPES_PART_@COMB2@,
|
||||
SD_COMMON_TYPES_PART_@COMB3@,
|
||||
INSTANT_PROCESS_COMBINATION_3,
|
||||
functions::scalar::ScalarTransform,
|
||||
::executeCudaShaped(
|
||||
dim3& launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
const void *vx,
|
||||
const sd::LongType *xShapeInfo,
|
||||
const sd::LongType *hxShapeInfo,
|
||||
void *vz,
|
||||
const sd::LongType *zShapeInfo,
|
||||
const sd::LongType *hzShapeInfo,
|
||||
const void *vscalar,
|
||||
void *vextraParams);
|
||||
);
|
||||
|
||||
ITERATE_COMBINATIONS_3(
|
||||
SD_COMMON_TYPES_PART_@COMB1@,
|
||||
SD_COMMON_TYPES_PART_@COMB2@,
|
||||
SD_COMMON_TYPES_PART_@COMB3@,
|
||||
INSTANT_PROCESS_COMBINATION_3,
|
||||
functions::scalar::ScalarTransform,
|
||||
::executeCudaAlongDimension(
|
||||
dim3& launchDims,
|
||||
cudaStream_t* stream,
|
||||
int opNum,
|
||||
const void *vx,
|
||||
const sd::LongType *xShapeInfo,
|
||||
void *vz,
|
||||
const sd::LongType *zShapeInfo,
|
||||
const void *vscalars,
|
||||
void *vextraParams,
|
||||
sd::LongType *dimension,
|
||||
sd::LongType dimensionLength,
|
||||
const sd::LongType *tadShapeInfo,
|
||||
const sd::LongType *tadOffsets,
|
||||
const sd::LongType *tadShapeInfoZ,
|
||||
const sd::LongType *tadOffsetsZ);
|
||||
);
|
||||
Reference in New Issue
Block a user