aboutsummaryrefslogtreecommitdiffstats
path: root/src/synth/netlists-memories.adb
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2019-11-10 07:53:14 +0100
committerTristan Gingold <tgingold@free.fr>2019-11-11 20:29:00 +0100
commit45032759fc845dddd2a150c13cb714927cdf98f4 (patch)
treee27f12afa485bd7d2a9fbb6bcbfa0ec69329118c /src/synth/netlists-memories.adb
parent0984b848d16a9445b019363cfe4be82d123e4e20 (diff)
downloadghdl-45032759fc845dddd2a150c13cb714927cdf98f4.tar.gz
ghdl-45032759fc845dddd2a150c13cb714927cdf98f4.tar.bz2
ghdl-45032759fc845dddd2a150c13cb714927cdf98f4.zip
netlists: optimize trunc.
Diffstat (limited to 'src/synth/netlists-memories.adb')
-rw-r--r--src/synth/netlists-memories.adb4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/synth/netlists-memories.adb b/src/synth/netlists-memories.adb
index 07c063cbf..d41468f86 100644
--- a/src/synth/netlists-memories.adb
+++ b/src/synth/netlists-memories.adb
@@ -26,6 +26,7 @@ with Netlists.Locations; use Netlists.Locations;
with Netlists.Internings;
with Netlists.Errors; use Netlists.Errors;
with Netlists.Concats;
+with Netlists.Folds; use Netlists.Folds;
with Synth.Errors; use Synth.Errors;
@@ -354,7 +355,8 @@ package body Netlists.Memories is
end if;
if Addr_W > Max_W then
-- Need to truncate.
- Sub_Addr1 := Build_Trunc (Ctxt, Id_Utrunc, Sub_Addr, Max_W);
+ Sub_Addr1 := Build2_Trunc
+ (Ctxt, Id_Utrunc, Sub_Addr, Max_W, No_Location);
else
Sub_Addr1 := Sub_Addr;
end if;