Mentions légales du service
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Chameleon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Operate
Environments
Terraform modules
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Admin message
GitLab upgrade completed. Current version is 17.11.4.
Show more breadcrumbs
solverstack
Chameleon
Commits
617c69b3
Commit
617c69b3
authored
5 years ago
by
PRUVOST Florent
Committed by
Mathieu Faverge
5 years ago
Browse files
Options
Downloads
Patches
Plain Diff
fix int overflow in core gram
parent
8d89cdfc
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
coreblas/compute/core_zgram.c
+3
-3
3 additions, 3 deletions
coreblas/compute/core_zgram.c
with
3 additions
and
3 deletions
coreblas/compute/core_zgram.c
+
3
−
3
View file @
617c69b3
...
...
@@ -122,16 +122,16 @@ int CORE_zgram( cham_uplo_t uplo,
return
CHAMELEON_SUCCESS
;
/* overall mean of squares */
d
=
D
[
0
]
*
D
[
0
]
/
(
M
*
N
);
d
=
(
D
[
0
]
*
D
[
0
]
)
/
(
(
double
)
M
*
(
double
)
N
);
for
(
j
=
0
;
j
<
Nt
;
j
++
)
{
/* mean of squares of the column */
dj
=
Dj
[
j
*
LDDJ
]
*
Dj
[
j
*
LDDJ
]
/
M
;
dj
=
(
Dj
[
j
*
LDDJ
]
*
Dj
[
j
*
LDDJ
]
)
/
((
double
)
M
)
;
int
mmin
=
(
uplo
==
ChamLower
)
?
j
:
0
;
int
mmax
=
(
uplo
==
ChamUpper
)
?
chameleon_min
(
j
+
1
,
Mt
)
:
Mt
;
for
(
i
=
mmin
;
i
<
mmax
;
i
++
)
{
/* mean of squares of the row */
di
=
Di
[
i
*
LDDI
]
*
Di
[
i
*
LDDI
]
/
N
;
di
=
(
Di
[
i
*
LDDI
]
*
Di
[
i
*
LDDI
]
)
/
((
double
)
N
)
;
/* compute Gram factor */
A
[
j
*
LDA
+
i
]
=
coef
*
(
A
[
j
*
LDA
+
i
]
*
A
[
j
*
LDA
+
i
]
-
di
-
dj
+
d
);
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment