Skip to contentSkip to conversation

target-microblaze: Delete unused sign_extend() function

PATCH Applied Peter Maydell 3 participants 3 messages Jun 3, 2014 – Jun 8, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 target-microblaze: Delete unused sign_extend() function

The sign_extend() function is unused; delete it.

---
We have sextract() for this these days anyway.

---
 target-microblaze/translate.c | 13 -------------
 1 file changed, 13 deletions(-)
target-microblaze/translate.c +0 -13
index 488df2d..50c214b 100644
@@ -98,19 +98,6 @@ static const char *special_regnames[] =
     "sr16", "sr17", "sr18"
 };
 
-/* Sign extend at translation time.  */
-static inline int sign_extend(unsigned int val, unsigned int width)
-{
-        int sval;
-
-        /* LSL.  */
-        val <<= 31 - width;
-        sval = val;
-        /* ASR.  */
-        sval >>= 31 - width;
-        return sval;
-}
-
 static inline void t_sync_flags(DisasContext *dc)
 {
     /* Synch the tb dependent flags between translator and runtime.  */
Signature · 1 line
1.9.2
Reviewed-by on v1 1/1
#1 lore raw
Quoted 1 line · Peter Maydell

The sign_extend() function is unused; delete it.

Peter, feel free to push this straight in.

Thanks,
Edgar

Quoted 35 lines

---
We have sextract() for this these days anyway.

---
 target-microblaze/translate.c | 13 -------------
 1 file changed, 13 deletions(-)
target-microblaze/translate.c +0 -13
index 488df2d..50c214b 100644
@@ -98,19 +98,6 @@ static const char *special_regnames[] =
     "sr16", "sr17", "sr18"
 };
 
-/* Sign extend at translation time.  */
-static inline int sign_extend(unsigned int val, unsigned int width)
-{
-        int sval;
-
-        /* LSL.  */
-        val <<= 31 - width;
-        sval = val;
-        /* ASR.  */
-        sval >>= 31 - width;
-        return sval;
-}
-
 static inline void t_sync_flags(DisasContext *dc)
 {
     /* Synch the tb dependent flags between translator and runtime.  */
Signature · 1 line
1.9.2