Re: [Qemu-devel] tracing guest memory access

2012-08-21 Thread Wei-Ren Chen
not see a relevant code in git master. This may be a little late, but yes, please cc to Lluís to ask him opinion. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http

Re: [Qemu-devel] Dump guest page table inside QEMU makes system hang

2012-08-21 Thread Wei-Ren Chen
); ... } --- The address of pde and pte should be (guest) physical address, right? If so, then target_ulong should be replaced with target_phys_addr_t. The other clue is the type of ldq_phys's parameter is target_phys_addr_t. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information

Re: [Qemu-devel] [PATCH] Fix copypaste typos in documentation comments

2012-08-21 Thread Wei-Ren Chen
if you make it align. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] qemu log function to print out the registers of the guest

2012-08-19 Thread Wei-Ren Chen
On Fri, Aug 17, 2012 at 03:57:55PM +0400, Max Filippov wrote: On Fri, Aug 17, 2012 at 3:14 PM, 陳韋任 (Wei-Ren Chen) che...@iis.sinica.edu.tw wrote: On Thu, Aug 16, 2012 at 7:49 PM, Steven wangwangk...@gmail.com wrote: [...] I want to get the guest memory address in the instruction mov

Re: [Qemu-devel] [PATCH] linux-user: fix emulation of getdents

