-
Notifications
You must be signed in to change notification settings - Fork 60
The proposed fix for the part number extraction logic from platforminfo
#73
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
base: master
Are you sure you want to change the base?
Conversation
…fo utility output on AWS F1 (Ubuntu AMI/2024.1). The proposed logic is to skip the extraction step if `PROGRAM_PLATFORM_PART` is defined beforehand. For example: `set(PROGRAM_PLATFORM_PART "xcvu9p-flga2104-2-e" CACHE INTERNAL "F1 part number")`
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you give this a try using a non-F1 platform as well? 🙂
@@ -476,7 +476,7 @@ function(add_vitis_program | |||
set(PROGRAM_DEPENDS ${PROGRAM_DEPENDS} ${_PROGRAM_DEPENDS}) | |||
|
|||
# Recover the part name used by the given platform | |||
if(NOT PROGRAM_PLATFORM_PART OR NOT "${${PROGRAM_TARGET}_PLATFORM}" STREQUAL "${PROGRAM_PLATFORM}") | |||
if(((NOT DEFINED PROGRAM_PLATFORM_PART) OR (NOT PROGRAM_PLATFORM_PART)) AND (NOT "${${PROGRAM_TARGET}_PLATFORM}" STREQUAL "${PROGRAM_PLATFORM}")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the DEFINED
necessary? I thought both undefined and empty would fail the plain check.
IIUC this is effectively turning the OR
into an AND
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Exactly. I agree.
The only difference of NOT DEFINED VAR
and NOT VAR
is when VAR
is defined, but as an empty string. OR
ing them will be identical to NOT VAR
.
@@ -485,6 +485,7 @@ function(add_vitis_program | |||
set(PROGRAM_PLATFORM_PART ${PLATFORM_PART} CACHE INTERNAL "") | |||
endif() | |||
endif() | |||
message(STATUS "Deduced PROGRAM_PLATFORM_PART: ${PROGRAM_PLATFORM_PART}") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we should print the internal CMake variable name
Unfortunately, at the moment I only have access to the aws f1 instances.
I need a day or two to test it on F1 to make sure it doesn't break other
stuff.
…On Fri, 21 Mar 2025, 17:19 Johannes de Fine Licht, ***@***.***> wrote:
***@***.**** commented on this pull request.
Did you give this a try using a non-F1 platform as well? 🙂
------------------------------
In cmake/FindVitis.cmake
<#73 (comment)>:
> @@ -476,7 +476,7 @@ function(add_vitis_program
set(PROGRAM_DEPENDS ${PROGRAM_DEPENDS} ${_PROGRAM_DEPENDS})
# Recover the part name used by the given platform
- if(NOT PROGRAM_PLATFORM_PART OR NOT "${${PROGRAM_TARGET}_PLATFORM}" STREQUAL "${PROGRAM_PLATFORM}")
+ if(((NOT DEFINED PROGRAM_PLATFORM_PART) OR (NOT PROGRAM_PLATFORM_PART)) AND (NOT "${${PROGRAM_TARGET}_PLATFORM}" STREQUAL "${PROGRAM_PLATFORM}"))
Is the DEFINED necessary? I thought both undefined and empty would fail
the plain check.
IIUC this is effectively turning the OR into an AND?
------------------------------
In cmake/FindVitis.cmake
<#73 (comment)>:
> @@ -485,6 +485,7 @@ function(add_vitis_program
set(PROGRAM_PLATFORM_PART ${PLATFORM_PART} CACHE INTERNAL "")
endif()
endif()
+ message(STATUS "Deduced PROGRAM_PLATFORM_PART: ${PROGRAM_PLATFORM_PART}")
I don't think we should print the internal CMake variable name
—
Reply to this email directly, view it on GitHub
<#73 (review)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AB5T7A6I4PABVQHTICKJC3T2VQ3ZJAVCNFSM6AAAAABZP2V6SSVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMZDOMBWGUZDEMBZHA>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
No worries! To be honest with I haven't had (easy) access to FPGA development platform tools for years now, so it's not quick for me to test either. I wonder if @derpda is still active? |
Ohh a little blast from the past! |
Today, I ran |
The proposed fix for the part number extraction logic from
platforminfo
utility output on AWS F1 (Ubuntu AMI/2024.1).The proposed logic is to skip the extraction step if
PROGRAM_PLATFORM_PART
is defined beforehand. For example:set(PROGRAM_PLATFORM_PART "xcvu9p-flga2104-2-e" CACHE INTERNAL "F1 part number")
To confirm that this does not break anything else that depends on the part number variable:
My information is a bit rusty (I used to work with SDAccel 2019.1 and many things have been changed/depreciated).
Also, see #72 for more details on the problem.