[ros-diffs] [tkreuzer] 49814: [INTRIN] Implement _inp, _inpd, _inpw, _outp, _outpd, _outpw as intrinsics, like on MSVC

tkreuzer at svn.reactos.org tkreuzer at svn.reactos.org
Sat Nov 27 12:36:15 UTC 2010


Author: tkreuzer
Date: Sat Nov 27 12:36:14 2010
New Revision: 49814

URL: http://svn.reactos.org/svn/reactos?rev=49814&view=rev
Log:
[INTRIN]
Implement _inp, _inpd, _inpw, _outp, _outpd, _outpw as intrinsics, like on MSVC

Modified:
    branches/cmake-bringup/include/crt/mingw32/intrin_x86.h

Modified: branches/cmake-bringup/include/crt/mingw32/intrin_x86.h
URL: http://svn.reactos.org/svn/reactos/branches/cmake-bringup/include/crt/mingw32/intrin_x86.h?rev=49814&r1=49813&r2=49814&view=diff
==============================================================================
--- branches/cmake-bringup/include/crt/mingw32/intrin_x86.h [iso-8859-1] (original)
+++ branches/cmake-bringup/include/crt/mingw32/intrin_x86.h [iso-8859-1] Sat Nov 27 12:36:14 2010
@@ -1113,6 +1113,39 @@
 	__asm__ __volatile__("rep; outsl" : : [Port] "d" (Port), [Buffer] "S" (Buffer), "c" (Count));
 }
 
+__INTRIN_INLINE int _inp(unsigned short Port)
+{
+	return __inbyte(Port);
+}
+
+__INTRIN_INLINE unsigned short _inpw(unsigned short Port)
+{
+	return __inword(Port);
+}
+
+__INTRIN_INLINE unsigned long _inpd(unsigned short Port)
+{
+	return __indword(Port);
+}
+
+__INTRIN_INLINE int _outp(unsigned short Port, int databyte)
+{
+	__outbyte(Port, databyte);
+	return databyte;
+}
+
+__INTRIN_INLINE unsigned short _outpw(unsigned short Port, unsigned short dataword)
+{
+	__outword(Port, dataword);
+	return dataword;
+}
+
+__INTRIN_INLINE unsigned long _outpd(unsigned short Port, unsigned long dataword)
+{
+	__outdword(Port, dataword);
+	return dataword;
+}
+
 
 /*** System information ***/
 __INTRIN_INLINE void __cpuid(int CPUInfo[], const int InfoType)




More information about the Ros-diffs mailing list