2012-08-17 Thread Wei-Ren Chen
d_reclen; - chard_name[256]; /* We must not include limits.h! */ + chard_name[257];/* We must not include limits.h! */ + /* 257 = NAME_MAX + '\0' + d_type */ }; struct target_dirent64 { -- ldv -- Wei-Ren Chen (陳韋任

Re: [Qemu-devel] qemu log function to print out the registers of the guest

2012-08-17 Thread Wei-Ren Chen
? In other words, (guest) ebx might not be the value you saw here. This is just my opinion. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] qemu log function to print out the registers of the guest

2012-08-17 Thread Wei-Ren Chen
code in the code cache, perhaps modifying tcg_out_tlb_load to log value of addrlo (see comments above tcg_out_tlb_load). HTH, chenwj [1] http://lists.gnu.org/archive/html/qemu-devel/2012-08/msg03060.html -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica

Re: [Qemu-devel] How does ARM VFP is emulated?

2012-08-17 Thread Wei-Ren Chen
, something like float VFP_helper(float a, float b) { ... } But I am wrong, it acutally does this, right? float64 VFP_HELPER(sqrt, d)(float64 a, CPUARMState *env) { return float64_sqrt(a, env-vfp.fp_status); } And float64_sqrt is implemented in fpu/* . Regards, chenwj -- Wei-Ren Chen (陳韋任

Re: [Qemu-devel] Does Qemu simulate the softmmu for memory data access?

2012-08-16 Thread Wei-Ren Chen
, it'll call qemu_ld_helpers which are actually functions synthesized by macro in files softmmu_*.h. Note that what I am describing above is for QEMU system mode. Good luck! HTH, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel

Re: [Qemu-devel] qemu log function to print out the registers of the guest

2012-08-16 Thread Wei-Ren Chen
I would like to is there any function that could log the register content of the guest machine, like info registers in the qemu monitor mode. Why not check how info registes be implemented in QEMU? ;) I guess you just have to log env-regs or something like that. Regards, chenwj -- Wei-Ren

Re: [Qemu-devel] Is it possible to detect guest OS modifying pte inside QEMU?

2012-08-10 Thread Wei-Ren Chen
Hi Peter, On Wed, Aug 08, 2012 at 09:05:18AM +0100, Peter Maydell wrote: On 8 August 2012 08:38, 陳韋任 (Wei-Ren Chen) che...@iis.sinica.edu.tw wrote: Just for research, we are studying if we can leave the guest page table walk to underlying hardware rather than using software emulation

[Qemu-devel] Is it possible to detect guest OS modifying pte inside QEMU?

2012-08-08 Thread Wei-Ren Chen
still haven't find a good way to know when the guest OS is modifying guest page table entry. Any idea is welcomed. Thanks. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http

Re: [Qemu-devel] Is it possible to detect guest OS modifying pte inside QEMU?

2012-08-08 Thread Wei-Ren Chen
On Wed, Aug 08, 2012 at 09:05:18AM +0100, Peter Maydell wrote: On 8 August 2012 08:38, 陳韋任 (Wei-Ren Chen) che...@iis.sinica.edu.tw wrote: Just for research, we are studying if we can leave the guest page table walk to underlying hardware rather than using software emulation (like current

Re: [Qemu-devel] [PATCH 01/15] atomic: introduce atomic operations

2012-08-08 Thread Wei-Ren Chen
I propose we use gcc builtins. We get automatic architecture support, and tuning for newer processors if the user so chooses. http://gcc.gnu.org/onlinedocs/gcc-4.1.2/gcc/Atomic-Builtins.html In May 2031 we can switch to C11 atomics. Maybe 2013? -- Wei-Ren Chen (陳韋任

Re: [Qemu-devel] Is it possible to detect guest OS modifying pte inside QEMU?

2012-08-08 Thread Wei-Ren Chen
a little bit about what notdirty and watch_mem does? Googleing doesn't help much... Thanks! Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] Synchronize issue and lost character when using serial as pipe type

2012-07-24 Thread Wei-Ren Chen
is my info. QEMU 0.10 is really old. Have you ever considered using current release? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] [PATCH] qemu: add .exrc

2012-07-20 Thread Wei-Ren Chen
In any case, 3 settings clearly don't encompass the whole of QEMU's coding style. The relevant bit of my .emacs tweaks about 20 different settings... Just leave the coding style checking to checkpatch.pl, I think? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute

Re: [Qemu-devel] Can't Build i386-bsd-user on Freebsd

2012-07-18 Thread Wei-Ren Chen
it . -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

[Qemu-devel] How IO emulation is done in QEMU?

2012-07-17 Thread Wei-Ren Chen
should I start counting. Thanks. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] [PATCH] Get tests/tcg building, fix unused variable warning due to wrong extended asm operand, fix the 'test' make target.

2012-07-13 Thread Wei-Ren Chen
Tested-by: Wei-Ren Chen On Fri, Jul 13, 2012 at 02:55:13AM -0400, Catalin Patulea wrote: Not all tests pass, but at least they can be run using 'make test'. To build individual tests: $ cd $BUILD_PATH/tests/tcg $ SRC_PATH=path/to/qemu make target [snip] Regards, chenwj -- Wei-Ren

Re: [Qemu-devel] [PATCH 1/5] Avoid GCC extension ?:

2012-07-11 Thread Wei-Ren Chen
supports the ?: gcc extension this patch doesn't move us any further in that direction. Let's get AVOID_PASS_ARGV0 patch done. ;) Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage

Re: [Qemu-devel] qemu softmmu inlined lookup sequence

2012-07-11 Thread Wei-Ren Chen
. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] KVM VMenter/exit cost

2012-07-07 Thread Wei-Ren Chen
/139/ The cost is quite high, ~800 cycles. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] [RFC][PATCH v2 1/4] tcg: add declarations and templates of extended MMU helpers

2012-07-06 Thread Wei-Ren Chen
Also, please line wrap your commit messages. I didn't know the line wrap rule of commit message. Is the rule included in checkpatch.pl? Let me check it. I guess it's 80 char length rule? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science

Re: [Qemu-devel] [PATCH 2/7 v6] update linux headers

2012-07-06 Thread Wei-Ren Chen
, 8aca521512a14c439624191bd0a891c52f91b401 Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] [RFC][PATCH 0/4] tcg: enhance code generation quality for qemu_ld/st IRs

2012-07-04 Thread Wei-Ren Chen
to review your patch before. :-) Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] [PATCH] add text about how to use qemu-nbd with qemu

2012-07-03 Thread Wei-Ren Chen
before. Should be For example? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] Using qemu to profile ARM binaries

2012-07-01 Thread Wei-Ren Chen
folder/file(s) in the source code where I can add code for profiling? target-arm/* would be the place since you're running ARM binary, tcg/ARCH/* could be another place depends on what machine you're running QEMU on. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute

Re: [Qemu-devel] [PATCH v7 11/16] target-or32: Add a IIS dummy board

2012-06-28 Thread Wei-Ren Chen
/* OpenRISC pic handler */ static void openrisc_pic_cpu_handler(void *opaque, int irq, int level) { OpenRISCCPU *cpu = (OpenRISCCPU *)opaque; ^^ Do we need casting before assigning opaque to cpu? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer

Re: [Qemu-devel] Fwd: qemu as dynamic binary translation infrastructure

2012-06-27 Thread Wei-Ren Chen
Bluestacks uses to run ARM apps. Perform a binary analysis, and you will see it is in fact Qemu. That might give you a hint. ;) Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http

Re: [Qemu-devel] [PATCH v6 08/16] target-or32: Add instruction tanslation

2012-06-26 Thread Wei-Ren Chen
-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] qemu as dynamic binary translation infrastructure

2012-06-26 Thread Wei-Ren Chen
Hi Liu, You might find this thread interesting, http://lists.gnu.org/archive/html/qemu-devel/2012-06/msg04351.html Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http

Re: [Qemu-devel] [PATCHv3 02/14] unicore32-softmmu: Add coprocessor 0(sysctrl) and 1(ocd) instruction support

2012-06-25 Thread Wei-Ren Chen
not be trusted (like cloud computing), but who knows the future? Is it proper to print such information to monitor? by using monitor_printf(). What if user doesn't open a monitor? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica

Re: [Qemu-devel] [PATCH] linux-user: fix segmentation fault passing with g2h(x) != x

2012-06-25 Thread Wei-Ren Chen
of the (usually 32-bit truncated) address. Passing in g2h(address) makes the guest process a lot happier. Passing g2h or h2g? From the context and code, I think h2g should make more sense. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute

Re: [Qemu-devel] nested page table translation for non-x86 operating system

2012-06-22 Thread Wei-Ren Chen
? When guest VM (with KVM enabled) fetch instructions from its memory, does it also have the same issue? Regards, chenwj [1] http://www.mail-archive.com/qemu-devel@nongnu.org/msg117254.html -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan

Re: [Qemu-devel] [PATCH v6 11/16] target-or32: Add a IIS dummy board

2012-06-21 Thread Wei-Ren Chen
+ * OpenRISC simulator for use as an ISS. ^^^ Shoudld be IIS? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http

Re: [Qemu-devel] [PATCH 2/2] kvm: use per-cpu lock to free vcpu thread out of the big lock

2012-06-21 Thread Wei-Ren Chen
-- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] [PATCH 6/7] Exit loop if we have been there too long

2012-06-21 Thread Wei-Ren Chen
THRESHOLD 50 if (t1 THRESHOLD) { ... } Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] [PATCH v5 00/16] QEMU OpenRISC support

2012-06-21 Thread Wei-Ren Chen
that is confusing it, but yes, just ignore the error. Should this be added to http://wiki.qemu.org/Contribute/SubmitAPatch as an example? I remember someone else had the same problem before. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia

Re: [Qemu-devel] How to measure guest memory access (qemu_ld/qemu_st) time?

2012-06-20 Thread Wei-Ren Chen
CC'ed to the mailing list. -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj ---BeginMessage--- On 06/19/2012 11:49 AM, 陳韋任 (Wei-Ren Chen) wrote: Mind me CC

Re: [Qemu-devel] Any better way to access CPUArchState in vl.c?

