Skip to content

Commit

Permalink
add new action mask to indicate the driver to program the PDI.
Browse files Browse the repository at this point in the history
Signed-off-by: xvijaysri <[email protected]>
  • Loading branch information
xvijaysri committed Aug 15, 2024
1 parent 7d95295 commit 25e81f2
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/runtime_src/core/include/xclbin.h
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,7 @@ extern "C" {

enum ACTION_MASK {
AM_LOAD_AIE = 0x1 /* Indicates to the driver to load the AIE PID section */
AM_LOAD_PDI = 0x2 /* Indicates to the driver to program the PDI */
};

struct axlf_section_header {
Expand Down
3 changes: 2 additions & 1 deletion src/runtime_src/tools/xclbinutil/FormattedOutput.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,8 @@ reportXclbinInfo(std::ostream& _ostream,
_ostream << boost::format(" %-23s ") % "Action Mask(s):";
if (_xclBinHeader.m_header.m_actionMask & AM_LOAD_AIE)
_ostream << "LOAD_AIE ";

if (_xclBinHeader.m_header.m_actionMask & AM_LOAD_PDI)
_ostream << "LOAD_PDI ";
_ostream << std::endl;
}
}
Expand Down
6 changes: 5 additions & 1 deletion src/runtime_src/tools/xclbinutil/XclBinClass.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -1554,7 +1554,11 @@ XclBin::setKeyValue(const std::string& _keyValue)
for (const auto& mask : masks) {
if (mask == "LOAD_AIE") {
m_xclBinHeader.m_header.m_actionMask |= AM_LOAD_AIE;
} else {
}
else if (mask == "LOAD_PDI") {
m_xclBinHeader.m_header.m_actionMask |= AM_LOAD_PDI;
}
else {
auto errMsg = boost::format("ERROR: Unknown bit mask '%s' for the key '%s'. Key-value pair: '%s'.") % mask % sKey % _keyValue;
throw std::runtime_error(errMsg.str());
}
Expand Down

0 comments on commit 25e81f2

Please sign in to comment.