Skip to content

Commit

Permalink
Remove more "simd" label (#36)
Browse files Browse the repository at this point in the history
Missed some previously
  • Loading branch information
LegNeato authored Nov 21, 2024
1 parent 0075eb5 commit ffdbca0
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,8 @@ pub mod tiling_2d {
use super::*;
use crate::backends::wgpu::MatrixMultiplier;

pub fn wgpu() -> MatrixMultiplier<variants::Tiling2dSimd> {
futures::executor::block_on(MatrixMultiplier::new(variants::Tiling2dSimd))
pub fn wgpu() -> MatrixMultiplier<variants::Tiling2d> {
futures::executor::block_on(MatrixMultiplier::new(variants::Tiling2d))
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,21 +154,21 @@ impl GridComputation for Tiling1dLoop {
}

/// GPU implementation of matrix multiplication with two-dimensional tiling.
pub struct Tiling2dSimd;
pub struct Tiling2d;

impl Display for Tiling2dSimd {
impl Display for Tiling2d {
fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result {
write!(f, "tiling_2d")
}
}

impl Gpu for Tiling2dSimd {
impl Gpu for Tiling2d {
fn compiled_shader(&self) -> &[u8] {
compiled_tiling_2d::SHADER_BINARY
}
}

impl GridComputation for Tiling2dSimd {
impl GridComputation for Tiling2d {
fn workgroup(&self) -> UVec3 {
UVec3::new(16, 16, 1)
}
Expand Down
2 changes: 1 addition & 1 deletion blog/2024-11-21-optimizing-matrix-mul/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ tile).

import { RustTiling2d } from './snippets/tiling_2d.tsx';

<RustTiling2dSimd />
<RustTiling2d />

Each thread now calculates a 4x4 grid of the output matrix and we see a slight
improvement over the last kernel.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from "react";
import Snippet from "@site/src/components/Snippet";
import RustKernelSource from "!!raw-loader!../code/crates/gpu/tiling_2d/src/lib.rs";

export const RustTiling2dSimd: React.FC = () => (
export const RustTiling2d: React.FC = () => (
<Snippet language="rust" className="text-xs" title="2D tiling kernel with Rust GPU">
{RustKernelSource}
</Snippet>
Expand Down

0 comments on commit ffdbca0

Please sign in to comment.