Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [PATCH] Remove MAX_REGISTER_SIZE from sol-thread.c
@ 2017-02-24 10:12 Alan Hayward
  2017-03-01 17:14 ` Yao Qi
  0 siblings, 1 reply; 7+ messages in thread
From: Alan Hayward @ 2017-02-24 10:12 UTC (permalink / raw)
  To: gdb-patches; +Cc: nd

Regcache calls in sol-thread.c are bogus and do nothing.
The code in between will not change or update regcache.
Removed.

Ok to commit?

Alan.

2017-02-24  Alan Hayward  <alan.hayward@arm.com>

	* sol-thread.c (sol_thread_store_registers): Remove regcache calls.


diff --git a/gdb/sol-thread.c b/gdb/sol-thread.c
index a09a3ab9a8bc56f367e3ba1537f5674f0a7f491f..06b146c314a10be0e360a7242bab229ced1c00b1 100644
--- a/gdb/sol-thread.c
+++ b/gdb/sol-thread.c
@@ -534,12 +534,6 @@ sol_thread_store_registers (struct target_ops *ops,

   if (regnum != -1)
     {
-      /* Not writing all the registers.  */
-      char old_value[MAX_REGISTER_SIZE];
-
-      /* Save new register value.  */
-      regcache_raw_collect (regcache, regnum, old_value);
-
       val = p_td_thr_getgregs (&thandle, gregset);
       if (val != TD_OK)
 	error (_("sol_thread_store_registers: td_thr_getgregs %s"),
@@ -548,9 +542,6 @@ sol_thread_store_registers (struct target_ops *ops,
       if (val != TD_OK)
 	error (_("sol_thread_store_registers: td_thr_getfpregs %s"),
 	       td_err_string (val));
-
-      /* Restore new register value.  */
-      regcache_raw_supply (regcache, regnum, old_value);
     }

   fill_gregset (regcache, (gdb_gregset_t *) &gregset, regnum);


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2017-03-02  9:52 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-02-24 10:12 [PATCH] Remove MAX_REGISTER_SIZE from sol-thread.c Alan Hayward
2017-03-01 17:14 ` Yao Qi
2017-03-01 17:24   ` Frank Ch. Eigler
2017-03-01 18:35     ` Alan Hayward
2017-03-01 21:15       ` Yao Qi
     [not found]     ` <20170301211039.aagkvmdlkqn7jf5u@localhost>
2017-03-01 21:59       ` Frank Ch. Eigler
2017-03-02  9:52         ` Yao Qi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox