VirtualBox

Changeset 8253 in vbox for trunk/include


Ignore:
Timestamp:
Apr 21, 2008 8:11:11 PM (17 years ago)
Author:
vboxsync
Message:

fix assembler getters()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/iprt/asm.h

    r8245 r8253  
    934934# elif RT_INLINE_ASM_GNU_STYLE
    935935#  ifdef RT_ARCH_AMD64
    936     __asm__ ("movq  %%cr0, %0\t\n" : "=r" (uCR0));
    937 #  else
    938     __asm__ ("movl  %%cr0, %0\t\n" : "=r" (uCR0));
     936    __asm__ __volatile__("movq  %%cr0, %0\t\n" : "=r" (uCR0));
     937#  else
     938    __asm__ __volatile__("movl  %%cr0, %0\t\n" : "=r" (uCR0));
    939939#  endif
    940940# else
     
    10041004# elif RT_INLINE_ASM_GNU_STYLE
    10051005#  ifdef RT_ARCH_AMD64
    1006     __asm__ ("movq  %%cr2, %0\t\n" : "=r" (uCR2));
    1007 #  else
    1008     __asm__ ("movl  %%cr2, %0\t\n" : "=r" (uCR2));
     1006    __asm__ __volatile__("movq  %%cr2, %0\t\n" : "=r" (uCR2));
     1007#  else
     1008    __asm__ __volatile__("movl  %%cr2, %0\t\n" : "=r" (uCR2));
    10091009#  endif
    10101010# else
     
    10711071# elif RT_INLINE_ASM_GNU_STYLE
    10721072#  ifdef RT_ARCH_AMD64
    1073     __asm__ ("movq  %%cr3, %0\t\n" : "=r" (uCR3));
    1074 #  else
    1075     __asm__ ("movl  %%cr3, %0\t\n" : "=r" (uCR3));
     1073    __asm__ __volatile__("movq  %%cr3, %0\t\n" : "=r" (uCR3));
     1074#  else
     1075    __asm__ __volatile__("movl  %%cr3, %0\t\n" : "=r" (uCR3));
    10761076#  endif
    10771077# else
     
    11801180# elif RT_INLINE_ASM_GNU_STYLE
    11811181#  ifdef RT_ARCH_AMD64
    1182     __asm__ ("movq  %%cr4, %0\t\n" : "=r" (uCR4));
    1183 #  else
    1184     __asm__ ("movl  %%cr4, %0\t\n" : "=r" (uCR4));
     1182    __asm__ __volatile__("movq  %%cr4, %0\t\n" : "=r" (uCR4));
     1183#  else
     1184    __asm__ __volatile__("movl  %%cr4, %0\t\n" : "=r" (uCR4));
    11851185#  endif
    11861186# else
     
    12591259
    12601260#  elif RT_INLINE_ASM_GNU_STYLE
    1261     __asm__ ("movq  %%cr8, %0\t\n" : "=r" (uCR8));
     1261    __asm__ __volatile__("movq  %%cr8, %0\t\n" : "=r" (uCR8));
    12621262#  else
    12631263    __asm
     
    15051505# if RT_INLINE_ASM_GNU_STYLE
    15061506#  ifdef RT_ARCH_AMD64
    1507     __asm__ ("movq   %%dr7, %0\n\t" : "=r" (uDR7));
    1508 #  else
    1509     __asm__ ("movl   %%dr7, %0\n\t" : "=r" (uDR7));
     1507    __asm__ __volatile__("movq   %%dr7, %0\n\t" : "=r" (uDR7));
     1508#  else
     1509    __asm__ __volatile__("movl   %%dr7, %0\n\t" : "=r" (uDR7));
    15101510#  endif
    15111511# else
     
    15391539# if RT_INLINE_ASM_GNU_STYLE
    15401540#  ifdef RT_ARCH_AMD64
    1541     __asm__ ("movq   %%dr6, %0\n\t" : "=r" (uDR6));
    1542 #  else
    1543     __asm__ ("movl   %%dr6, %0\n\t" : "=r" (uDR6));
     1541    __asm__ __volatile__("movq   %%dr6, %0\n\t" : "=r" (uDR6));
     1542#  else
     1543    __asm__ __volatile__("movl   %%dr6, %0\n\t" : "=r" (uDR6));
    15441544#  endif
    15451545# else
     
    15741574    RTCCUINTREG uNewValue =  0xffff0ff0;  /* 31-16 and 4-11 are 1's, 12 and 63-31 are zero. */
    15751575#  ifdef RT_ARCH_AMD64
    1576     __asm__ ("movq   %%dr6, %0\n\t"
     1576    __asm__ __volatile__("movq   %%dr6, %0\n\t"
    15771577             "movq   %1, %%dr6\n\t"
    15781578             : "=r" (uDR6)
    15791579             : "r" (uNewValue));
    15801580#  else
    1581     __asm__ ("movl   %%dr6, %0\n\t"
     1581    __asm__ __volatile__("movl   %%dr6, %0\n\t"
    15821582             "movl   %1, %%dr6\n\t"
    15831583             : "=r" (uDR6)
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette