This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 2/5] Associate target_dcache to address_space.
- From: Tom Tromey <tromey at redhat dot com>
- To: Yao Qi <yao at codesourcery dot com>
- Cc: <gdb-patches at sourceware dot org>
- Date: Mon, 28 Oct 2013 14:49:16 -0600
- Subject: Re: [PATCH 2/5] Associate target_dcache to address_space.
- Authentication-results: sourceware.org; auth=none
- References: <1382516855-32218-1-git-send-email-yao at codesourcery dot com> <1382516855-32218-3-git-send-email-yao at codesourcery dot com> <878uxkdjv3 dot fsf at fleche dot redhat dot com> <5268DAE1 dot 6070409 at codesourcery dot com>
>>>>> "Yao" == Yao Qi <yao@codesourcery.com> writes:
Yao> 2013-10-24 Yao Qi <yao@codesourcery.com>
Yao> * progspace.h (struct address_space): Declare.
Yao> * target.c (target_dcache_aspace_key): New.
Yao> (target_dcache): Delete.
Yao> (struct target_dcache): New.
Yao> (target_dcache_alloc): New function.
Yao> (target_dcache_xfree): New function.
Yao> (target_dcache_get): New function.
Yao> (target_dcache_cleanup)): New function.
Yao> (target_dcache_invalidate): Update.
Yao> (memory_xfer_partial_1): Update.
Yao> (initialize_targets): Initialize target_dcache_aspace_key.
This is ok.
And, immediately contradicting myself, I think this is an improvement
regardless of whether the rest of the series goes in as-is or not.
That's because it removes a state-holding global in favor of a
parameterized approach. So, it would be fine by me if you wanted to
push in #1 and #2.
If you'd rather wait for the whole series to be done, that's also ok, as
it isn't urgent.
Yao> +
Yao> +static void
Yao> +target_dcache_cleanup (struct address_space *aspace, void *arg)
Yao> +{
This one needs a (short) intro comment.
Tom