Skip to content

Commit f0f4675

Browse files
committed
remove memory constraint and fix definition.
1 parent 17c3fc9 commit f0f4675

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

clang/lib/Headers/intrin.h

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -349,25 +349,22 @@ static inline unsigned long _inpd(unsigned short port) {
349349
}
350350

351351
static inline int _outp(unsigned short port, int data) {
352-
__asm__ volatile("outb %b0, %w1" : : "a"(data), "Nd"(port) : "memory");
352+
__asm__ volatile("outb %b0, %w1" : : "a"(data), "Nd"(port));
353353
return data;
354354
}
355355

356356
static inline unsigned short
357357
_outpw(unsigned short port, unsigned short data) {
358-
__asm__ volatile("outw %w0, %w1" : : "a"(data), "Nd"(port) : "memory");
358+
__asm__ volatile("outw %w0, %w1" : : "a"(data), "Nd"(port));
359359
return data;
360360
}
361361

362362
static inline unsigned long _outpd(unsigned short port,
363363
unsigned long data) {
364-
__asm__ volatile("outl %k0, %w1" : : "a"(data), "Nd"(port) : "memory");
364+
__asm__ volatile("outl %k0, %w1" : : "a"(data), "Nd"(port));
365365
return data;
366366
}
367367

368-
#endif
369-
370-
#if defined(__i386__) || defined(__x86_64__) || defined(__aarch64__)
371368
static __inline__ void __DEFAULT_FN_ATTRS __nop(void) {
372369
__asm__ volatile("nop");
373370
}

0 commit comments

Comments
 (0)