Skip to content

Commit 2d08f52

Browse files
committed
xcelium: Remove broken VPI support
VPI support never actually worked for the xcelium backend. Remove it to avoid confusion.
1 parent e44d5d0 commit 2d08f52

File tree

3 files changed

+10
-47
lines changed

3 files changed

+10
-47
lines changed

edalize/xcelium.py

Lines changed: 5 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -32,39 +32,22 @@
3232
XRUN ?= $(XCELIUM_HOME)/tools/bin/xrun
3333
3434
TOPLEVEL := {toplevel}
35-
VPI_MODULES := {modules}
3635
PARAMETERS ?= {parameters}
3736
PLUSARGS ?= {plusargs}
3837
XMSIM_OPTIONS ?= {xmsim_options}
3938
XRUN_OPTIONS ?= {xrun_options}
4039
EXTRA_OPTIONS ?= $(XRUN_OPTIONS) $(if $(XMSIM_OPTIONS),-xmsimargs '$(XMSIM_OPTIONS)',) $(addprefix -defparam ,$(PARAMETERS)) $(addprefix +,$(PLUSARGS))
4140
42-
XRUN_CALL = $(XRUN) -q -f edalize_main.f $(addprefix -pli ,$(VPI_MODULES)) $(EXTRA_OPTIONS) -top $(TOPLEVEL)
41+
XRUN_CALL = $(XRUN) -q -f edalize_main.f $(EXTRA_OPTIONS) -top $(TOPLEVEL)
4342
44-
all: $(VPI_MODULES)
43+
all:
4544
46-
run: $(VPI_MODULES)
45+
run:
4746
$(XRUN_CALL)
4847
49-
run-gui: $(VPI_MODULES)
48+
run-gui:
5049
$(XRUN_CALL) -gui -access rwc
51-
52-
clean: {clean_targets}
53-
"""
54-
55-
VPI_MAKE_SECTION = """
56-
{name}_OBJS := {objs}
57-
{name}_LIBS := {libs}
58-
{name}_INCS := $(INCS) {incs}
59-
60-
$({name}_OBJS): %.o : %.c
61-
$(CC) $(CFLAGS) $({name}_INCS) -o $@ $<
62-
63-
{name}: $({name}_OBJS)
64-
$(LD) $(LDFLAGS) -o $@ $? $({name}_LIBS)
65-
66-
clean_{name}:
67-
$(RM) $({name}_OBJS) {name}
50+
clean:
6851
"""
6952

7053

@@ -167,32 +150,15 @@ def _write_makefile(self):
167150
_xmsim_options = self.tool_options.get("xmsim_options", [])
168151
_xrun_options = self.tool_options.get("xrun_options", [])
169152

170-
_modules = [m["name"] for m in self.vpi_modules]
171-
_clean_targets = " ".join(["clean_" + m for m in _modules])
172153
_s = MAKE_HEADER.format(
173154
toplevel=self.toplevel,
174155
parameters=" ".join(_parameters),
175156
plusargs=" ".join(_plusargs),
176157
xmsim_options=" ".join(_xmsim_options),
177158
xrun_options=" ".join(_xrun_options),
178-
modules=" ".join(_modules),
179-
clean_targets=_clean_targets,
180159
)
181160
vpi_make.write(_s)
182161

183-
for vpi_module in self.vpi_modules:
184-
_name = vpi_module["name"]
185-
_objs = [os.path.splitext(s)[0] + ".o" for s in vpi_module["src_files"]]
186-
_libs = ["-l" + l for l in vpi_module["libs"]]
187-
_incs = ["-I" + d for d in vpi_module["include_dirs"]]
188-
_s = VPI_MAKE_SECTION.format(
189-
name=_name,
190-
objs=" ".join(_objs),
191-
libs=" ".join(_libs),
192-
incs=" ".join(_incs),
193-
)
194-
vpi_make.write(_s)
195-
196162
vpi_make.close()
197163

198164
def configure_main(self):

tests/test_xcelium.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ def test_xcelium(make_edalize_test):
1010
"xrun_options": ["plenty", "of", "xrun_options"],
1111
}
1212

13-
# FIXME: Add VPI tests
1413
tf = make_edalize_test("xcelium", tool_options=tool_options)
1514

1615
tf.backend.configure()

tests/test_xcelium/Makefile

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,21 +21,19 @@ INCS := -I$(XCELIUM_HOME)/tools/include
2121
XRUN ?= $(XCELIUM_HOME)/tools/bin/xrun
2222

2323
TOPLEVEL := top_module
24-
VPI_MODULES :=
2524
PARAMETERS ?= vlogparam_bool=1 vlogparam_int=42 vlogparam_str=hello
2625
PLUSARGS ?= plusarg_bool=1 plusarg_int=42 plusarg_str=hello
2726
XMSIM_OPTIONS ?= a few xmsim_options
2827
XRUN_OPTIONS ?= plenty of xrun_options
2928
EXTRA_OPTIONS ?= $(XRUN_OPTIONS) $(if $(XMSIM_OPTIONS),-xmsimargs '$(XMSIM_OPTIONS)',) $(addprefix -defparam ,$(PARAMETERS)) $(addprefix +,$(PLUSARGS))
3029

31-
XRUN_CALL = $(XRUN) -q -f edalize_main.f $(addprefix -pli ,$(VPI_MODULES)) $(EXTRA_OPTIONS) -top $(TOPLEVEL)
30+
XRUN_CALL = $(XRUN) -q -f edalize_main.f $(EXTRA_OPTIONS) -top $(TOPLEVEL)
3231

33-
all: $(VPI_MODULES)
32+
all:
3433

35-
run: $(VPI_MODULES)
34+
run:
3635
$(XRUN_CALL)
3736

38-
run-gui: $(VPI_MODULES)
37+
run-gui:
3938
$(XRUN_CALL) -gui -access rwc
40-
41-
clean:
39+
clean:

0 commit comments

Comments
 (0)