Skip to content

perf(filters): Vector128 islow IDCT #474

Closed

Description

@michaelstonis

Vectorize the integer (islow) IDCT, columns and rows four at a time in int lanes, checked against djpeg -dct int. Profile the IDCT's share of DCT decode time first; the research could not verify it.

Blocked by #470 (test and benchmark infrastructure).

Background: docs/research/simd.md (PR #469), section "Proposed follow-up issues".

Rules for every SIMD kernel

  • Internal Vector128<T> only, with the scalar path kept as the fallback. No Vector256/Vector512 or platform intrinsics unless a benchmark shows a need (Mono on the MAUI targets never accelerates Vector256, and AdvSimd needs LLVM, iOS Release only).
  • Bit-exact with the scalar path: an exhaustive (or near-exhaustive) equality test, and the same tests run with DOTNET_EnableHWIntrinsic=0.
  • No allocations; a BenchmarkDotNet case with [MemoryDiagnoser] showing before/after.
  • Measure in both browser builds (the WebAssembly interpreter maps only part of the Vector128 API and can be slower than scalar; the AOT build emits native Wasm SIMD). Do not ship a kernel that regresses the interpreter build.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area:filtersenhancement

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions