Skip to content
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

Fixup B0 on certain MacOSX SDKs #557

Merged
merged 1 commit into from
Feb 10, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions src/blas/KokkosBlas3_gemm.hpp
Original file line number Diff line number Diff line change
@@ -117,14 +117,16 @@ gemm (const char transA[],
bool B_t = !(transB[0] == 'N' || transB[0] == 'n');
int64_t A0 = A.extent(0);
int64_t A1 = A.extent(1);
int64_t B0 = B.extent(0);
// B0 is a `#define`'d constant in
// certain MacOSX SDKs in termios.h:291
int64_t B_0 = B.extent(0);
int64_t B1 = B.extent(1);
int64_t C0 = C.extent(0);
int64_t C1 = C.extent(1);

if ( ((A_t?A1:A0) != C0) ||
((B_t?B0:B1) != C1) ||
((A_t?A0:A1) != (B_t?B1:B0)) ) {
((B_t?B_0:B1) != C1) ||
((A_t?A0:A1) != (B_t?B1:B_0)) ) {
std::ostringstream os;
os << "KokkosBlas::gemm: Dimensions of A, B, and C do not match: "
<< "transA: " << transA[0] << " transB: " << transB[0]