Skip to content

Commit

Permalink
use iree's path escaping
Browse files Browse the repository at this point in the history
  • Loading branch information
makslevental committed Aug 19, 2024
1 parent d9682fc commit b5bc33d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 14 deletions.
1 change: 0 additions & 1 deletion cmake/iree_aie_rt.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ iree_install_targets(
# aie-rt
# ##############################################################################

#set(common_DIR ${CMAKE_CURRENT_LIST_DIR})
set(_aie_rt_source_dir ${IREE_AMD_AIE_SOURCE_DIR}/third_party/aie-rt)
set(_AIE_RT_BINARY_INCLUDE_DIR ${CMAKE_CURRENT_BINARY_DIR}/iree_aie_runtime/include)

Expand Down
18 changes: 5 additions & 13 deletions compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/Passes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@

#include "iree-amd-aie/Transforms/Passes.h"

#include <filesystem>
#include <iomanip>

#include "aie/Passes.h"
#include "aievec/Passes.h"
#include "air/Conversion/Passes.h"
Expand All @@ -17,6 +14,7 @@
#include "iree-dialects/Dialect/LinalgTransform/Passes.h"
#include "iree/compiler/Codegen/Common/Passes.h"
#include "iree/compiler/Utils/PassUtils.h"
#include "iree/compiler/Utils/ToolUtils.h"
#include "mlir/Conversion/AffineToStandard/AffineToStandard.h"
#include "mlir/Conversion/ArithToLLVM/ArithToLLVM.h"
#include "mlir/Conversion/ControlFlowToLLVM/ControlFlowToLLVM.h"
Expand Down Expand Up @@ -308,11 +306,8 @@ void addPackPeelBasedPassPipeline(OpPassManager &funcPassManager,
// Lower to UKernels.
{
AMDAIELowerToUKernelsOptions options;
std::filesystem::path pathToUkernels = clPathToUkernels.getValue();
// quote for windows paths like `C:/Program Files`
std::stringstream ss;
ss << pathToUkernels.make_preferred();
ss >> std::quoted(options.pathToUkernels);
// windows
options.pathToUkernels = escapeCommandLineComponent(clPathToUkernels);
funcPassManager.addPass(createAMDAIELowerToUKernelsPass(options));
}

Expand Down Expand Up @@ -419,11 +414,8 @@ void addPadPackBasedPassPipeline(OpPassManager &funcPassManager,
// Lower to UKernels
{
AMDAIELowerToUKernelsOptions options;
std::filesystem::path pathToUkernels = clPathToUkernels.getValue();
// quote for windows paths like `C:/Program Files`
std::stringstream ss;
ss << pathToUkernels.make_preferred();
ss >> std::quoted(options.pathToUkernels);
// windows
options.pathToUkernels = escapeCommandLineComponent(clPathToUkernels);
funcPassManager.addPass(createAMDAIELowerToUKernelsPass(options));
}
// Vectorization passes
Expand Down

0 comments on commit b5bc33d

Please sign in to comment.