]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Make some function parameters pointer to const.
authorFlorian Krohm <florian@eich-krohm.de>
Sat, 24 Nov 2012 21:07:14 +0000 (21:07 +0000)
committerFlorian Krohm <florian@eich-krohm.de>
Sat, 24 Nov 2012 21:07:14 +0000 (21:07 +0000)
Companion patch to valgrind r13138.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2566

VEX/priv/guest_amd64_helpers.c
VEX/priv/guest_arm_helpers.c
VEX/priv/guest_ppc_helpers.c
VEX/priv/guest_x86_helpers.c
VEX/pub/libvex_guest_amd64.h
VEX/pub/libvex_guest_arm.h
VEX/pub/libvex_guest_ppc32.h
VEX/pub/libvex_guest_ppc64.h
VEX/pub/libvex_guest_x86.h

index 8cc11ad51e9164f11e4f9a42c70b437efad36fd6..53546bd3dec504e67437b22f4082594586f5e7eb 100644 (file)
@@ -811,7 +811,7 @@ ULong amd64g_calculate_condition ( ULong/*AMD64Condcode*/ cond,
 
 
 /* VISIBLE TO LIBVEX CLIENT */
-ULong LibVEX_GuestAMD64_get_rflags ( /*IN*/VexGuestAMD64State* vex_state )
+ULong LibVEX_GuestAMD64_get_rflags ( /*IN*/const VexGuestAMD64State* vex_state )
 {
    ULong rflags = amd64g_calculate_rflags_all_WRK(
                      vex_state->guest_CC_OP,
index 2c452e35e050ac0a11da2e796c65739941458aac..e0d87bd4fdc57d49965a92a601e9c3afd492e088 100644 (file)
@@ -910,7 +910,7 @@ void LibVEX_GuestARM_put_flags ( UInt flags_native,
 #endif
 
 /* VISIBLE TO LIBVEX CLIENT */
-UInt LibVEX_GuestARM_get_cpsr ( /*IN*/VexGuestARMState* vex_state )
+UInt LibVEX_GuestARM_get_cpsr ( /*IN*/const VexGuestARMState* vex_state )
 {
    UInt cpsr = 0;
    // NZCV
index 906f9b4546989470fcbb24be4ba32455bd87019a..f320149f4fbc0abc26737312676d762efe49030c 100644 (file)
@@ -210,7 +210,7 @@ IRExpr* guest_ppc64_spechelper ( const HChar* function_name,
 /*----------------------------------------------*/
 
 /* VISIBLE TO LIBVEX CLIENT */
-UInt LibVEX_GuestPPC32_get_CR ( /*IN*/VexGuestPPC32State* vex_state )
+UInt LibVEX_GuestPPC32_get_CR ( /*IN*/const VexGuestPPC32State* vex_state )
 {
 #  define FIELD(_n)                                    \
       ( ( (UInt)                                       \
@@ -231,7 +231,7 @@ UInt LibVEX_GuestPPC32_get_CR ( /*IN*/VexGuestPPC32State* vex_state )
 
 /* VISIBLE TO LIBVEX CLIENT */
 /* Note: %CR is 32 bits even for ppc64 */
-UInt LibVEX_GuestPPC64_get_CR ( /*IN*/VexGuestPPC64State* vex_state )
+UInt LibVEX_GuestPPC64_get_CR ( /*IN*/const VexGuestPPC64State* vex_state )
 {
 #  define FIELD(_n)                                    \
       ( ( (UInt)                                       \
@@ -304,7 +304,7 @@ void LibVEX_GuestPPC64_put_CR ( UInt cr_native,
 
 
 /* VISIBLE TO LIBVEX CLIENT */
-UInt LibVEX_GuestPPC32_get_XER ( /*IN*/VexGuestPPC32State* vex_state )
+UInt LibVEX_GuestPPC32_get_XER ( /*IN*/const VexGuestPPC32State* vex_state )
 {
    UInt w = 0;
    w |= ( ((UInt)vex_state->guest_XER_BC) & 0xFF );
@@ -317,7 +317,7 @@ UInt LibVEX_GuestPPC32_get_XER ( /*IN*/VexGuestPPC32State* vex_state )
 
 /* VISIBLE TO LIBVEX CLIENT */
 /* Note: %XER is 32 bits even for ppc64 */
-UInt LibVEX_GuestPPC64_get_XER ( /*IN*/VexGuestPPC64State* vex_state )
+UInt LibVEX_GuestPPC64_get_XER ( /*IN*/const VexGuestPPC64State* vex_state )
 {
    UInt w = 0;
    w |= ( ((UInt)vex_state->guest_XER_BC) & 0xFF );
index 35938c99cf5d6f13153a637d60d4861ddf2578f0..9c26794fc8b5d1081371b11f55caa0da91a088f7 100644 (file)
@@ -713,7 +713,7 @@ UInt x86g_calculate_condition ( UInt/*X86Condcode*/ cond,
 
 
 /* VISIBLE TO LIBVEX CLIENT */
-UInt LibVEX_GuestX86_get_eflags ( /*IN*/VexGuestX86State* vex_state )
+UInt LibVEX_GuestX86_get_eflags ( /*IN*/const VexGuestX86State* vex_state )
 {
    UInt eflags = x86g_calculate_eflags_all_WRK(
                     vex_state->guest_CC_OP,
index b8fef94dc15aefd0079b3b97762c9682a29e5735..d9e5cbb986cfff3f80024634166d3663393bc85c 100644 (file)
@@ -186,7 +186,7 @@ void LibVEX_GuestAMD64_initialise ( /*OUT*/VexGuestAMD64State* vex_state );
 /* Extract from the supplied VexGuestAMD64State structure the
    corresponding native %rflags value. */
 extern 
-ULong LibVEX_GuestAMD64_get_rflags ( /*IN*/VexGuestAMD64State* vex_state );
+ULong LibVEX_GuestAMD64_get_rflags ( /*IN*/const VexGuestAMD64State* vex_state );
 
 /* Set the carry flag in the given state to 'new_carry_flag', which
    should be zero or one. */
@@ -208,7 +208,7 @@ void LibVEX_GuestX86_put_x87 ( /*IN*/UChar* x87_state,
 /* Extract from the supplied VexGuestX86State structure, an x87 FPU
    image. */
 extern 
-void LibVEX_GuestX86_get_x87 ( /*IN*/VexGuestX86State* vex_state, 
+void LibVEX_GuestX86_get_x87 ( /*IN*/const VexGuestX86State* vex_state, 
                                /*OUT*/UChar* x87_state );
 
 
index e837666f49e81521a225b1c833883f3757d1ba14..bb242f48a59f7a036c71602563b3f8d46287d362 100644 (file)
@@ -217,7 +217,7 @@ void LibVEX_GuestARM_initialise ( /*OUT*/VexGuestARMState* vex_state );
 /* Calculate the ARM flag state from the saved data. */
 
 extern
-UInt LibVEX_GuestARM_get_cpsr ( /*IN*/VexGuestARMState* vex_state );
+UInt LibVEX_GuestARM_get_cpsr ( /*IN*/const VexGuestARMState* vex_state );
 
 
 #endif /* ndef __LIBVEX_PUB_GUEST_ARM_H */
index c69101722acfb4ac0e8a868ff2eddde2ad86169a..d90b7d3bde462f5d0023b232e8571ae173c1ca62 100644 (file)
@@ -265,7 +265,7 @@ void LibVEX_GuestPPC32_put_CR ( UInt cr_native,
 /* Extract from the supplied VexGuestPPC32State structure the
    corresponding native %CR value. */
 extern
-UInt LibVEX_GuestPPC32_get_CR ( /*IN*/VexGuestPPC32State* vex_state );
+UInt LibVEX_GuestPPC32_get_CR ( /*IN*/const VexGuestPPC32State* vex_state );
 
 
 /* Write the given native %XER value to the supplied VexGuestPPC32State
@@ -277,7 +277,7 @@ void LibVEX_GuestPPC32_put_XER ( UInt xer_native,
 /* Extract from the supplied VexGuestPPC32State structure the
    corresponding native %XER value. */
 extern
-UInt LibVEX_GuestPPC32_get_XER ( /*IN*/VexGuestPPC32State* vex_state );
+UInt LibVEX_GuestPPC32_get_XER ( /*IN*/const VexGuestPPC32State* vex_state );
 
 #endif /* ndef __LIBVEX_PUB_GUEST_PPC32_H */
 
index b05b5b15e231b19477e5370ae8e03fd3cc475dbb..1c9502c24063fd6a5cea220cd5ff81f33ec84a1a 100644 (file)
@@ -309,7 +309,7 @@ void LibVEX_GuestPPC64_put_CR ( UInt cr_native,
    corresponding native %CR value.  Note, %CR is 32-bits even for
    ppc64. */
 extern
-UInt LibVEX_GuestPPC64_get_CR ( /*IN*/VexGuestPPC64State* vex_state );
+UInt LibVEX_GuestPPC64_get_CR ( /*IN*/const VexGuestPPC64State* vex_state );
 
 
 /* Write the given native %XER value to the supplied
@@ -323,7 +323,7 @@ void LibVEX_GuestPPC64_put_XER ( UInt xer_native,
    corresponding native %XER value.  Note, %CR is 32-bits even for
    ppc64. */
 extern
-UInt LibVEX_GuestPPC64_get_XER ( /*IN*/VexGuestPPC64State* vex_state );
+UInt LibVEX_GuestPPC64_get_XER ( /*IN*/const VexGuestPPC64State* vex_state );
 
 #endif /* ndef __LIBVEX_PUB_GUEST_PPC64_H */
 
index d46d67b098263bc0b89717e85754c6923bec4f2e..d8d2554b93813f63188806f108bfe0c1f77f7f0e 100644 (file)
@@ -277,7 +277,7 @@ void LibVEX_GuestX86_initialise ( /*OUT*/VexGuestX86State* vex_state );
 /* Extract from the supplied VexGuestX86State structure the
    corresponding native %eflags value. */
 extern 
-UInt LibVEX_GuestX86_get_eflags ( /*IN*/VexGuestX86State* vex_state );
+UInt LibVEX_GuestX86_get_eflags ( /*IN*/const VexGuestX86State* vex_state );
 
 /* Set the carry flag in the given state to 'new_carry_flag', which
    should be zero or one. */