Skip to content
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

Vck5000 IRON Support #1140

Closed
wants to merge 29 commits into from
Closed

Conversation

eddierichter-amd
Copy link
Collaborator

Adding dynamic data movement support from IRON examples to VCK5000 AIE1

github-actions[bot]

This comment was marked as outdated.

github-actions[bot]

This comment was marked as outdated.

github-actions[bot]

This comment was marked as outdated.

reference_designs/IRON-examples/matrix_add_one/aie2.py Outdated Show resolved Hide resolved
reference_designs/IRON-examples/matrix_add_one/aie2.py Outdated Show resolved Hide resolved
reference_designs/ipu-xrt/vector_max/aie2.py Outdated Show resolved Hide resolved
reference_designs/ipu-xrt/vector_min/aie2.py Outdated Show resolved Hide resolved
reference_designs/ipu-xrt/vector_sum/aie2.py Outdated Show resolved Hide resolved
reference_designs/lit.cfg.py Outdated Show resolved Hide resolved
reference_designs/lit.cfg.py Outdated Show resolved Hide resolved
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit

clang-format

runtime_lib/test_lib/test_library.cpp|229|
runtime_lib/test_lib/test_library.h|23|
runtime_lib/test_lib/test_library.h|25|
runtime_lib/test_lib/test_library.h|129|

reference_designs/dynamic_dma_config_add_one/test.cpp Outdated Show resolved Hide resolved
reference_designs/dynamic_dma_config_add_one/test.cpp Outdated Show resolved Hide resolved
reference_designs/dynamic_dma_config_add_one/test.cpp Outdated Show resolved Hide resolved
reference_designs/ipu-xrt/vector_sum/test.cpp Outdated Show resolved Hide resolved
runtime_lib/test_lib/test_library.cpp Outdated Show resolved Hide resolved
runtime_lib/test_lib/test_library.cpp Outdated Show resolved Hide resolved
runtime_lib/test_lib/test_library.cpp Outdated Show resolved Hide resolved
runtime_lib/test_lib/test_library.cpp Outdated Show resolved Hide resolved
reference_designs/IRON-examples/matrix_add_one/aie2.py Outdated Show resolved Hide resolved
reference_designs/IRON-examples/vector_add/aie2.py Outdated Show resolved Hide resolved
reference_designs/IRON-examples/vector_max/aie2.py Outdated Show resolved Hide resolved
reference_designs/IRON-examples/vector_min/aie2.py Outdated Show resolved Hide resolved
reference_designs/IRON-examples/vector_mult/aie2.py Outdated Show resolved Hide resolved
reference_designs/IRON-examples/vector_scalar/aie2.py Outdated Show resolved Hide resolved
reference_designs/IRON-examples/vector_sum/aie2.py Outdated Show resolved Hide resolved
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit

clang-format

reference_designs/IRON-examples/vector_max/test_vck5000.cpp|119|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|124|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|126|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|128|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|133|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|22|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|24 col 1|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|25|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|27 col 1|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|57|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|90|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|100|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|106|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|117|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|122|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|129|
reference_designs/IRON-examples/vector_mult/test_vck5000.cpp|22|
reference_designs/IRON-examples/vector_mult/test_vck5000.cpp|24 col 1|
reference_designs/IRON-examples/vector_mult/test_vck5000.cpp|25|
reference_designs/IRON-examples/vector_mult/test_vck5000.cpp|27 col 1|
reference_designs/IRON-examples/vector_mult/test_vck5000.cpp|57|
reference_designs/IRON-examples/vector_mult/test_vck5000.cpp|126|
reference_designs/IRON-examples/vector_scalar/test_vck5000.cpp|22|
reference_designs/IRON-examples/vector_scalar/test_vck5000.cpp|24 col 1|
reference_designs/IRON-examples/vector_scalar/test_vck5000.cpp|25|
reference_designs/IRON-examples/vector_scalar/test_vck5000.cpp|27 col 1|
reference_designs/IRON-examples/vector_scalar/test_vck5000.cpp|57|
reference_designs/IRON-examples/vector_scalar/test_vck5000.cpp|124|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|22|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|24 col 1|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|25|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|27 col 1|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|57|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|90|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|100|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|116|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|118|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|123|
runtime_lib/test_lib/test_library.cpp|229|
runtime_lib/test_lib/test_library.h|23|
runtime_lib/test_lib/test_library.h|25|
runtime_lib/test_lib/test_library.h|129|

reference_designs/IRON-examples/vector_add/test.cpp Outdated Show resolved Hide resolved
runtime_lib/test_lib/test_library.cpp Outdated Show resolved Hide resolved
runtime_lib/test_lib/test_library.h Outdated Show resolved Hide resolved
runtime_lib/test_lib/test_library.h Outdated Show resolved Hide resolved
runtime_lib/test_lib/test_library.h Outdated Show resolved Hide resolved
Copy link
Contributor

github-actions bot commented Mar 20, 2024

Coverage Report

