Skip to content

Add testing infra for reduction kernel #1344

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

Sameeranjoshi
Copy link
Contributor

No description provided.

…enerates vector.extract + vector.add + vector.insert, need vector.transfer_Write instead.
This is partial fix, the program fails for out of Program memory on a core.
1. solves the reduction legalizer issue.
2. Converts the transfer_reads into loads
3. Applies 2D->1D flattening pattern on vector type.
4. Solves stack size problem by bumping the stack size.
1. Selected appropriate tile sizes.
   Peano vectorizes for <32xbf16> we choose the tile sizes such that we always
   generate the legal shapes.
2. found the bounds for both bf16 and f32 which work.
3. Tested the patch and cleaned up the patterns.
F32
 Correctness: Pass
 Benchmark: Fails PM issue(run_benchmarks=true)

BF16:
 Correctness: Fails
 Benchmarks: Pass(but this might be not correct as results are wrong)

Run commands:
python run.py delete_out_reduction $IREE_DIR --xrt_dir=$XRT_DIR --peano_dir=$PEANO_DIR \
--target_device="npu4" --xrt_lite_n_core_rows=$XRT_LITE_N_CORE_ROWS \
--xrt_lite_n_core_cols=$XRT_LITE_N_CORE_COLS --tests Reduction
@Sameeranjoshi Sameeranjoshi force-pushed the sam-testing-profiling branch from cb18aa8 to b0035f8 Compare August 4, 2025 05:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant