Skip to content

Commit cd8e570

Browse files
authored
Merge pull request #3691 from martin-frbg/issue3679-sparc
SPARC: fix DNRM2 returning INF instead of zero due to intermediate overflow
2 parents a4303ae + 06ef015 commit cd8e570

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

kernel/sparc/dnrm2.S

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -387,6 +387,14 @@
387387
FMUL fmax, c1, c1
388388

389389
.LL99:
390+
#ifdef DOUBLE
391+
set 0x000010C6F7A0B5ED8, %g1
392+
393+
st %g1, [%fp-8]
394+
ld [%fp-8], a8
395+
FCMP %fcc0, a8, fmax
396+
fmovdg %fcc0, fzero, c1
397+
#endif
390398
return %i7 + 8
391399
clr %g0
392400

0 commit comments

Comments
 (0)