Created: 2024-03-22 19:51

Click here for information about interpreting this report.

FilenameFunction CoverageLine CoverageRegion CoverageBranch Coverage
Totals- - - -
Generated by llvm-cov -- llvm version 14.0.0

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit

clang-format

reference_designs/IRON-examples/matrix_add_one/test_vck5000.cpp|145|
reference_designs/IRON-examples/matrix_multiplication_scalar/test.cpp|22|
reference_designs/IRON-examples/matrix_multiplication_scalar/test.cpp|25|
reference_designs/IRON-examples/matrix_multiplication_scalar/test.cpp|68|
reference_designs/IRON-examples/matrix_multiplication_scalar/test.cpp|127|
reference_designs/IRON-examples/matrix_multiplication_scalar/test.cpp|131|
reference_designs/IRON-examples/matrix_multiplication_scalar/test.cpp|135|
reference_designs/IRON-examples/matrix_multiplication_scalar/test.cpp|145|
reference_designs/IRON-examples/passthrough_hardware/test_vck5000.cpp|22|
reference_designs/IRON-examples/passthrough_hardware/test_vck5000.cpp|25|
reference_designs/IRON-examples/passthrough_hardware/test_vck5000.cpp|57|
reference_designs/IRON-examples/passthrough_hardware/test_vck5000.cpp|122|
reference_designs/IRON-examples/vector_add/test.cpp|178|
reference_designs/IRON-examples/vector_add/test.cpp|183|
reference_designs/IRON-examples/vector_add/test_vck5000.cpp|22|
reference_designs/IRON-examples/vector_add/test_vck5000.cpp|25|
reference_designs/IRON-examples/vector_add/test_vck5000.cpp|57|
reference_designs/IRON-examples/vector_add/test_vck5000.cpp|126|
reference_designs/IRON-examples/vector_max/test.cpp|154|
reference_designs/IRON-examples/vector_max/test.cpp|173|
reference_designs/IRON-examples/vector_max/test.cpp|181|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|22|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|25|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|57|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|90|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|100|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|106|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|109|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|119|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|124|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|126|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|128|
reference_designs/IRON-examples/vector_max/test_vck5000.cpp|133|
reference_designs/IRON-examples/vector_min/test.cpp|154|
reference_designs/IRON-examples/vector_min/test.cpp|173|
reference_designs/IRON-examples/vector_min/test.cpp|181|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|22|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|25|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|57|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|90|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|100|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|106|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|117|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|122|
reference_designs/IRON-examples/vector_min/test_vck5000.cpp|129|
reference_designs/IRON-examples/vector_mult/test.cpp|179|
reference_designs/IRON-examples/vector_mult/test.cpp|184|
reference_designs/IRON-examples/vector_mult/test_vck5000.cpp|22|
reference_designs/IRON-examples/vector_mult/test_vck5000.cpp|25|
reference_designs/IRON-examples/vector_mult/test_vck5000.cpp|57|
reference_designs/IRON-examples/vector_mult/test_vck5000.cpp|126|
reference_designs/IRON-examples/vector_scalar/test_vck5000.cpp|22|
reference_designs/IRON-examples/vector_scalar/test_vck5000.cpp|25|
reference_designs/IRON-examples/vector_scalar/test_vck5000.cpp|57|
reference_designs/IRON-examples/vector_scalar/test_vck5000.cpp|124|
reference_designs/IRON-examples/vector_scalar_kernel/scale.cc|11|
reference_designs/IRON-examples/vector_scalar_kernel/test.cpp|22|
reference_designs/IRON-examples/vector_scalar_kernel/test.cpp|25|
reference_designs/IRON-examples/vector_scalar_kernel/test.cpp|57|
reference_designs/IRON-examples/vector_scalar_kernel/test.cpp|124|
reference_designs/IRON-examples/vector_sum/test.cpp|154|
reference_designs/IRON-examples/vector_sum/test.cpp|173|
reference_designs/IRON-examples/vector_sum/test.cpp|179|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|22|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|25|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|57|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|90|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|100|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|116|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|118|
reference_designs/IRON-examples/vector_sum/test_vck5000.cpp|123|
reference_designs/dynamic_dma_config_add_one/test.cpp|21|
reference_designs/dynamic_dma_config_add_one/test.cpp|55|
reference_designs/dynamic_dma_config_add_one/test.cpp|154|
reference_designs/dynamic_dma_config_add_one/test.cpp|164|
reference_designs/dynamic_dma_config_add_one_kernel/test.cpp|21|
reference_designs/dynamic_dma_config_add_one_kernel/test.cpp|55|
reference_designs/dynamic_dma_config_add_one_kernel/test.cpp|154|
reference_designs/dynamic_dma_config_add_one_kernel/test.cpp|164|
reference_designs/dynamic_dma_config_add_one_kernel_obj_fifo/test.cpp|21|
reference_designs/dynamic_dma_config_add_one_kernel_obj_fifo/test.cpp|24|
reference_designs/dynamic_dma_config_add_one_kernel_obj_fifo/test.cpp|56|
reference_designs/dynamic_dma_config_add_one_kernel_obj_fifo/test.cpp|117|
reference_designs/ipu-xrt/matrix_add_one/test.cpp|182|
reference_designs/ipu-xrt/matrix_add_one/test.cpp|186|
reference_designs/ipu-xrt/matrix_add_one/test.cpp|190|
reference_designs/ipu-xrt/vector_max/test.cpp|154|
reference_designs/ipu-xrt/vector_max/test.cpp|173|
reference_designs/ipu-xrt/vector_max/test.cpp|181|
reference_designs/ipu-xrt/vector_min/test.cpp|154|
reference_designs/ipu-xrt/vector_min/test.cpp|173|
reference_designs/ipu-xrt/vector_min/test.cpp|181|
reference_designs/ipu-xrt/vector_sum/test.cpp|154|
reference_designs/ipu-xrt/vector_sum/test.cpp|173|
reference_designs/ipu-xrt/vector_sum/test.cpp|179|
runtime_lib/test_lib/test_library.cpp|29|
runtime_lib/test_lib/test_library.cpp|40|
runtime_lib/test_lib/test_library.cpp|109|
runtime_lib/test_lib/test_library.cpp|140|
runtime_lib/test_lib/test_library.cpp|229|
runtime_lib/test_lib/test_library.h|23|
runtime_lib/test_lib/test_library.h|25|