2012-06-20 Thread Wei-Ren Chen
On Tue, Jun 19, 2012 at 01:08:47PM +0100, Peter Maydell wrote: On 19 June 2012 12:54, 陳韋任 (Wei-Ren Chen) che...@iis.sinica.edu.tw wrote: If you only have one CPU then using first_cpu-some_field1 should be almost as easy. :)  I am afraid first_cpu (CPUArchState) is got poisoned, too

Re: [Qemu-devel] [PATCHv3 02/14] unicore32-softmmu: Add coprocessor 0(sysctrl) and 1(ocd) instruction support

2012-06-20 Thread Wei-Ren Chen
Does this pass scripts/checkpatch.pl? These should become if (cop != 0) { goto unrecognized; } Thanks for pointing it out, and sorry for that. I will correct it in next version. You can run scripts/checkpatch.pl before you submit the patch. Regards, chenwj -- Wei-Ren Chen (陳韋任

Re: [Qemu-devel] How to measure guest memory access (qemu_ld/qemu_st) time?

2012-06-19 Thread Wei-Ren Chen
into the TLB (IIUC). I don't see much differences here. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] Any better way to access CPUArchState in vl.c?

2012-06-19 Thread Wei-Ren Chen
-some_field1 // print env-some_field2 } --- If we can access env in vl.c directly, it would make the task easier. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http

Re: [Qemu-devel] Any better way to access CPUArchState in vl.c?

2012-06-19 Thread Wei-Ren Chen
use in this function) --- Any thought on what I am missing? Thanks. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] How to measure guest memory access (qemu_ld/qemu_st) time?

2012-06-18 Thread Wei-Ren Chen
: call MMU helper (6) ... (next code) Do you mean we directly call MMU helper ing step 2? Regards, chenwj [1] http://www.mail-archive.com/qemu-devel@nongnu.org/msg91294.html -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886

Re: [Qemu-devel] [PATCHv2 00/13] unicore32: add softmmu support and puv3 machine

2012-06-18 Thread Wei-Ren Chen
Yes. But how to do that. I can't find the upload location or someone who receives the image. Perhaps someone can open a wiki account for you, so that you can upload an image. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica

[Qemu-devel] Any better way to access CPUArchState in vl.c?

2012-06-18 Thread Wei-Ren Chen
; but it's not very convenient if we have many field of CPUState want to access. Is there a better way to do so? Thanks! Regards, chenwj [1] http://stackoverflow.com/questions/9461625/gcc-error-message-attempt-to-use-poisoned-target-i386 -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute

Re: [Qemu-devel] How to measure guest memory access (qemu_ld/qemu_st) time?

2012-06-18 Thread Wei-Ren Chen
-- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] [PATCH 1/2] Add usb option in machine options to enable/disable usb

2012-06-18 Thread Wei-Ren Chen
Hi Li Zhang, Perhaps you miss [PATCH v3 1/2] in the subject? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] How to management KVM virtual machines via libvirt?

2012-06-16 Thread Wei-Ren Chen
this go to libvirt mailing list? http://libvirt.org/contact.html Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] [PATCHv2 05/13] unicore32-softmmu: Make sure that kernel can access user space

2012-06-15 Thread Wei-Ren Chen
void do_ldst_ir(CPUUniCore32State *env, DisasContext *s, uint32_t insn) { -unsigned int i; +unsigned int mmuindex; I would suggest you to rename it to mmu_idx or something like that. :) Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab

Re: [Qemu-devel] [PATCHv2 00/13] unicore32: add softmmu support and puv3 machine

2012-06-15 Thread Wei-Ren Chen
linux kernel boot and busybox run in initramfs. Do you plan put disk image on http://wiki.qemu.org/Testing ? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http

[Qemu-devel] Does kvm_fd mean KVM or VCPU fd?

