legalize readio/writeio into load/stores, fixing CodeGen/X86/io.llx with
the pattern isel.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21828 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Target/X86/X86ISelPattern.cpp b/lib/Target/X86/X86ISelPattern.cpp
index d4b2b1a..584d4af 100644
--- a/lib/Target/X86/X86ISelPattern.cpp
+++ b/lib/Target/X86/X86ISelPattern.cpp
@@ -70,6 +70,15 @@
setOperationAction(ISD::CTTZ , MVT::i32 , Expand);
setOperationAction(ISD::CTLZ , MVT::i32 , Expand);
+ setOperationAction(ISD::READIO , MVT::i1 , Expand);
+ setOperationAction(ISD::READIO , MVT::i8 , Expand);
+ setOperationAction(ISD::READIO , MVT::i16 , Expand);
+ setOperationAction(ISD::READIO , MVT::i32 , Expand);
+ setOperationAction(ISD::WRITEIO , MVT::i1 , Expand);
+ setOperationAction(ISD::WRITEIO , MVT::i8 , Expand);
+ setOperationAction(ISD::WRITEIO , MVT::i16 , Expand);
+ setOperationAction(ISD::WRITEIO , MVT::i32 , Expand);
+
if (!UnsafeFPMath) {
setOperationAction(ISD::FSIN , MVT::f64 , Expand);
setOperationAction(ISD::FCOS , MVT::f64 , Expand);