include/aie/Targets/AIETargets.h Outdated Show resolved Hide resolved
lib/Targets/AIETargetHSA.cpp Outdated Show resolved Hide resolved
lib/Targets/AIETargetHSA.cpp Outdated Show resolved Hide resolved
lib/Targets/AIETargetHSA.cpp Outdated Show resolved Hide resolved
lib/Targets/AIETargetHSA.cpp Outdated Show resolved Hide resolved
reference_designs/lit.cfg.py Outdated Show resolved Hide resolved
reference_designs/lit.cfg.py Outdated Show resolved Hide resolved
reference_designs/lit.cfg.py Outdated Show resolved Hide resolved
reference_designs/lit.cfg.py Outdated Show resolved Hide resolved
test/lit.cfg.py Outdated Show resolved Hide resolved
test/lit.cfg.py Outdated Show resolved Hide resolved
test/lit.cfg.py Outdated Show resolved Hide resolved
test/lit.cfg.py Outdated Show resolved Hide resolved
@@ -74,13 +74,18 @@ mlir::LogicalResult AIETranslateToHSA(ModuleOp module, raw_ostream &output) {
}

// Getting the sequence function op which contains the instructions
mlir::func::FuncOp funcOp;
mlir::func::FuncOp funcOp = NULL;
Copy link
Member

Choose a reason for hiding this comment

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

No NULL in C++ since 2011. Use nullptr instead.

@@ -0,0 +1,10 @@
// (c) Copyright 2023 Advanced Micro Devices, Inc.
Copy link
Member

Choose a reason for hiding this comment

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

Happy new years everywhere?

config.unsupported = []

if not config.has_libxaie:
config.unsupported = ['IRON-examples']
Copy link
Member

Choose a reason for hiding this comment

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

Perhaps it is a good opportunity to introduce some new variables here so instead of copy-pasting
%python aiecc.py %VitisSysrootFlag% --host-target=%aieHostTargetTriplet% %link_against_hsa% ./aie.mlir -I%host_runtime_lib%/test_lib/include %extraAieCcFlags% %S/test_vck5000.cpp -o test.elf -L%host_runtime_lib%/test_lib/lib -ltest_lib
all over the place we can just have
%aiecc %iron_test
or something like that?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Good idea! We do need to add some logic of course to differentiate between the IPU and VCK5000 build instructions, but can encode that in %iron_test. I don't know if I want to put it in this PR as it is already incorporating a bunch of changes but if you want to take that in a separate branch that would be great :)

Copy link
Member

Choose a reason for hiding this comment

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

No emergency.
At least we could start thinking about how many different classes of tests we have first.

@eddierichter-amd eddierichter-amd force-pushed the vck5000-dynamic-dma-config branch 2 times, most recently from 3612a28 to 50fac6c Compare March 21, 2024 21:33
reference_designs/lit.cfg.py Outdated Show resolved Hide resolved
test/lit.cfg.py Outdated Show resolved Hide resolved
eddierichter-amd and others added 10 commits March 22, 2024 13:47
* Adding comments to build-mlir-aie.sh on how to point to the ROCm runtime
* Updating documentation to build on VCK5000 and adding script to allow users to clone the ROCm-air-platforms repository
* Updating build-mlir-aie that builds against the ROCm runtime as a new script, and updating the documentation to refer to the new script
* Updating documentation on new way to build aie-rt that works with both Phoenix and VCK5000
@eddierichter-amd eddierichter-amd marked this pull request as ready for review March 22, 2024 20:27
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.

3 participants