Skip to content

Commit

Permalink
Squashed 'data_mover' changes from 0b65225..8a229e3 (#823)
Browse files Browse the repository at this point in the history
8a229e3 Merge pull request Xilinx#3 from RepoOps/rep_a
9a09d42 Replace DEVICE with PLATFORM

Co-authored-by: sdausr <[email protected]>
  • Loading branch information
2 people authored and GitHub Enterprise committed Mar 29, 2023
1 parent c93e11f commit d5401d8
Show file tree
Hide file tree
Showing 14 changed files with 147 additions and 133 deletions.
4 changes: 2 additions & 2 deletions data_mover/L1/tests/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ To perform c-simulation and co-sim on all tests, run the following command in th
make CSIM=1 COSIM=1 run
```

To test device other than default `xcu200-fsgd2104-2-e`, just specify the platform name via DEVICE var, for example:
To test device other than default `xcu200-fsgd2104-2-e`, just specify the platform name via PLATFORM var, for example:

```
make CSIM=1 COSIM=1 check DEVICE=u250_xdma_201803_2 PLATFORM_REPO_PATHS=/my/path/to/xilinx/platforms
make CSIM=1 COSIM=1 check PLATFORM=u250_xdma_201803_2 PLATFORM_REPO_PATHS=/my/path/to/xilinx/platforms
```

Here the `PLATFORM_REPO_PATHS` is used to privde locations for platform files.
24 changes: 12 additions & 12 deletions data_mover/L1/tests/check_stream_with_master/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@ help::
@echo ""
@echo "Makefile Usage:"
@echo ""
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 DEVICE=<FPGA platform> PLATFORM_REPO_PATHS=<path to platform directories>"
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 PLATFORM=<FPGA platform> PLATFORM_REPO_PATHS=<path to platform directories>"
@echo " Command to run the selected tasks for specified device."
@echo ""
@echo " Valid tasks are CSIM, CSYNTH, COSIM, VIVADO_SYN, VIVADO_IMPL"
@echo ""
@echo " DEVICE is case-insensitive and support awk regex."
@echo " For example, \`make run DEVICE='u200.*xdma' COSIM=1\`"
@echo " PLATFORM is case-insensitive and support awk regex."
@echo " For example, \`make run PLATFORM='u200.*xdma' COSIM=1\`"
@echo " It can also be an absolute path to platform file."
@echo ""
@echo " PLATFORM_REPO_PATHS variable is used to specify the paths in which the platform files will be"
Expand All @@ -41,7 +41,7 @@ help::
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 XPART=<FPGA part name>"
@echo " Alternatively, the FPGA part can be speficied via XPART."
@echo " For example, \`make run XPART='xcu200-fsgd2104-2-e' COSIM=1\`"
@echo " When XPART is set, DEVICE will be ignored."
@echo " When XPART is set, PLATFORM will be ignored."
@echo ""
@echo " make clean "
@echo " Command to remove the generated files."
Expand Down Expand Up @@ -98,12 +98,12 @@ endif
ifeq (,$(XPART))
# MK_INC_BEGIN vitis_set_platform.mk

ifneq (,$(wildcard $(DEVICE)))
# Use DEVICE as a file path
XPLATFORM := $(DEVICE)
ifneq (,$(wildcard $(PLATFORM)))
# Use PLATFORM as a file path
XPLATFORM := $(PLATFORM)
else
# Use DEVICE as a file name pattern
DEVICE_L := $(shell echo $(DEVICE) | tr A-Z a-z)
# Use PLATFORM as a file name pattern
DEVICE_L := $(shell echo $(PLATFORM) | tr A-Z a-z)
# 1. search paths specified by variable
ifneq (,$(PLATFORM_REPO_PATHS))
# 1.1 as exact name
Expand Down Expand Up @@ -137,15 +137,15 @@ endif # 3
endif

define MSG_PLATFORM
No platform matched pattern '$(DEVICE)'.
No platform matched pattern '$(PLATFORM)'.
Available platforms are: $(XPLATFORMS)
To add more platform directories, set the PLATFORM_REPO_PATHS variable or point DEVICE variable to the full path of platform .xpfm file.
To add more platform directories, set the PLATFORM_REPO_PATHS variable or point PLATFORM variable to the full path of platform .xpfm file.
endef
export MSG_PLATFORM

define MSG_DEVICE
More than one platform matched: $(XPLATFORM)
Please set DEVICE variable more accurately to select only one platform file, or set DEVICE variable to the full path of the platform .xpfm file.
Please set PLATFORM variable more accurately to select only one platform file, or set PLATFORM variable to the full path of the platform .xpfm file.
endef
export MSG_DEVICE

Expand Down
35 changes: 21 additions & 14 deletions data_mover/L1/tests/cuboid_read_hls/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@ help::
@echo ""
@echo "Makefile Usage:"
@echo ""
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 DEVICE=<FPGA platform> PLATFORM_REPO_PATHS=<path to platform directories>"
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 PLATFORM=<FPGA platform> PLATFORM_REPO_PATHS=<path to platform directories>"
@echo " Command to run the selected tasks for specified device."
@echo ""
@echo " Valid tasks are CSIM, CSYNTH, COSIM, VIVADO_SYN, VIVADO_IMPL"
@echo ""
@echo " DEVICE is case-insensitive and support awk regex."
@echo " For example, \`make run DEVICE='u200.*xdma' COSIM=1\`"
@echo " PLATFORM is case-insensitive and support awk regex."
@echo " For example, \`make run PLATFORM='u200.*xdma' COSIM=1\`"
@echo " It can also be an absolute path to platform file."
@echo ""
@echo " PLATFORM_REPO_PATHS variable is used to specify the paths in which the platform files will be"
Expand All @@ -41,7 +41,7 @@ help::
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 XPART=<FPGA part name>"
@echo " Alternatively, the FPGA part can be speficied via XPART."
@echo " For example, \`make run XPART='xcu200-fsgd2104-2-e' COSIM=1\`"
@echo " When XPART is set, DEVICE will be ignored."
@echo " When XPART is set, PLATFORM will be ignored."
@echo ""
@echo " make clean "
@echo " Command to remove the generated files."
Expand Down Expand Up @@ -98,12 +98,12 @@ endif
ifeq (,$(XPART))
# MK_INC_BEGIN vitis_set_platform.mk

ifneq (,$(wildcard $(DEVICE)))
# Use DEVICE as a file path
XPLATFORM := $(DEVICE)
ifneq (,$(wildcard $(PLATFORM)))
# Use PLATFORM as a file path
XPLATFORM := $(PLATFORM)
else
# Use DEVICE as a file name pattern
DEVICE_L := $(shell echo $(DEVICE) | tr A-Z a-z)
# Use PLATFORM as a file name pattern
DEVICE_L := $(shell echo $(PLATFORM) | tr A-Z a-z)
# 1. search paths specified by variable
ifneq (,$(PLATFORM_REPO_PATHS))
# 1.1 as exact name
Expand Down Expand Up @@ -137,15 +137,15 @@ endif # 3
endif

define MSG_PLATFORM
No platform matched pattern '$(DEVICE)'.
No platform matched pattern '$(PLATFORM)'.
Available platforms are: $(XPLATFORMS)
To add more platform directories, set the PLATFORM_REPO_PATHS variable or point DEVICE variable to the full path of platform .xpfm file.
To add more platform directories, set the PLATFORM_REPO_PATHS variable or point PLATFORM variable to the full path of platform .xpfm file.
endef
export MSG_PLATFORM

define MSG_DEVICE
More than one platform matched: $(XPLATFORM)
Please set DEVICE variable more accurately to select only one platform file, or set DEVICE variable to the full path of the platform .xpfm file.
Please set PLATFORM variable more accurately to select only one platform file, or set PLATFORM variable to the full path of the platform .xpfm file.
endef
export MSG_DEVICE

Expand Down Expand Up @@ -179,6 +179,13 @@ endif # XPART
# MK_INC_END vitis_set_part.mk

# MK_INC_BEGIN hls_test_rules.mk
#

gen_instances: $(INSTANCE_FILES)
@echo "Nothing to generate."

valid_params:
@echo "Nothing to validate."


.PHONY: run setup runhls clean cleanall check
Expand Down Expand Up @@ -217,7 +224,7 @@ endif
data:
@true

run: data setup runhls
run: gen_instances data setup runhls

setup: | check_part
@rm -f ./settings.tcl
Expand All @@ -240,7 +247,7 @@ runhls: data setup | check_vivado check_vpp
$(HLS) -f run_hls.tcl;

clean:
rm -rf settings.tcl *_hls.log prj.prj
rm -rf settings.tcl *_hls.log prj.prj $(INSTANCE_FILES)

# Used by Jenkins test
cleanall: clean
Expand Down
35 changes: 21 additions & 14 deletions data_mover/L1/tests/cuboid_write_hls/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@ help::
@echo ""
@echo "Makefile Usage:"
@echo ""
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 DEVICE=<FPGA platform> PLATFORM_REPO_PATHS=<path to platform directories>"
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 PLATFORM=<FPGA platform> PLATFORM_REPO_PATHS=<path to platform directories>"
@echo " Command to run the selected tasks for specified device."
@echo ""
@echo " Valid tasks are CSIM, CSYNTH, COSIM, VIVADO_SYN, VIVADO_IMPL"
@echo ""
@echo " DEVICE is case-insensitive and support awk regex."
@echo " For example, \`make run DEVICE='u200.*xdma' COSIM=1\`"
@echo " PLATFORM is case-insensitive and support awk regex."
@echo " For example, \`make run PLATFORM='u200.*xdma' COSIM=1\`"
@echo " It can also be an absolute path to platform file."
@echo ""
@echo " PLATFORM_REPO_PATHS variable is used to specify the paths in which the platform files will be"
Expand All @@ -41,7 +41,7 @@ help::
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 XPART=<FPGA part name>"
@echo " Alternatively, the FPGA part can be speficied via XPART."
@echo " For example, \`make run XPART='xcu200-fsgd2104-2-e' COSIM=1\`"
@echo " When XPART is set, DEVICE will be ignored."
@echo " When XPART is set, PLATFORM will be ignored."
@echo ""
@echo " make clean "
@echo " Command to remove the generated files."
Expand Down Expand Up @@ -98,12 +98,12 @@ endif
ifeq (,$(XPART))
# MK_INC_BEGIN vitis_set_platform.mk

ifneq (,$(wildcard $(DEVICE)))
# Use DEVICE as a file path
XPLATFORM := $(DEVICE)
ifneq (,$(wildcard $(PLATFORM)))
# Use PLATFORM as a file path
XPLATFORM := $(PLATFORM)
else
# Use DEVICE as a file name pattern
DEVICE_L := $(shell echo $(DEVICE) | tr A-Z a-z)
# Use PLATFORM as a file name pattern
DEVICE_L := $(shell echo $(PLATFORM) | tr A-Z a-z)
# 1. search paths specified by variable
ifneq (,$(PLATFORM_REPO_PATHS))
# 1.1 as exact name
Expand Down Expand Up @@ -137,15 +137,15 @@ endif # 3
endif

define MSG_PLATFORM
No platform matched pattern '$(DEVICE)'.
No platform matched pattern '$(PLATFORM)'.
Available platforms are: $(XPLATFORMS)
To add more platform directories, set the PLATFORM_REPO_PATHS variable or point DEVICE variable to the full path of platform .xpfm file.
To add more platform directories, set the PLATFORM_REPO_PATHS variable or point PLATFORM variable to the full path of platform .xpfm file.
endef
export MSG_PLATFORM

define MSG_DEVICE
More than one platform matched: $(XPLATFORM)
Please set DEVICE variable more accurately to select only one platform file, or set DEVICE variable to the full path of the platform .xpfm file.
Please set PLATFORM variable more accurately to select only one platform file, or set PLATFORM variable to the full path of the platform .xpfm file.
endef
export MSG_DEVICE

Expand Down Expand Up @@ -179,6 +179,13 @@ endif # XPART
# MK_INC_END vitis_set_part.mk

# MK_INC_BEGIN hls_test_rules.mk
#

gen_instances: $(INSTANCE_FILES)
@echo "Nothing to generate."

valid_params:
@echo "Nothing to validate."


.PHONY: run setup runhls clean cleanall check
Expand Down Expand Up @@ -217,7 +224,7 @@ endif
data:
@true

run: data setup runhls
run: gen_instances data setup runhls

setup: | check_part
@rm -f ./settings.tcl
Expand All @@ -240,7 +247,7 @@ runhls: data setup | check_vivado check_vpp
$(HLS) -f run_hls.tcl;

clean:
rm -rf settings.tcl *_hls.log prj.prj
rm -rf settings.tcl *_hls.log prj.prj $(INSTANCE_FILES)

# Used by Jenkins test
cleanall: clean
Expand Down
24 changes: 12 additions & 12 deletions data_mover/L1/tests/load_master_to_stream/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@ help::
@echo ""
@echo "Makefile Usage:"
@echo ""
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 DEVICE=<FPGA platform> PLATFORM_REPO_PATHS=<path to platform directories>"
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 PLATFORM=<FPGA platform> PLATFORM_REPO_PATHS=<path to platform directories>"
@echo " Command to run the selected tasks for specified device."
@echo ""
@echo " Valid tasks are CSIM, CSYNTH, COSIM, VIVADO_SYN, VIVADO_IMPL"
@echo ""
@echo " DEVICE is case-insensitive and support awk regex."
@echo " For example, \`make run DEVICE='u200.*xdma' COSIM=1\`"
@echo " PLATFORM is case-insensitive and support awk regex."
@echo " For example, \`make run PLATFORM='u200.*xdma' COSIM=1\`"
@echo " It can also be an absolute path to platform file."
@echo ""
@echo " PLATFORM_REPO_PATHS variable is used to specify the paths in which the platform files will be"
Expand All @@ -41,7 +41,7 @@ help::
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 XPART=<FPGA part name>"
@echo " Alternatively, the FPGA part can be speficied via XPART."
@echo " For example, \`make run XPART='xcu200-fsgd2104-2-e' COSIM=1\`"
@echo " When XPART is set, DEVICE will be ignored."
@echo " When XPART is set, PLATFORM will be ignored."
@echo ""
@echo " make clean "
@echo " Command to remove the generated files."
Expand Down Expand Up @@ -98,12 +98,12 @@ endif
ifeq (,$(XPART))
# MK_INC_BEGIN vitis_set_platform.mk

ifneq (,$(wildcard $(DEVICE)))
# Use DEVICE as a file path
XPLATFORM := $(DEVICE)
ifneq (,$(wildcard $(PLATFORM)))
# Use PLATFORM as a file path
XPLATFORM := $(PLATFORM)
else
# Use DEVICE as a file name pattern
DEVICE_L := $(shell echo $(DEVICE) | tr A-Z a-z)
# Use PLATFORM as a file name pattern
DEVICE_L := $(shell echo $(PLATFORM) | tr A-Z a-z)
# 1. search paths specified by variable
ifneq (,$(PLATFORM_REPO_PATHS))
# 1.1 as exact name
Expand Down Expand Up @@ -137,15 +137,15 @@ endif # 3
endif

define MSG_PLATFORM
No platform matched pattern '$(DEVICE)'.
No platform matched pattern '$(PLATFORM)'.
Available platforms are: $(XPLATFORMS)
To add more platform directories, set the PLATFORM_REPO_PATHS variable or point DEVICE variable to the full path of platform .xpfm file.
To add more platform directories, set the PLATFORM_REPO_PATHS variable or point PLATFORM variable to the full path of platform .xpfm file.
endef
export MSG_PLATFORM

define MSG_DEVICE
More than one platform matched: $(XPLATFORM)
Please set DEVICE variable more accurately to select only one platform file, or set DEVICE variable to the full path of the platform .xpfm file.
Please set PLATFORM variable more accurately to select only one platform file, or set PLATFORM variable to the full path of the platform .xpfm file.
endef
export MSG_DEVICE

Expand Down
24 changes: 12 additions & 12 deletions data_mover/L1/tests/preloadable_ram/bram/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@ help::
@echo ""
@echo "Makefile Usage:"
@echo ""
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 DEVICE=<FPGA platform> PLATFORM_REPO_PATHS=<path to platform directories>"
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 PLATFORM=<FPGA platform> PLATFORM_REPO_PATHS=<path to platform directories>"
@echo " Command to run the selected tasks for specified device."
@echo ""
@echo " Valid tasks are CSIM, CSYNTH, COSIM, VIVADO_SYN, VIVADO_IMPL"
@echo ""
@echo " DEVICE is case-insensitive and support awk regex."
@echo " For example, \`make run DEVICE='u200.*xdma' COSIM=1\`"
@echo " PLATFORM is case-insensitive and support awk regex."
@echo " For example, \`make run PLATFORM='u200.*xdma' COSIM=1\`"
@echo " It can also be an absolute path to platform file."
@echo ""
@echo " PLATFORM_REPO_PATHS variable is used to specify the paths in which the platform files will be"
Expand All @@ -41,7 +41,7 @@ help::
@echo " make run CSIM=1 CSYNTH=1 COSIM=1 XPART=<FPGA part name>"
@echo " Alternatively, the FPGA part can be speficied via XPART."
@echo " For example, \`make run XPART='xcu200-fsgd2104-2-e' COSIM=1\`"
@echo " When XPART is set, DEVICE will be ignored."
@echo " When XPART is set, PLATFORM will be ignored."
@echo ""
@echo " make clean "
@echo " Command to remove the generated files."
Expand Down Expand Up @@ -98,12 +98,12 @@ endif
ifeq (,$(XPART))
# MK_INC_BEGIN vitis_set_platform.mk

ifneq (,$(wildcard $(DEVICE)))
# Use DEVICE as a file path
XPLATFORM := $(DEVICE)
ifneq (,$(wildcard $(PLATFORM)))
# Use PLATFORM as a file path
XPLATFORM := $(PLATFORM)
else
# Use DEVICE as a file name pattern
DEVICE_L := $(shell echo $(DEVICE) | tr A-Z a-z)
# Use PLATFORM as a file name pattern
DEVICE_L := $(shell echo $(PLATFORM) | tr A-Z a-z)
# 1. search paths specified by variable
ifneq (,$(PLATFORM_REPO_PATHS))
# 1.1 as exact name
Expand Down Expand Up @@ -137,15 +137,15 @@ endif # 3
endif

define MSG_PLATFORM
No platform matched pattern '$(DEVICE)'.
No platform matched pattern '$(PLATFORM)'.
Available platforms are: $(XPLATFORMS)
To add more platform directories, set the PLATFORM_REPO_PATHS variable or point DEVICE variable to the full path of platform .xpfm file.
To add more platform directories, set the PLATFORM_REPO_PATHS variable or point PLATFORM variable to the full path of platform .xpfm file.
endef
export MSG_PLATFORM

define MSG_DEVICE
More than one platform matched: $(XPLATFORM)
Please set DEVICE variable more accurately to select only one platform file, or set DEVICE variable to the full path of the platform .xpfm file.
Please set PLATFORM variable more accurately to select only one platform file, or set PLATFORM variable to the full path of the platform .xpfm file.
endef
export MSG_DEVICE

Expand Down
Loading

0 comments on commit d5401d8

Please sign in to comment.