Opened 8 years ago
Closed 8 years ago
#4474 closed defect (fixed)
inefficient list() comprehension
| Reported by: | Henning Kiel | Owned by: | Martin Sjölund |
|---|---|---|---|
| Priority: | high | Milestone: | 1.12.0 |
| Component: | MetaModelica | Version: | |
| Keywords: | Cc: |
Description
In ExpandableArray.toList() there is a line
listT := list(Util.getOption(data[i]) for i guard isSome(data[i]) in 1:capacity);
where the range is really created in the compiled C-code
create_integer_array_from_range(&tmp4, ((modelica_integer) 1), 1, (modelica_integer)_capacity);
instead of using a for loop. This is insane in speed and memory.
Change History (1)
comment:1 by , 8 years ago
| Milestone: | Future → 1.12.0 |
|---|---|
| Resolution: | → fixed |
| Status: | new → closed |
Note:
See TracTickets
for help on using tickets.

Fixed with PR1755.