-
Notifications
You must be signed in to change notification settings - Fork 923
Add FP16 datatypes #6205
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Add FP16 datatypes #6205
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
f6b3945
opal/datatype: Support `short float`
kawashima-fj 2ad1c09
opal/datatype: Add `opal_short_float_t`
kawashima-fj 829846d
fp16 hcoll bindings
Sergei-Lebedev 4375c11
ompi/datatype: Add `ompi_mpi_short_float`
kawashima-fj 4d7bde2
ompi/datatype: Use `short float` for `MPI_REAL2`
kawashima-fj c44599e
mpiext/shortfloat: Add `shortfloat` MPI extension
kawashima-fj f8a4419
mpiext/shortfloat: Add `MPIX_C_FLOAT16` datatype
kawashima-fj 9b54967
README: Add description of shortfloat MPI extension
kawashima-fj ef4c47d
configure: disable `short float` with Intel compiler
kawashima-fj File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
dnl -*- shell-script -*- | ||
dnl | ||
dnl Copyright (c) 2018 FUJITSU LIMITED. All rights reserved. | ||
dnl $COPYRIGHT$ | ||
dnl | ||
dnl Additional copyrights may follow | ||
dnl | ||
dnl $HEADER$ | ||
dnl | ||
|
||
# Check whether the user wants to use an alternate type of C 'short float'. | ||
|
||
# OPAL_CHECK_ALT_SHORT_FLOAT | ||
# ------------------------------------------------------------ | ||
AC_DEFUN([OPAL_CHECK_ALT_SHORT_FLOAT], [ | ||
AC_CHECK_TYPES(_Float16) | ||
AC_MSG_CHECKING([if want alternate C type of short float]) | ||
AC_ARG_ENABLE(alt-short-float, | ||
AC_HELP_STRING([--enable-alt-short-float=TYPE], | ||
[Use an alternate C type TYPE of 'short float' if 'short float' is not available on the C compiler. 'short float' is a new C type proposed for the next C language standard in ISO/IEC JTC 1/SC 22 WG 14 (C WG). (default: "_Float16" if available, disabled otherwise)])) | ||
if test "$enable_alt_short_float" = "yes"; then | ||
AC_MSG_ERROR([--enable-alt-short-float must have an argument.]) | ||
elif test "$enable_alt_short_float" = "no"; then | ||
: | ||
elif test "$enable_alt_short_float" != ""; then | ||
opal_short_float_type="$enable_alt_short_float" | ||
opal_short_float_complex_type="$enable_alt_short_float [[2]]" | ||
elif test "$ac_cv_type_short_float" = "yes" && \ | ||
test "$ac_cv_type_short_float__Complex" = "yes"; then | ||
opal_short_float_type="short float" | ||
opal_short_float_complex_type="short float _Complex" | ||
elif test "$ac_cv_type__Float16" = "yes"; then | ||
opal_short_float_type="_Float16" | ||
opal_short_float_complex_type="_Float16 [[2]]" | ||
fi | ||
if test "$opal_short_float_type" != ""; then | ||
AC_MSG_RESULT([yes ($opal_short_float_type)]) | ||
AC_CHECK_TYPES($opal_short_float_type, [opal_enable_short_float=1], [opal_enable_short_float=0]) | ||
if test "$opal_enable_short_float" = 1; then | ||
AC_DEFINE_UNQUOTED(opal_short_float_t, [[$opal_short_float_type]], | ||
[User-selected alternate C type of short float]) | ||
AC_DEFINE_UNQUOTED(opal_short_float_complex_t, [[$opal_short_float_complex_type]], | ||
[User-selected alternate C type of short float _Complex]) | ||
AC_CHECK_TYPES(opal_short_float_t) | ||
AC_CHECK_TYPES(opal_short_float_complex_t) | ||
AC_CHECK_SIZEOF(opal_short_float_t) | ||
AC_CHECK_SIZEOF(opal_short_float_complex_t) | ||
OPAL_C_GET_ALIGNMENT(opal_short_float_t, OPAL_ALIGNMENT_OPAL_SHORT_FLOAT_T) | ||
elif test "$enable_alt_short_float" != ""; then | ||
AC_MSG_ERROR([Alternate C type of short float $opal_short_float_type requested but not available. Aborting]) | ||
fi | ||
else | ||
AC_MSG_RESULT([no]) | ||
fi | ||
]) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.