2012-06-14 Thread Wei-Ren Chen
fd? */ } --- I think KVM_CREATE_VCPU should return VCPU fd, right? AFAIK, in KVM world, kvm_fd usually means the fd we get after opening /dev/kvm. Just want to make sure I understand the code correcly. Thanks. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information

Re: [Qemu-devel] Does kvm_fd mean KVM or VCPU fd?

2012-06-14 Thread Wei-Ren Chen
. Don't know rename it or add a comment to indicate it's a VCPU fd is a good idea. ;) Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] How to measure guest memory access (qemu_ld/qemu_st) time?

2012-06-13 Thread Wei-Ren Chen
On Wed, Jun 13, 2012 at 12:43:28PM +0200, Laurent Desnogues wrote: On Wed, Jun 13, 2012 at 5:14 AM, 陳韋任 (Wei-Ren Chen) che...@iis.sinica.edu.tw wrote: Hi all,  I suspect that guest memory access (qemu_ld/qemu_st) account for the major of time spent in system mode. I would like to know

Re: [Qemu-devel] How to measure guest memory access (qemu_ld/qemu_st) time?

2012-06-13 Thread Wei-Ren Chen
Unfortunately, I had the bad idea of rebasing all my series on top of the latest makefile changes, and I'll have to go through each patch to check it's still working (I'm sure some of them broke). Need some help? :) Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute

Re: [Qemu-devel] How to measure guest memory access (qemu_ld/qemu_st) time?

2012-06-13 Thread Wei-Ren Chen
the others? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

[Qemu-devel] How to measure guest memory access (qemu_ld/qemu_st) time?

2012-06-12 Thread Wei-Ren Chen
/tcg-target.c? Or there is a better way to know how much time QEMU spend on handling guest memory access? Any suggestion/comment is welcomed. Thanks! Regards, chenwj [1] https://perf.wiki.kernel.org/index.php/Main_Page -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science

Re: [Qemu-devel] QEMU translation flags

2012-06-11 Thread Wei-Ren Chen
|| tb-flags != flags)) { tb = tb_find_slow(env, pc, cs_base, flags); } --- If current flags (flags) is not match the flags while translating the tb (tb-flags), then the translated tb will be discarded. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute

Re: [Qemu-devel] [Bug 1011142] [NEW] Arm emulation do a crash

2012-06-11 Thread Wei-Ren Chen
I don't know why, with kvm it say: KVM not supported for this target No accelerator found! Unless you're running on ARM with a patched kernel you can't get KVM for ARM guests. That's no error. Linux/ARM starts to support kvm? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems

Re: [Qemu-devel] [PATCH v3 08/16] target-or32: Add translation routines

2012-06-07 Thread Wei-Ren Chen
exceptions via an out-of-line handler. ^^^ I guess you mean helper function? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] Any approach to log the file read/write (I/O data flow) like the -d in_asm option?

2012-06-06 Thread Wei-Ren Chen
(register state), shadow memory(from?pmemsave) and shadow .img file (disk). Why doesn't the savevm command provide the snapshotting you need? It sounds like you're trying to do VM snapshots yourself. Does `savevm` and reply do the same thing? :) Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer

Re: [Qemu-devel] tcg_qemu_tb_exec...

2012-06-04 Thread Wei-Ren Chen
://en.wikipedia.org/wiki/Function_prologue -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] general question

2012-05-31 Thread Wei-Ren Chen
on QEMU flush the entire tlb. So it could flush particular tlb entry in tlb_flush_entry? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] [PATCH qom-next 57/59] cpu: Introduce mandatory tlb_flush callback

2012-05-30 Thread Wei-Ren Chen
On Wed, May 30, 2012 at 09:53:20AM +0200, Alexander Graf wrote: Mind to elaborate (in the patch description maybe) why we need a CPU specific TLB flush callback that merely calls the globally visible tlb_flush? :) For future extension? ;) Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer

Re: [Qemu-devel] general question

