set(LLVM_LINK_COMPONENTS
  Support
  )

add_toy_chapter(toyc-ch5
  toyc.cpp
  parser/AST.cpp
  mlir/EarlyLowering.cpp
  mlir/LateLowering.cpp
  mlir/MLIRGen.cpp
  mlir/ShapeInferencePass.cpp
  mlir/ToyDialect.cpp
  mlir/ToyCombine.cpp
  )
include_directories(include/)
target_link_libraries(toyc-ch5
  PRIVATE
    Linalg3DialectConstruction
    Linalg3
    Linalg2
    Linalg1
    MLIRAnalysis
    MLIREDSC
    MLIRExecutionEngine
    MLIRIR
    MLIRLLVMIR
    MLIRParser
    MLIRPass
    MLIRTargetLLVMIR
    MLIRTransforms
    MLIRSupport
)
whole_archive_link(toyc-ch5
  MLIRAffineOps
  MLIRStandardOps
)


set(LLVM_LINK_COMPONENTS
  Support
  )

add_toy_chapter(toyc-ch5
  toyc.cpp
  parser/AST.cpp
  mlir/EarlyLowering.cpp
  mlir/LateLowering.cpp
  mlir/MLIRGen.cpp
  mlir/ShapeInferencePass.cpp
  mlir/ToyDialect.cpp
  mlir/ToyCombine.cpp
  )
include_directories(include/)
include_directories(../../Linalg/Linalg1/include/)
include_directories(../../Linalg/Linalg2/include/)
include_directories(../../Linalg/Linalg3/include/)
target_link_libraries(toyc-ch5
  PRIVATE
    Linalg3DialectConstruction
    Linalg3
    Linalg2
    Linalg1
    MLIRAnalysis
    MLIREDSC
    MLIRExecutionEngine
    MLIRIR
    MLIRLLVMIR
    MLIRParser
    MLIRPass
    MLIRTargetLLVMIR
    MLIRTransforms
    MLIRSupport
)
whole_archive_link(toyc-ch5
  MLIRAffineOps
  MLIRStandardOps
)


Fix Toy cmake build: add missing includes
    Fix Toy cmake build: add missing includes

--

PiperOrigin-RevId: 242609231
