From: Peter Maydell <peter.maydell@linaro.org>
To: casmac <climber.cui@qq.com>
Cc: "Alex ,Bennée" <alex.bennee@linaro.org>,
qemu-devel <qemu-devel@nongnu.org>,
"Philippe Mathieu-Daudé" <f4bug@amsat.org>
Subject: Re: Why QEMU translates one instruction to a TB?
Date: Fri, 18 Sep 2020 10:39:23 +0100 [thread overview]
Message-ID: <CAFEAcA8m0xuWfibSD06Aw3TGC3BpiqNC7M-+RiVzJrfKSbtNLg@mail.gmail.com> (raw)
In-Reply-To: <tencent_6FBC0FD37CA798D4766FE6B2822DAC3E2908@qq.com>
On Fri, 18 Sep 2020 at 07:12, casmac <climber.cui@qq.com> wrote:
>
> Hello ,
> thanks for the hints. I modified one parameter of memory_region_init_ram() call ,and the slow-path problem disappeared.
> What I did is , change the RAM size from the exact memory size needed to hold the object file section(s), to the size that TI C3X user manual memory mapping specifies.
> The former size is significantly smaller. But I did not specify the memory mapping else where in the program, so still unsure about the cause of conflict.
>
> memory_region_init_ram(ary_sect_chain[i].mem_region, NULL, ary_sect_chain[i].s_name,
> /*ary_sect_chain[i].chain_size*4*/ ary_sect_chain[i].region_size, &error_fatal); //region_size is fixed as specified in CPU manual , region_size>chain_size*4
This still looks very strange. You shouldn't be creating
RAM memory regions in your COFF file loader at all. You create
the RAM memory regions for the board in the board model. Then
the file loader only needs to call rom_add_blob() or similar.
Look at the way we handle ELF files -- COFF loading should
work on a similar principle.
thanks
-- PMM
next prev parent reply other threads:[~2020-09-18 9:40 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <tencent_EAC696641F035EB7E9885302EAAE37455907@qq.com>
2020-09-17 7:38 ` Why QEMU translates one instruction to a TB? Philippe Mathieu-Daudé
2020-09-17 7:45 ` Philippe Mathieu-Daudé
[not found] ` <tencent_6FBC0FD37CA798D4766FE6B2822DAC3E2908@qq.com>
2020-09-18 9:39 ` Peter Maydell [this message]
2020-09-18 10:04 ` 回复: " Alex Bennée
2020-09-17 8:41 ` Alex Bennée
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAFEAcA8m0xuWfibSD06Aw3TGC3BpiqNC7M-+RiVzJrfKSbtNLg@mail.gmail.com \
--to=peter.maydell@linaro.org \
--cc=alex.bennee@linaro.org \
--cc=climber.cui@qq.com \
--cc=f4bug@amsat.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).