3 /* Subroutine */ int dscal_(integer *n, doublereal *da, doublereal *dx,
6 /* System generated locals */
10 integer i__, m, mp1, nincx;
12 /* .. Scalar Arguments .. */
14 /* .. Array Arguments .. */
20 /* scales a vector by a constant. */
21 /* uses unrolled loops for increment equal to one. */
22 /* jack dongarra, linpack, 3/11/78. */
23 /* modified 3/93 to return if incx .le. 0. */
24 /* modified 12/3/93, array(1) declarations changed to array(*) */
27 /* .. Local Scalars .. */
29 /* .. Intrinsic Functions .. */
31 /* Parameter adjustments */
35 if (*n <= 0 || *incx <= 0) {
42 /* code for increment not equal to 1 */
47 for (i__ = 1; i__2 < 0 ? i__ >= i__1 : i__ <= i__1; i__ += i__2) {
48 dx[i__] = *da * dx[i__];
53 /* code for increment equal to 1 */
64 for (i__ = 1; i__ <= i__2; ++i__) {
65 dx[i__] = *da * dx[i__];
74 for (i__ = mp1; i__ <= i__2; i__ += 5) {
75 dx[i__] = *da * dx[i__];
76 dx[i__ + 1] = *da * dx[i__ + 1];
77 dx[i__ + 2] = *da * dx[i__ + 2];
78 dx[i__ + 3] = *da * dx[i__ + 3];
79 dx[i__ + 4] = *da * dx[i__ + 4];