P
Phil Tomson
Guest
I've searched around Xilinx's site, but I havent' been able to find the
meaning of this error message (there was a message there about how this
had been fixed in XSE 4.something, but I've tried on both 6.2i and 6.3i
and still get the same error).
Here's the error:
Analyzing Entity <csvm> (Architecture <synth_csvm>.
ERROR:Xst:829 - C:/phil/vhdl/svm/../fix_std.vhd line 1382: Constant Value
expected for Generic 'U'.
Here's the offending line:
Copy_V(F, N, overflow, rounding);
Here's the Copy_V function:
procedure Copy_V(
target : out UFix;
source : UFix;
overflow : Fix_Overflow_Mode := Fix_Default_Overflow;
rounding : Fix_Rounding_Mode := Fix_Default_Rounding
) is
subtype target_T is UFix(target'RANGE);
variable W: UFix(Max(target'LEFT, source'LEFT+1) downto
Min(target'RIGHT, source'RIGHT));
constant HighZero: UFix(W'LEFT downto target'LEFT+1) := (others =>
'0');
begin
assert not target'ASCENDING
report "target" & bad_direction_msg
severity direction_severity;
assert not source'ASCENDING
report "source" & bad_direction_msg
severity direction_severity;
W := (others => '0');
W(source'RANGE) := source;
if target'RIGHT > source'RIGHT then
case rounding is
when clip_LS | towards_zero =>
null;
when to_nearest =>
W(W'LEFT downto target'RIGHT-1) := UFix(
unsigned(W(W'LEFT downto target'RIGHT-1)) + 1
);
end case;
end if;
target := W(target'RANGE);
if HighZero'LENGTH > 0 then
if unsigned(W(HighZero'RANGE)) /= unsigned(HighZero) then
case overflow is
when clip_MS =>
null;
when saturate =>
target := target_T'(others => '1');
end case;
end if;
end if;
end;
I have no idea what this error message is trying to tell me. This code
compiles fine in my simulator (GHDL).
Any ideas about what this means?
Phil
meaning of this error message (there was a message there about how this
had been fixed in XSE 4.something, but I've tried on both 6.2i and 6.3i
and still get the same error).
Here's the error:
Analyzing Entity <csvm> (Architecture <synth_csvm>.
ERROR:Xst:829 - C:/phil/vhdl/svm/../fix_std.vhd line 1382: Constant Value
expected for Generic 'U'.
Here's the offending line:
Copy_V(F, N, overflow, rounding);
Here's the Copy_V function:
procedure Copy_V(
target : out UFix;
source : UFix;
overflow : Fix_Overflow_Mode := Fix_Default_Overflow;
rounding : Fix_Rounding_Mode := Fix_Default_Rounding
) is
subtype target_T is UFix(target'RANGE);
variable W: UFix(Max(target'LEFT, source'LEFT+1) downto
Min(target'RIGHT, source'RIGHT));
constant HighZero: UFix(W'LEFT downto target'LEFT+1) := (others =>
'0');
begin
assert not target'ASCENDING
report "target" & bad_direction_msg
severity direction_severity;
assert not source'ASCENDING
report "source" & bad_direction_msg
severity direction_severity;
W := (others => '0');
W(source'RANGE) := source;
if target'RIGHT > source'RIGHT then
case rounding is
when clip_LS | towards_zero =>
null;
when to_nearest =>
W(W'LEFT downto target'RIGHT-1) := UFix(
unsigned(W(W'LEFT downto target'RIGHT-1)) + 1
);
end case;
end if;
target := W(target'RANGE);
if HighZero'LENGTH > 0 then
if unsigned(W(HighZero'RANGE)) /= unsigned(HighZero) then
case overflow is
when clip_MS =>
null;
when saturate =>
target := target_T'(others => '1');
end case;
end if;
end if;
end;
I have no idea what this error message is trying to tell me. This code
compiles fine in my simulator (GHDL).
Any ideas about what this means?
Phil