This is an archive of the discontinued LLVM Phabricator instance.

[MLIR] Allow non-binary operations to be commutative
ClosedPublic

Authored by stephenneuendorffer on Jan 29 2020, 3:59 PM.

Diff Detail

Event Timeline

Unit tests: fail. 62314 tests passed, 1 failed and 838 were skipped.

failed: libc++.std/thread/thread_mutex/thread_mutex_requirements/thread_mutex_requirements_mutex/thread_mutex_class/try_lock.pass.cpp

clang-tidy: fail. clang-tidy found 0 errors and 1 warnings. 0 of them are added as review comments below (why?).

clang-format: fail. Please format your changes with clang-format by running git-clang-format HEAD^ or applying this patch.

Build artifacts: diff.json, clang-tidy.txt, clang-format.patch, CMakeCache.txt, console-log.txt, test-results.xml

Pre-merge checks is in beta. Report issue. Please join beta or enable it for your project.

rriddle requested changes to this revision.Jan 29 2020, 4:59 PM
rriddle added inline comments.
mlir/lib/Transforms/Utils/FoldUtils.cpp
142

You should be able to do something like:

return matchPattern(O.get(), m_Constant());
mlir/test/Transforms/test-canonicalize.mlir
48
This revision now requires changes to proceed.Jan 29 2020, 4:59 PM

Unit tests: pass. 62315 tests passed, 0 failed and 838 were skipped.

clang-tidy: fail. clang-tidy found 0 errors and 1 warnings. 0 of them are added as review comments below (why?).

clang-format: pass.

Build artifacts: diff.json, clang-tidy.txt, clang-format.patch, CMakeCache.txt, console-log.txt, test-results.xml

Pre-merge checks is in beta. Report issue. Please join beta or enable it for your project.

Unit tests: fail. 62513 tests passed, 3 failed and 844 were skipped.

failed: libc++.std/thread/thread_mutex/thread_lock/thread_lock_unique/thread_lock_unique_cons/mutex_time_point.pass.cpp
failed: libc++.std/thread/thread_mutex/thread_mutex_requirements/thread_mutex_requirements_mutex/thread_mutex_class/try_lock.pass.cpp
failed: libc++.std/thread/thread_mutex/thread_mutex_requirements/thread_timedmutex_requirements/thread_timedmutex_recursive/try_lock_until.pass.cpp

clang-tidy: pass.

clang-format: fail. Please format your changes with clang-format by running git-clang-format HEAD^ or applying this patch.

Build artifacts: clang-tidy.txt, clang-format.patch, CMakeCache.txt, console-log.txt, test-results.xml

Pre-merge checks is in beta. Report issue. Please join beta or enable it for your project.

stephenneuendorffer marked an inline comment as done.Feb 7 2020, 5:16 PM

Any more comments?

rriddle accepted this revision.Feb 9 2020, 10:57 PM

Can you update the comment in OperationSupport.h:60? It currently mentions binary operations directly.

This revision is now accepted and ready to land.Feb 9 2020, 10:57 PM
This revision was automatically updated to reflect the committed changes.