-
Notifications
You must be signed in to change notification settings - Fork 787
[Matrix][SYCL] Refactor matrix feature header file #5532
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
Conversation
OP(T, +) | ||
OP(T, -) | ||
OP(T, *) | ||
OP(T, /) | ||
OP(bool, ==) | ||
OP(bool, !=) | ||
OP(bool, <) | ||
OP(bool, >) | ||
OP(bool, <=) | ||
OP(bool, >=) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we delete all the overloaded operator's function since implicit conversion from wi_element to T is provided?
Of course we should keep overloaded operator's function of the bfloat16.
…mplicit conversion from wi_element<T> to T
ping? |
@steffenlarsen @dkhaldi any comments? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Always happy to see a reduction in repeated code! Generally it looks great, I just have a couple suggestions.
static uint16_t convert(const T &from) { return make_bf16(from); } | ||
}; | ||
#if __SYCL_DEVICE_ONLY__ | ||
#define OP(input_type, type, op) \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Eh, I am not gifted at naming, do we have a better naming style for 'inuput_type' here? actually it represents input type of 'convert' function.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Just one minor suggestion.
@bader @vladimirlaz could you please help us merge it? |
Allow operands of different type in some overloaded function in wi_element.