Skip to content

Commit c8535a2

Browse files
Virat Agarwalheeran-xilinx
authored andcommitted
Adding run target to kernel_swap (#431)
1 parent f3b341f commit c8535a2

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

sys_opt/kernel_swap/Makefile

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,33 @@ ifeq ($(HOST_ARCH), x86)
183183
endif
184184
endif
185185

186+
############################## Setting Essential Checks and Running Rules ##############################
187+
run: all
188+
ifeq ($(findstring zcu102_base_202010, $(DEVICE)), zcu102_base_202010)
189+
$(error This example is not supported for $(DEVICE))
190+
endif
191+
ifeq ($(findstring zcu104_base_202010, $(DEVICE)), zcu104_base_202010)
192+
$(error This example is not supported for $(DEVICE))
193+
endif
194+
ifeq ($(findstring vck, $(DEVICE)), vck)
195+
$(error This example is not supported for $(DEVICE))
196+
endif
197+
ifeq ($(findstring zc7, $(DEVICE)), zc7)
198+
$(error This example is not supported for $(DEVICE))
199+
endif
200+
ifeq ($(TARGET),$(filter $(TARGET),sw_emu hw_emu))
201+
ifeq ($(HOST_ARCH), x86)
202+
$(CP) $(EMCONFIG_DIR)/emconfig.json .
203+
XCL_EMULATION_MODE=$(TARGET) ./$(EXECUTABLE) -x1 $(BUILD_DIR)/krnl_vmul.xclbin -x2 $(BUILD_DIR)/krnl_vadd.xclbin
204+
else
205+
$(ABS_COMMON_REPO)/common/utility/run_emulation.pl "./${LAUNCH_EMULATOR} | tee run_app.log" "./${RUN_APP_SCRIPT} $(TARGET)" "${RESULT_STRING}" "7"
206+
endif
207+
else
208+
ifeq ($(HOST_ARCH), x86)
209+
./$(EXECUTABLE) -x1 $(BUILD_DIR)/krnl_vmul.xclbin -x2 $(BUILD_DIR)/krnl_vadd.xclbin
210+
endif
211+
endif
212+
186213
.PHONY: test
187214
test: $(EXECUTABLE)
188215
ifeq ($(TARGET),$(filter $(TARGET),sw_emu hw_emu))

0 commit comments

Comments
 (0)