2012-05-30 Thread Wei-Ren Chen
helper_invlpg function in the target-i386/op_helper.c to see how it is implemented. FWIW. Currently, QEMU just flush the entire tlb (env-tlb_table). Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667

Re: [Qemu-devel] Lack of codes in logging

2012-05-29 Thread Wei-Ren Chen
On Tue, May 29, 2012 at 12:25:51AM -0400, Yue Chen wrote: Do you know how to use that? When I use log(-d) exec and log(-d) pcall, the qemu.log is always empty. `qemu -d in_asm,exec` will do. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science

Re: [Qemu-devel] nested page table translation for non-x86 operating system

2012-05-29 Thread Wei-Ren Chen
the guest CR3, we need to trap into the kernel as kvm does. I read stuff about Intel NPT again. Is gCR3 a field of VMCS, then loaded into CR3 at runtime? Thanks! Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2

Re: [Qemu-devel] Android Goldfish on QEMU

2012-05-29 Thread Wei-Ren Chen
. And a much sweeter one (KVM makes it pretty fast :) ). Running it in QEMU/KVM? If we want to run a ARM image, we can't use KVM, right? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage

Re: [Qemu-devel] [PATCH 1/1 v5] Allow machines to configure the QEMU_VERSION that's exposed via hardware

2012-05-29 Thread Wei-Ren Chen
not available anymore. User document now is hosted on http://qemu.weilnetz.de/qemu-doc.html;. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 Homepage: http://people.cs.nctu.edu.tw/~chenwj

Re: [Qemu-devel] [PATCH 1/1 v5] Allow machines to configure the QEMU_VERSION that's exposed via hardware

2012-05-29 Thread Wei-Ren Chen
On Wed, May 30, 2012 at 04:54:26AM +0100, Peter Maydell wrote: On 30 May 2012 04:51, 陳韋任 (Wei-Ren Chen) che...@iis.sinica.edu.tw wrote: diff --git a/hw/bt-sdp.c b/hw/bt-sdp.c index 3e390ab..c0431d1 100644 --- a/hw/bt-sdp.c +++ b/hw/bt-sdp.c @@ -834,7 +834,7 @@ SERVICE(hid

[Qemu-devel] [Bug 996303] Re: does not work with clang

2012-05-09 Thread Wei-Ren Chen
O.K., the first thing you need to know is llvm-gcc uses GCC as it's frontend to parse your source code, and uses LLVM as it's backend to generate binary. In order to support global register correctly, not only the frontend has to be able to recognize the global register syntax, but also the LLVM

[Qemu-devel] [Bug 996303] Re: does not work with clang

2012-05-09 Thread Wei-Ren Chen
You can try to configure QEMU to use TCI (interpreter) rather then TCG (jitter). IIRC, TCI doesn't use global register. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/996303 Title: does not work

[Qemu-devel] [Bug 996303] Re: does not work with clang

2012-05-09 Thread Wei-Ren Chen
`../qemu/configure --enable-tcg-interpreter` will use TCI not TCG. You can use `configure --help` to see what options it provides. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/996303 Title: does

[Qemu-devel] [Bug 996303] Re: does not work with clang

2012-05-09 Thread Wei-Ren Chen
You can send launchpad a bug report talking about this. ;-) -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/996303 Title: does not work with clang Status in QEMU: New Bug description: Frozen

[Qemu-devel] [Bug 996303] Re: does not work with clang

2012-05-09 Thread Wei-Ren Chen
So O.K. to close? :-) -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/996303 Title: does not work with clang Status in QEMU: New Bug description: Frozen on start. CPU: dual-core 64-bit

[Qemu-devel] [Bug 996303] Re: does not work with clang

2012-05-08 Thread Wei-Ren Chen
IIRC, clang doesn't support global register yet. Do you configure QEMU to use TCI? What's the version of Clang and QEMU you're using? -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/996303 Title:

<    1   2