Skip to content

Commit

Permalink
Make print_matrix O(1) again (#23681)
Browse files Browse the repository at this point in the history
  • Loading branch information
iamed2 authored and mbauman committed Sep 15, 2017
1 parent 9a3ea7d commit c23d6bc
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions base/show.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1617,9 +1617,8 @@ function print_matrix(io::IO, X::AbstractVecOrMat,
postsp = ""
@assert strwidth(hdots) == strwidth(ddots)
sepsize = length(sep)
inds1, inds2 = indices(X,1), indices(X,2)
m, n = length(inds1), length(inds2)
rowsA, colsA = collect(inds1), collect(inds2)
rowsA, colsA = indices(X,1), indices(X,2)
m, n = length(rowsA), length(colsA)
# To figure out alignments, only need to look at as many rows as could
# fit down screen. If screen has at least as many rows as A, look at A.
# If not, then we only need to look at the first and last chunks of A,
Expand Down

2 comments on commit c23d6bc

@nanosoldier
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Executing the daily benchmark build, I will reply here when finished:

@nanosoldier runbenchmarks(ALL, isdaily = true)

@nanosoldier
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your benchmark job has completed - possible performance regressions were detected. A full report can be found here. cc @ararslan

Please sign in to comment.