Skip to content

Commit b3944af

Browse files
authored
Merge pull request #19463 from knn-k/fixWriteGPInfo
Fix the output of floating point values in writeGPInfo()
2 parents 12856fe + fa632a3 commit b3944af

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

runtime/vm/gphandle.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -971,36 +971,36 @@ writeGPInfo(struct J9PortLibrary* portLibrary, void *writeGPInfoCrashData)
971971

972972
switch (infoKind) {
973973
case J9PORT_SIG_VALUE_16:
974-
n = j9str_printf(PORTLIB, cursor, length, "%s=%04X%c", name, *(U_16 *)value, c);
974+
n = j9str_printf(PORTLIB, cursor, length, "%s=%04X%c", name, *(U_16 *)value, c);
975975
break;
976976
case J9PORT_SIG_VALUE_32:
977-
n = j9str_printf(PORTLIB, cursor , length, "%s=%08.8x%c", name, *(U_32 *)value, c);
977+
n = j9str_printf(PORTLIB, cursor, length, "%s=%08.8x%c", name, *(U_32 *)value, c);
978978
break;
979979
case J9PORT_SIG_VALUE_64:
980-
n = j9str_printf(PORTLIB, cursor, length,"%s=%016.16llx%c", name, *(U_64 *)value, c);
980+
n = j9str_printf(PORTLIB, cursor, length, "%s=%016.16llx%c", name, *(U_64 *)value, c);
981981
break;
982982
case J9PORT_SIG_VALUE_128:
983983
{
984984
const U_128 * const v = (U_128 *) value;
985985
const U_64 h = v->high64;
986986
const U_64 l = v->low64;
987987

988-
n = j9str_printf(PORTLIB, cursor, length,"%s=%016.16llx%016.16llx%c", name, h, l, c);
988+
n = j9str_printf(PORTLIB, cursor, length, "%s=%016.16llx%016.16llx%c", name, h, l, c);
989989
}
990990
break;
991991
case J9PORT_SIG_VALUE_STRING:
992-
n = j9str_printf(PORTLIB, cursor, length, "%s=%s%c", name, (char *)value, c);
992+
n = j9str_printf(PORTLIB, cursor, length, "%s=%s%c", name, (char *)value, c);
993993
break;
994994
case J9PORT_SIG_VALUE_ADDRESS:
995-
n = j9str_printf(PORTLIB, cursor, length, "%s=%p%c", name, *(void**)value, c);
995+
n = j9str_printf(PORTLIB, cursor, length, "%s=%p%c", name, *(void**)value, c);
996996
break;
997997
case J9PORT_SIG_VALUE_FLOAT_64:
998998
/* make sure when casting to a float that we get least significant 32-bits. */
999-
n = j9str_printf(PORTLIB, cursor, length,"%s %016.16llx (f: %f, d: %e)%c", name, *(U_64 *)value, (float)LOW_U32_FROM_DBL_PTR(value), *(double *)value, c);
999+
n = j9str_printf(PORTLIB, cursor, length, "%s=%016.16llx (f: %f, d: %e)%c", name, *(U_64 *)value, (float)LOW_U32_FROM_DBL_PTR(value), *(double *)value, c);
10001000
break;
10011001
case J9PORT_SIG_VALUE_UNDEFINED:
10021002
default:
1003-
n = j9str_printf(PORTLIB, cursor, length, "%s=<UNDEFINED>%c", name, c);
1003+
n = j9str_printf(PORTLIB, cursor, length, "%s=<UNDEFINED>%c", name, c);
10041004
break;
10051005
}
10061006

0 commit comments

Comments
 (0)