projects
/
litex.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5681a3c
)
build/xilinx/vivado: only generate constraints that are not empty
author
Florent Kermarrec
<florent@enjoy-digital.fr>
Mon, 8 Jan 2018 16:03:19 +0000
(17:03 +0100)
committer
Florent Kermarrec
<florent@enjoy-digital.fr>
Mon, 8 Jan 2018 16:03:19 +0000
(17:03 +0100)
litex/build/xilinx/vivado.py
patch
|
blob
|
history
diff --git
a/litex/build/xilinx/vivado.py
b/litex/build/xilinx/vivado.py
index 4b9fedfa1a7a5f9b0f2f5adc8a395da7d6ca58b1..ea5eb0111a427fa7d1f27754a6a5d08f18b551e5 100644
(file)
--- a/
litex/build/xilinx/vivado.py
+++ b/
litex/build/xilinx/vivado.py
@@
-21,7
+21,7
@@
def _format_constraint(c):
elif isinstance(c, Misc):
return "set_property " + c.misc.replace("=", " ")
elif isinstance(c, Inverted):
- return
""
+ return
None
else:
raise ValueError("unknown constraint {}".format(c))
@@
-33,7
+33,8
@@
def _format_xdc(signame, resname, *constraints):
fmt_r += "." + resname[2]
r = " ## {}\n".format(fmt_r)
for c in fmt_c:
- r += c + " [get_ports " + signame + "]\n"
+ if c is not None:
+ r += c + " [get_ports " + signame + "]\n"
return r