Skip to content

fix(test): resolve cxxopts option collision in dma_complex_dims#3028

Merged
fifield merged 4 commits intoXilinx:mainfrom
FIM43-Redeye:fix/dma-complex-dims-cxxopts
Apr 21, 2026
Merged

fix(test): resolve cxxopts option collision in dma_complex_dims#3028
fifield merged 4 commits intoXilinx:mainfrom
FIM43-Redeye:fix/dma-complex-dims-cxxopts

Conversation

@FIM43-Redeye
Copy link
Copy Markdown
Contributor

Summary

  • Fix two bugs introduced by the Boost-to-cxxopts migration (Use cxxopts instead of Boost #2234) that were
    both hiding behind a single XFAIL:
    1. Option name collision: test.cpp registered "k" which conflicts with
      test_utils.cpp's "kernel,k" -- both claim -k, causing
      option_already_exists at parse time. Renamed to "tile-k" (long-only).
    2. Double-dash syntax: the RUN line used --m, --K, --r, --s for
      single-char options. cxxopts rejects -- for single-char names (unlike
      Boost). Changed to -m, -K, -r, -s.
  • Remove XFAIL marker -- test now passes.

Closes #2470 (last remaining test in that issue).

Test plan

  • Compiled and ran on NPU1 hardware with Peano -- PASS
  • Verified argument parsing: --help shows correct options, no collision
  • Confirmed single-dash syntax parses correctly for all dimension args

The Boost-to-cxxopts migration (Xilinx#2234) introduced two bugs that hid
behind a single XFAIL:

1. Option name collision: test.cpp registered "k" as a cxxopts option,
   which conflicts with test_utils.cpp's "kernel,k" -- both claim the
   -k short option, causing option_already_exists at parse time. Renamed
   to "tile-k" (long-only) to avoid the collision.

2. Double-dash syntax: the RUN line used --m, --K, --r, --s for
   single-char options. cxxopts rejects double-dash for single-char
   names (unlike Boost). Changed to single-dash -m, -K, -r, -s.

Test verified on NPU1 hardware with Peano: PASS.

Closes Xilinx#2470 (last remaining test in that issue).

Generated using Claude Code.
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Fixes dma_complex_dims NPU/XRT test failures caused by cxxopts behavior differences after the Boost→cxxopts migration, and re-enables the test by removing its blanket XFAIL.

Changes:

  • Avoid -k short-option collision by renaming the test’s tile-dimension option from k to long-only tile-k.
  • Update the lit RUN line to use single-dash syntax for single-character options (-m, -K, -r, -s) as required by cxxopts.
  • Remove the # XFAIL: * marker now that the test passes.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
test/npu-xrt/dma_complex_dims/test.cpp Renames the k CLI option to tile-k and updates parsing to match.
test/npu-xrt/dma_complex_dims/aie2.py Removes XFAIL and fixes RUN-line option syntax / updated tile-k flag usage.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread test/npu-xrt/dma_complex_dims/test.cpp Outdated
FIM43-Redeye and others added 3 commits April 10, 2026 22:57
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
The previous commit disabled xchesscc for kernel compilation but
forgot --no-xbridge, so the linking step still went through
xchesscc_wrapper. This caused a segfault on CI's older aietools
(v2024.2) during xbridge linking. Other Peano-only tests already
pass both flags together.

Generated using Claude Code.
@FIM43-Redeye
Copy link
Copy Markdown
Contributor Author

CI still seems green so far, is this ready to merge?

@fifield fifield added this pull request to the merge queue Apr 21, 2026
Merged via the queue into Xilinx:main with commit 8f987e6 Apr 21, 2026
71 checks passed
joeldushouyu pushed a commit to joeldushouyu/mlir-aie that referenced this pull request Apr 24, 2026
…nx#3028)

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
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.

Fix failing npu-xrt tests

4 participants