summaryrefslogtreecommitdiff
path: root/src/test/resources/chisel3/BlackBoxTest.v
diff options
context:
space:
mode:
authorJack Koenig2018-05-24 15:18:58 -0700
committerGitHub2018-05-24 15:18:58 -0700
commite03e3f730250673ffa48c000caa369ed582467a2 (patch)
tree9a3e7a1c93e10ce77c1b84ce65150b5c9e83deb4 /src/test/resources/chisel3/BlackBoxTest.v
parentd64ee7dd5d536f043cbbae4f1d2a4a01c4ba91e8 (diff)
Use Vec.apply instead of new Vec in VecInit.apply (#825)
The Vec constructor invokes the gen argument for each element in the Vec. Since VecInit invokes cloneSupertype which touches every element of the input Seq, this was an n^2 operation. Vec.apply accepts its arguments by value so cloneSupertype is only called once. It then calls cloneType on that once for each element in the Vec, which is constant time reducing the overall complexity of VecInit to just n.
Diffstat (limited to 'src/test/resources/chisel3/BlackBoxTest.v')
0 files changed, 0 insertions, 0 deletions