Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sv2v
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
sv2v
Commits
2f712842
Commit
2f712842
authored
Jul 10, 2021
by
Zachary Snow
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix errant untyped localparam substitution
parent
103db674
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
3 deletions
+13
-3
src/Convert/Interface.hs
+1
-1
src/Convert/Simplify.hs
+0
-2
test/basic/simplify_type.sv
+12
-0
No files found.
src/Convert/Interface.hs
View file @
2f712842
...
...
@@ -570,7 +570,7 @@ inlineInstance global ranges modportBindings items partName
makeParameterBind
(
x
,
Left
t
)
=
ParamType
Localparam
(
paramTmp
++
x
)
t
makeParameterBind
(
x
,
Right
e
)
=
Param
Localparam
(
TypeOf
e
)
(
paramTmp
++
x
)
e
Param
Localparam
UnknownType
(
paramTmp
++
x
)
e
overrideParam
::
Decl
->
Decl
overrideParam
(
Param
Parameter
t
x
e
)
=
...
...
src/Convert/Simplify.hs
View file @
2f712842
...
...
@@ -36,8 +36,6 @@ traverseDeclM decl = do
case
decl'
of
Param
Localparam
UnknownType
x
e
->
insertExpr
x
e
Param
Localparam
(
Implicit
_
[(
RawNum
31
,
RawNum
0
)])
x
e
->
insertExpr
x
e
Param
Localparam
(
Implicit
sg
rs
)
x
e
->
insertExpr
x
$
Cast
(
Left
t
)
e
where
t
=
IntegerVector
TLogic
sg
rs
...
...
test/basic/simplify_type.sv
0 → 100644
View file @
2f712842
module
top
;
localparam
_1
B1
=
1'b1
;
localparam
_1
SB1
=
1
'
sb1
;
localparam
[
31
:
0
]
_1
B1_EXT
=
1'b1
;
localparam
[
31
:
0
]
_1
SB1_EXT
=
1
'
sb1
;
initial
begin
$
display
(
"%d"
,
$
clog2
(
{
_1
B1
,
1'b0
}
))
;
$
display
(
"%d"
,
$
clog2
(
{
_1
SB1
,
1'b0
}
))
;
$
display
(
"%d"
,
$
clog2
(
{
_1
B1_EXT
,
1'b0
}
))
;
$
display
(
"%d"
,
$
clog2
(
{
_1
SB1_EXT
,
1'b0
}
))
;
end
endmodule
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