From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23068 invoked by alias); 3 Nov 2013 05:57:49 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 23001 invoked by uid 89); 3 Nov 2013 05:57:48 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.5 required=5.0 tests=AWL,BAYES_00,FROM_12LTRDOM,RDNS_NONE,URIBL_BLOCKED autolearn=no version=3.3.2 X-HELO: relay1.mentorg.com Received: from Unknown (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sun, 03 Nov 2013 05:57:04 +0000 Received: from svr-orw-exc-10.mgc.mentorg.com ([147.34.98.58]) by relay1.mentorg.com with esmtp id 1Vcqez-000209-T0 from Yao_Qi@mentor.com for gdb-patches@sourceware.org; Sat, 02 Nov 2013 22:55:41 -0700 Received: from SVR-ORW-FEM-02.mgc.mentorg.com ([147.34.96.206]) by SVR-ORW-EXC-10.mgc.mentorg.com with Microsoft SMTPSVC(6.0.3790.4675); Sat, 2 Nov 2013 22:55:42 -0700 Received: from qiyao.dyndns.org (147.34.91.1) by svr-orw-fem-02.mgc.mentorg.com (147.34.96.168) with Microsoft SMTP Server id 14.2.247.3; Sat, 2 Nov 2013 22:55:40 -0700 From: Yao Qi To: Subject: [PATCH 00/10 V2] Cache code access for disassemble Date: Sun, 03 Nov 2013 05:57:00 -0000 Message-ID: <1383458049-20893-1-git-send-email-yao@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain X-IsSubscribed: yes X-SW-Source: 2013-11/txt/msg00040.txt.bz2 Hi, This is the V2 of this patch series. In the discussion of V1, the major comments are: 1. dcache.c and target_dcache needs some cleanups and factor. 2. commands "set dcache size" and "set dcahce line-size" needs a description on semantics when dcache is per-address_space. 3. Use a single global 'target_dcache' for both stack caching and code caching. 4. Replace "executable code" with "code segment" in doc and NEWS. V2 addresses these comments as follows: Patch #1 ~ #4 are about cleanups and factors to dcache.c and target_dcache. Patch #5 is a minor optimization to target_dcache. Patch #6 and #7 change target_dcache to per-address_space mode, and update doc on dcache-related commands. We decide to use single 'target_dcache' for caching different types of access, so cache invalidation caused by option "stack-cache" changes makes troubles. Think a little, I find we don't have to invalidate target_dcache when option "stack-cache" is changed. This is what patch #8 does, and looks change in patch #8 doesn't affect the semantics of option "set stack-cache". Patch #9 adds command "set code-cache", similar to "set stack-cache", and patch #10 is to use TARGET_OBJECT_CODE_MEMORY to read for disassembly. Patch 4, 5, 7, and 9 need doc review. Each patch is regression tested on x86_64-linux. *** BLURB HERE *** Yao Qi (10): Remove last_cache Don't update target_dcache if it is not initialized Move target-dcache out of target.c Don't stress 'remote' in "Data Caching" in doc Invalidate or shrink dcache when setting is changed. Add REGISTRY for struct address_space. Associate target_dcache to address_space. Don't invalidate dcache when option stack-cache is changed set/show code-cache Use target_read_code in disassemble. gdb/Makefile.in | 6 +- gdb/NEWS | 6 ++ gdb/dcache.c | 93 ++++++++++++++++++--------- gdb/dcache.h | 4 + gdb/disasm.c | 2 +- gdb/doc/gdb.texinfo | 52 ++++++++++----- gdb/memattr.c | 1 + gdb/progspace.c | 14 ++--- gdb/progspace.h | 19 +++++- gdb/target-dcache.c | 175 +++++++++++++++++++++++++++++++++++++++++++++++++++ gdb/target-dcache.h | 30 +++++++++ gdb/target.c | 94 +++++++++------------------- gdb/target.h | 9 ++- gdb/top.c | 1 + gdb/tracepoint.c | 1 + 15 files changed, 379 insertions(+), 128 deletions(-) create mode 100644 gdb/target-dcache.c create mode 100644 gdb/target-dcache.h -- 1.7.7.6