Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
H
Hdlmake
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
15
Issues
15
List
Board
Labels
Milestones
Merge Requests
4
Merge Requests
4
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
Hdlmake
Commits
2d3307c5
Commit
2d3307c5
authored
Aug 01, 2016
by
Javier D. Garcia-Lasheras
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Solve constructors hierarchy issues for Class ModulePool
parent
8c6a146b
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
47 additions
and
10 deletions
+47
-10
action.py
hdlmake/action/action.py
+3
-2
check.py
hdlmake/action/check.py
+3
-0
core.py
hdlmake/action/core.py
+3
-0
qsys_hw_tcl_update.py
hdlmake/action/qsys_hw_tcl_update.py
+4
-0
simulation.py
hdlmake/action/simulation.py
+9
-0
synthesis.py
hdlmake/action/synthesis.py
+9
-0
tree.py
hdlmake/action/tree.py
+3
-0
module_pool.py
hdlmake/module_pool.py
+13
-8
No files found.
hdlmake/action/action.py
View file @
2d3307c5
...
...
@@ -26,13 +26,14 @@ import logging
from
hdlmake
import
new_dep_solver
as
dep_solver
class
Action
(
objec
t
):
class
Action
(
lis
t
):
"""This is the base class providing the common Action methods"""
def
__init__
(
self
):
def
__init__
(
self
,
*
args
):
self
.
top_module
=
None
self
.
_deps_solved
=
False
self
.
env
=
None
list
.
__init__
(
self
,
*
args
)
def
_check_all_fetched_or_quit
(
self
):
...
...
hdlmake/action/check.py
View file @
2d3307c5
...
...
@@ -31,6 +31,9 @@ from .action import Action
class
ActionCheck
(
Action
):
"""Class providing the method to check general properties"""
def
__init__
(
self
,
*
args
):
Action
.
__init__
(
self
,
*
args
)
def
check_manifest
(
self
):
"""Method that checks the manifest dict"""
logging
.
warning
(
"Problems with top_module at
%
s"
,
self
.
top_module
.
path
)
...
...
hdlmake/action/core.py
View file @
2d3307c5
...
...
@@ -36,6 +36,9 @@ from .action import Action
class
ActionCore
(
Action
):
"""Class that contains the methods for core actions"""
def
__init__
(
self
,
*
args
):
Action
.
__init__
(
self
,
*
args
)
def
fetch
(
self
):
"""Fetch the missing required modules from their remote origin"""
top_module
=
self
.
get_top_module
()
...
...
hdlmake/action/qsys_hw_tcl_update.py
View file @
2d3307c5
...
...
@@ -27,6 +27,10 @@ import logging
from
.action
import
Action
class
QsysHwTclUpdate
(
Action
):
def
__init__
(
self
,
*
args
):
Action
.
__init__
(
self
,
*
args
)
def
qsys_hw_tcl_update
(
self
):
file_set
=
self
.
build_file_set
(
self
.
get_top_module
()
.
manifest_dict
[
"syn_top"
])
...
...
hdlmake/action/simulation.py
View file @
2d3307c5
...
...
@@ -40,6 +40,15 @@ class ActionSimulation(Action,
ToolActiveHDL
,
ToolRiviera
,
ToolGHDL
):
"""This class contains the simulation specific methods"""
def
__init__
(
self
,
*
args
):
Action
.
__init__
(
self
,
*
args
)
ToolIVerilog
.
__init__
(
self
,
*
args
)
ToolISim
.
__init__
(
self
,
*
args
)
ToolModelsim
.
__init__
(
self
,
*
args
)
ToolActiveHDL
.
__init__
(
self
,
*
args
)
ToolRiviera
.
__init__
(
self
,
*
args
)
ToolGHDL
.
__init__
(
self
,
*
args
)
def
_check_simulation_makefile
(
self
):
"""Check if the simulation keys are provided by the top manifest"""
if
not
self
.
get_top_module
()
.
manifest_dict
[
"sim_top"
]:
...
...
hdlmake/action/synthesis.py
View file @
2d3307c5
...
...
@@ -41,6 +41,15 @@ class ActionSynthesis(Action,
ToolQuartus
,
ToolDiamond
,
ToolLibero
):
"""Class providing the public synthesis methods for the user"""
def
__init__
(
self
,
*
args
):
Action
.
__init__
(
self
,
*
args
)
ToolISE
.
__init__
(
self
,
*
args
)
ToolPlanAhead
.
__init__
(
self
,
*
args
)
ToolVivado
.
__init__
(
self
,
*
args
)
ToolQuartus
.
__init__
(
self
,
*
args
)
ToolDiamond
.
__init__
(
self
,
*
args
)
ToolLibero
.
__init__
(
self
,
*
args
)
def
_load_synthesis_tool
(
self
):
"""Returns a tool_object that provides the synthesis tool interface"""
tool_name
=
self
.
get_top_module
()
.
manifest_dict
[
"syn_tool"
]
...
...
hdlmake/action/tree.py
View file @
2d3307c5
...
...
@@ -30,6 +30,9 @@ from .action import Action
class
ActionTree
(
Action
):
"""Class providing methods to create a graph from pool and to analyze it"""
def
__init__
(
self
,
*
args
):
Action
.
__init__
(
self
,
*
args
)
def
_generate_tree_web
(
self
,
hierarchy
,
top_id
):
"""Create a JSON file containing the graph hierarchy from pool"""
if
self
.
env
.
options
.
web
:
...
...
hdlmake/module_pool.py
View file @
2d3307c5
...
...
@@ -34,23 +34,28 @@ from .util import path as path_mod
from
.
import
fetch
from
.env
import
Env
from
.action
import
(
Action
,
Action
Check
,
ActionCore
,
from
.action
import
(
ActionCheck
,
ActionCore
,
ActionTree
,
ActionSimulation
,
ActionSynthesis
,
QsysHwTclUpdate
)
class
ModulePool
(
list
,
ActionCheck
,
ActionCore
,
ActionTree
,
ActionSimulation
,
ActionSynthesis
,
QsysHwTclUpdate
):
class
ModulePool
(
ActionCheck
,
ActionCore
,
ActionTree
,
ActionSimulation
,
ActionSynthesis
,
QsysHwTclUpdate
):
"""
The ModulePool class acts as the container for the HDLMake modules that
are progressively being added to the design hierarchy.
"""
def
__init__
(
self
,
*
args
):
list
.
__init__
(
self
,
*
args
)
Action
.
__init__
(
self
)
ActionCheck
.
__init__
(
self
,
*
args
)
ActionCore
.
__init__
(
self
,
*
args
)
ActionTree
.
__init__
(
self
,
*
args
)
ActionSimulation
.
__init__
(
self
,
*
args
)
ActionSynthesis
.
__init__
(
self
,
*
args
)
QsysHwTclUpdate
.
__init__
(
self
,
*
args
)
def
set_environment
(
self
,
options
):
"""Initialize the module pool environment from the provided options"""
...
...
@@ -95,7 +100,7 @@ class ModulePool(list, ActionCheck, ActionCore,
new_module_args
=
ModuleArgs
()
new_module_args
.
set_args
(
parent
,
url
,
source
,
fetchto
)
new_module
=
Module
(
new_module_args
,
self
)
if
not
self
.
__contains
(
new_module
):
self
.
_add
(
new_module
)
if
not
self
.
top_module
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment