Skip to content

Commit

Permalink
[mux] Remove degenerate subgroup support.
Browse files Browse the repository at this point in the history
Older versions of oneAPI Construction Kit used an implementation of
subgroups where the subgroup size was always equal to the workgroup
size. This implementation is no longer used by any targets, but the code
to support it was still in place. This commit removes it.
  • Loading branch information
hvdijk committed Jan 16, 2025
1 parent 47df6fd commit a68190f
Show file tree
Hide file tree
Showing 39 changed files with 120 additions and 1,487 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# ComputeAorta Changes

## TBD

Upgrade guidance:

* Support for degenerate subgroups has been removed. No in-tree target or
template was using this, but custom targets may need to be updated.

## Version 4.0.0

Upgrade guidance:
Expand Down
5 changes: 5 additions & 0 deletions doc/modules/mux/changes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,11 @@ version increases mean backward compatible bug fixes have been applied.
Versions prior to 1.0.0 may contain breaking changes in minor
versions as the API is still under development.

0.81.0
------

* Removed ``mux-degenerate-subgroups``.

0.80.0
------

Expand Down
5 changes: 1 addition & 4 deletions doc/specifications/mux-compiler-spec.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
ComputeMux Compiler Specification
=================================

This is version 0.80.0 of the specification.
This is version 0.81.0 of the specification.

ComputeMux is Codeplay’s proprietary API for executing compute workloads across
heterogeneous devices. ComputeMux is an extremely lightweight,
Expand Down Expand Up @@ -1432,9 +1432,6 @@ different stages of the pipeline:
by the use of known mux sub-group builtins). If a pass introduces the
explicit use of sub-groups to a function, it should remove this
attribute.
* - ``"mux-degenerate-subgroups"``
- Marks the function has using degenerate sub-groups (i.e. one sub-group
for the entire local work-group).

``mux-kernel`` attribute
~~~~~~~~~~~~~~~~~~~~~~~~
Expand Down
2 changes: 1 addition & 1 deletion doc/specifications/mux-runtime-spec.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
ComputeMux Runtime Specification
================================

This is version 0.80.0 of the specification.
This is version 0.81.0 of the specification.

ComputeMux is Codeplay’s proprietary API for executing compute workloads across
heterogeneous devices. ComputeMux is an extremely lightweight,
Expand Down
2 changes: 0 additions & 2 deletions modules/compiler/compiler_pipeline/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ add_ca_library(compiler-pipeline STATIC
${CMAKE_CURRENT_SOURCE_DIR}/include/compiler/utils/compute_local_memory_usage_pass.h
${CMAKE_CURRENT_SOURCE_DIR}/include/compiler/utils/define_mux_builtins_pass.h
${CMAKE_CURRENT_SOURCE_DIR}/include/compiler/utils/define_mux_dma_pass.h
${CMAKE_CURRENT_SOURCE_DIR}/include/compiler/utils/degenerate_sub_group_pass.h
${CMAKE_CURRENT_SOURCE_DIR}/include/compiler/utils/device_info.h
${CMAKE_CURRENT_SOURCE_DIR}/include/compiler/utils/dma.h
${CMAKE_CURRENT_SOURCE_DIR}/include/compiler/utils/encode_builtin_range_metadata_pass.h
Expand Down Expand Up @@ -79,7 +78,6 @@ add_ca_library(compiler-pipeline STATIC
${CMAKE_CURRENT_SOURCE_DIR}/source/compute_local_memory_usage_pass.cpp
${CMAKE_CURRENT_SOURCE_DIR}/source/define_mux_builtins_pass.cpp
${CMAKE_CURRENT_SOURCE_DIR}/source/define_mux_dma_pass.cpp
${CMAKE_CURRENT_SOURCE_DIR}/source/degenerate_sub_group_pass.cpp
${CMAKE_CURRENT_SOURCE_DIR}/source/dma.cpp
${CMAKE_CURRENT_SOURCE_DIR}/source/encode_builtin_range_metadata_pass.cpp
${CMAKE_CURRENT_SOURCE_DIR}/source/encode_kernel_metadata_pass.cpp
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -162,16 +162,6 @@ void setBarrierSchedule(llvm::CallInst &CI, BarrierSchedule Sched);
/// @return the execution schedule for this barrier
BarrierSchedule getBarrierSchedule(const llvm::CallInst &CI);

/// @brief Marks a kernel's subgroups as degenerate
///
/// @param[in] F Function in which to encode the information.
void setHasDegenerateSubgroups(llvm::Function &F);

/// @brief Returns whether the kernel has degenerate subgroups.
///
/// @param[in] F Function to check.
bool hasDegenerateSubgroups(const llvm::Function &F);

/// @brief Marks a function as not explicitly using subgroups
///
/// May be set even with unresolved external functions, assuming those don't
Expand Down

This file was deleted.

12 changes: 0 additions & 12 deletions modules/compiler/compiler_pipeline/source/attributes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -186,18 +186,6 @@ BarrierSchedule getBarrierSchedule(const CallInst &CI) {
return BarrierSchedule::Unordered;
}

static constexpr const char *MuxDegenerateSubgroupsAttrName =
"mux-degenerate-subgroups";

void setHasDegenerateSubgroups(Function &F) {
F.addFnAttr(MuxDegenerateSubgroupsAttrName);
}

bool hasDegenerateSubgroups(const Function &F) {
const Attribute Attr = F.getFnAttribute(MuxDegenerateSubgroupsAttrName);
return Attr.isValid();
}

static constexpr const char *MuxNoSubgroupsAttrName = "mux-no-subgroups";

void setHasNoExplicitSubgroups(Function &F) {
Expand Down
Loading

0 comments on commit a68190f

Please sign in to comment.