2019-08-15 11:34:36 -05:00
|
|
|
%_pm.h: passes/pmgen/pmgen.py %.pmg
|
2019-10-19 01:04:52 -05:00
|
|
|
$(P) mkdir -p passes/pmgen && $(PYTHON_EXECUTABLE) $< -o $@ -p $(subst _pm.h,,$(notdir $@)) $(filter-out $<,$^)
|
2019-04-29 06:38:56 -05:00
|
|
|
|
|
|
|
# --------------------------------------
|
2019-01-13 03:57:11 -06:00
|
|
|
|
2019-08-19 06:04:06 -05:00
|
|
|
OBJS += passes/pmgen/test_pmgen.o
|
2021-03-11 08:56:32 -06:00
|
|
|
GENFILES += passes/pmgen/test_pmgen_pm.h
|
2019-08-30 16:00:40 -05:00
|
|
|
passes/pmgen/test_pmgen.o: passes/pmgen/test_pmgen_pm.h passes/pmgen/ice40_dsp_pm.h passes/pmgen/peepopt_pm.h passes/pmgen/xilinx_srl_pm.h
|
2019-08-19 06:04:06 -05:00
|
|
|
$(eval $(call add_extra_objs,passes/pmgen/test_pmgen_pm.h))
|
2019-04-29 06:38:56 -05:00
|
|
|
|
|
|
|
# --------------------------------------
|
2019-01-13 03:57:11 -06:00
|
|
|
|
2019-08-15 11:34:36 -05:00
|
|
|
OBJS += passes/pmgen/ice40_dsp.o
|
2021-03-11 08:56:32 -06:00
|
|
|
GENFILES += passes/pmgen/ice40_dsp_pm.h
|
2019-01-13 03:57:11 -06:00
|
|
|
passes/pmgen/ice40_dsp.o: passes/pmgen/ice40_dsp_pm.h
|
2019-08-15 11:34:36 -05:00
|
|
|
$(eval $(call add_extra_objs,passes/pmgen/ice40_dsp_pm.h))
|
2019-01-13 03:57:11 -06:00
|
|
|
|
2019-04-29 06:38:56 -05:00
|
|
|
# --------------------------------------
|
|
|
|
|
2019-08-19 06:04:06 -05:00
|
|
|
OBJS += passes/pmgen/ice40_wrapcarry.o
|
2021-03-11 08:56:32 -06:00
|
|
|
GENFILES += passes/pmgen/ice40_wrapcarry_pm.h
|
2019-08-12 14:06:45 -05:00
|
|
|
passes/pmgen/ice40_wrapcarry.o: passes/pmgen/ice40_wrapcarry_pm.h
|
2019-08-20 22:18:51 -05:00
|
|
|
$(eval $(call add_extra_objs,passes/pmgen/ice40_wrapcarry_pm.h))
|
2019-08-15 11:35:00 -05:00
|
|
|
|
|
|
|
# --------------------------------------
|
|
|
|
|
2019-08-30 07:57:15 -05:00
|
|
|
OBJS += passes/pmgen/xilinx_dsp.o
|
2021-03-11 08:56:32 -06:00
|
|
|
GENFILES += passes/pmgen/xilinx_dsp_pm.h
|
|
|
|
GENFILES += passes/pmgen/xilinx_dsp48a_pm.h
|
|
|
|
GENFILES += passes/pmgen/xilinx_dsp_CREG_pm.h
|
|
|
|
GENFILES += passes/pmgen/xilinx_dsp_cascade_pm.h
|
2019-12-22 13:43:39 -06:00
|
|
|
passes/pmgen/xilinx_dsp.o: passes/pmgen/xilinx_dsp_pm.h passes/pmgen/xilinx_dsp48a_pm.h passes/pmgen/xilinx_dsp_CREG_pm.h passes/pmgen/xilinx_dsp_cascade_pm.h
|
2019-08-30 07:57:15 -05:00
|
|
|
$(eval $(call add_extra_objs,passes/pmgen/xilinx_dsp_pm.h))
|
2019-12-22 13:43:39 -06:00
|
|
|
$(eval $(call add_extra_objs,passes/pmgen/xilinx_dsp48a_pm.h))
|
2019-09-23 15:27:10 -05:00
|
|
|
$(eval $(call add_extra_objs,passes/pmgen/xilinx_dsp_CREG_pm.h))
|
2019-09-20 12:00:09 -05:00
|
|
|
$(eval $(call add_extra_objs,passes/pmgen/xilinx_dsp_cascade_pm.h))
|
2019-04-29 06:38:56 -05:00
|
|
|
|
|
|
|
# --------------------------------------
|
|
|
|
|
2019-08-15 11:34:36 -05:00
|
|
|
OBJS += passes/pmgen/peepopt.o
|
2021-03-11 08:56:32 -06:00
|
|
|
GENFILES += passes/pmgen/peepopt_pm.h
|
2019-04-29 06:38:56 -05:00
|
|
|
passes/pmgen/peepopt.o: passes/pmgen/peepopt_pm.h
|
2019-08-15 11:34:36 -05:00
|
|
|
$(eval $(call add_extra_objs,passes/pmgen/peepopt_pm.h))
|
2019-04-29 06:38:56 -05:00
|
|
|
|
2023-08-02 11:04:54 -05:00
|
|
|
PEEPOPT_PATTERN = passes/pmgen/peepopt_shiftmul_right.pmg
|
|
|
|
PEEPOPT_PATTERN += passes/pmgen/peepopt_shiftmul_left.pmg
|
2019-04-30 04:25:15 -05:00
|
|
|
PEEPOPT_PATTERN += passes/pmgen/peepopt_muldiv.pmg
|
2019-04-30 01:04:22 -05:00
|
|
|
|
|
|
|
passes/pmgen/peepopt_pm.h: passes/pmgen/pmgen.py $(PEEPOPT_PATTERN)
|
2019-10-19 01:04:52 -05:00
|
|
|
$(P) mkdir -p passes/pmgen && $(PYTHON_EXECUTABLE) $< -o $@ -p peepopt $(filter-out $<,$^)
|
2019-08-21 14:50:49 -05:00
|
|
|
|
|
|
|
# --------------------------------------
|
|
|
|
|
|
|
|
OBJS += passes/pmgen/xilinx_srl.o
|
2021-03-11 08:56:32 -06:00
|
|
|
GENFILES += passes/pmgen/xilinx_srl_pm.h
|
2019-08-21 14:50:49 -05:00
|
|
|
passes/pmgen/xilinx_srl.o: passes/pmgen/xilinx_srl_pm.h
|
|
|
|
$(eval $(call add_extra_objs,passes/pmgen/xilinx_srl_pm.h))
|