Revision: 4291
Author: [email protected]
Date: Fri Mar 26 00:58:24 2010
Log: Proper constraints for inline implementation in assembly.

Review URL: http://codereview.chromium.org/1359002

http://code.google.com/p/v8/source/detail?r=4291

Modified:
 /branches/bleeding_edge/src/utils.h

=======================================
--- /branches/bleeding_edge/src/utils.h Wed Mar 17 08:15:45 2010
+++ /branches/bleeding_edge/src/utils.h Fri Mar 26 00:58:24 2010
@@ -581,11 +581,12 @@
 #endif

 #if defined(__GNUC__) && defined(STOS)
-  asm("cld;"
+  asm volatile(
+      "cld;"
       "rep ; " STOS
-      : /* no output */
-      : "c" (counter), "a" (value), "D" (dest)
-      : /* no clobbered list as all inputs are considered clobbered */);
+      : "+&c" (counter), "+&D" (dest)
+      : "a" (value)
+      : "memory", "cc");
 #else
   for (int i = 0; i < counter; i++) {
     dest[i] = value;

--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

To unsubscribe from this group, send email to v8-dev+unsubscribegooglegroups.com or reply 
to this email with the words "REMOVE ME" as the subject.

Reply via email to