@@ -490,12 +490,14 @@ l_range = (1:l) .+ (l_sub_start -1)
490490 q, r = qr! (A)
491491 @test collect (d_q) ≈ Array (q)
492492 @test collect (d_r) ≈ Array (r)
493+ A = rand (elty, n, m)
494+ d_A = CuArray (A)
493495 A_view = view (A, m_subrange, n_subrange)
494496 d_A_view = view (d_A, m_subrange, n_subrange)
495497 d_q, d_r = qr! (d_A_view)
496498 q, r = qr! (A_view)
497- @test collect (d_q) ≈ Array (q)
498- @test collect (d_r) ≈ Array (r)
499+ @test collect (d_q) ≈ collect (q)
500+ @test collect (d_r) ≈ collect (r)
499501
500502 A = rand (elty, n) # A and B are vectors
501503 d_A = CuArray (A)
@@ -517,26 +519,6 @@ l_range = (1:l) .+ (l_sub_start -1)
517519 d_B = view (d_B_large, n_range)
518520 @test collect (d_M \ d_B) ≈ M \ B
519521
520- A = rand (elty, n) # A and B are vectors
521- d_A = CuArray (A)
522- M = qr! (A)
523- d_M = qr! (d_A)
524- B = rand (elty, n)
525- d_B = CuArray (B)
526- @test collect (d_M \ d_B) ≈ M \ B
527- A_view = view (A, n_subrange)
528- d_A_view = view (d_A, n_subrange)
529- M_view = qr! (A_view)
530- d_M_view = qr! (d_A_view)
531- B_view = view (B, n_subrange)
532- d_B_view = view (d_B, n_subrange)
533- @test collect (d_M_view \ d_B_view) ≈ M_view \ B_view
534- B_large = rand (elty, n_large)
535- B = view (B_large, n_range)
536- d_B_large = CuArray (B_large)
537- d_B = view (d_B_large, n_range)
538- @test collect (d_M \ d_B) ≈ M \ B
539-
540522 A = rand (elty, m, n) # A is a matrix and B,C is a vector
541523 d_A = CuArray (A)
542524 M = qr (A)
@@ -606,6 +588,8 @@ l_range = (1:l) .+ (l_sub_start -1)
606588 @test collect (d_M. R' * d_C) ≈ (M. R' * C)
607589 @test collect (d_C' * d_M. R) ≈ (C' * M. R)
608590 @test collect (d_C' * d_M. R' ) ≈ (C' * M. R' )
591+ A = rand (elty, m, n)
592+ d_A = CuArray (A)
609593 A_view = view (A, m_subrange, n_subrange)
610594 d_A_view = view (d_A, m_subrange, n_subrange)
611595 M_view = qr! (A_view)
@@ -710,6 +694,8 @@ l_range = (1:l) .+ (l_sub_start -1)
710694 @test collect (d_M. R' * d_C) ≈ (M. R' * C)
711695 @test collect (d_C' * d_M. R) ≈ (C' * M. R)
712696 @test collect (d_C' * d_M. R' ) ≈ (C' * M. R' )
697+ A = rand (elty, m, n)
698+ d_A = CuArray (A)
713699 A_view = view (A, m_subrange, n_subrange)
714700 d_A_view = view (d_A, m_subrange, n_subrange)
715701 M_view = qr! (A_view)
0 commit comments