* powerpc simulator instruction question
@ 2006-11-17 19:53 Joel Sherrill
2006-11-17 19:57 ` Daniel Jacobowitz
0 siblings, 1 reply; 6+ messages in thread
From: Joel Sherrill @ 2006-11-17 19:53 UTC (permalink / raw)
To: gdb; +Cc: Ralf Corsepius
Hi,
Version: gdb 6.5 with ppc simulator enabled.
I have an RTEMS program which seems to have the FPU
enabled OK since it executes the instructions at
0x9a0, 0x9ac, and 0x9b0. But it gets an exception
0x0700 at 0x9b4.
9a0: fd 8c 00 32 fmul f12,f12,f0
9a4: c0 09 0c e0 lfs f0,3296(r9)
9a8: 39 21 00 48 addi r9,r1,72
9ac: fd 8c 00 32 fmul f12,f12,f0
9b0: fd a0 60 1e fctiwz f13,f12
9b4: 7d a0 4f ae stfiwx f13,0,r9
The device tree file is:
#address-cells 2
/openprom/init/register/pvr 0xfffe0000
/openprom/options/oea-memory-size 8388608
The code in question was compiled with -mcpu=603e.
I have tried starting the simulator with no model
argument (tar sim...), 603e (-m 603e) and 603 without
any difference.
The stfiwx was generated by gcc.
Is the stfiwx not implemented in the simulator? Not valid?
Any suggestions, patches?
I can provide the executable in question if it helps
someone.
Thanks.
--joel sherrill
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: powerpc simulator instruction question 2006-11-17 19:53 powerpc simulator instruction question Joel Sherrill @ 2006-11-17 19:57 ` Daniel Jacobowitz 2006-11-17 20:08 ` Joel Sherrill 0 siblings, 1 reply; 6+ messages in thread From: Daniel Jacobowitz @ 2006-11-17 19:57 UTC (permalink / raw) To: Joel Sherrill; +Cc: gdb, Ralf Corsepius On Fri, Nov 17, 2006 at 01:53:27PM -0600, Joel Sherrill wrote: > Is the stfiwx not implemented in the simulator? Not valid? Looks unimplemented. GCC didn't generate it until 2005. -- Daniel Jacobowitz CodeSourcery ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: powerpc simulator instruction question 2006-11-17 19:57 ` Daniel Jacobowitz @ 2006-11-17 20:08 ` Joel Sherrill 2006-11-17 20:11 ` Daniel Jacobowitz 2006-11-19 20:37 ` Frank Ch. Eigler 0 siblings, 2 replies; 6+ messages in thread From: Joel Sherrill @ 2006-11-17 20:08 UTC (permalink / raw) To: Joel Sherrill, gdb, Ralf Corsepius Daniel Jacobowitz wrote: > On Fri, Nov 17, 2006 at 01:53:27PM -0600, Joel Sherrill wrote: > >> Is the stfiwx not implemented in the simulator? Not valid? >> > > Looks unimplemented. GCC didn't generate it until 2005. > > I found some posts that indicate qemu only got a patch for it in Oct 2006. :) I have no idea how to read, modify, or use ppc-instructions to add it. How can I find the instruction in there? How can I map that back to the 603e manual? This is pretty deep in the bowels of something and quite picky. :( Is there any PPC expert willing to take a stab at it? --joel ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: powerpc simulator instruction question 2006-11-17 20:08 ` Joel Sherrill @ 2006-11-17 20:11 ` Daniel Jacobowitz 2006-11-17 20:45 ` Joel Sherrill 2006-11-19 20:37 ` Frank Ch. Eigler 1 sibling, 1 reply; 6+ messages in thread From: Daniel Jacobowitz @ 2006-11-17 20:11 UTC (permalink / raw) To: Joel Sherrill; +Cc: gdb, Ralf Corsepius On Fri, Nov 17, 2006 at 02:08:37PM -0600, Joel Sherrill wrote: > Is there any PPC expert willing to take a stab at it? I don't think that there are any recently active developers who know the first thing about psim. -- Daniel Jacobowitz CodeSourcery ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: powerpc simulator instruction question 2006-11-17 20:11 ` Daniel Jacobowitz @ 2006-11-17 20:45 ` Joel Sherrill 0 siblings, 0 replies; 6+ messages in thread From: Joel Sherrill @ 2006-11-17 20:45 UTC (permalink / raw) To: Joel Sherrill, gdb, Ralf Corsepius Daniel Jacobowitz wrote: > On Fri, Nov 17, 2006 at 02:08:37PM -0600, Joel Sherrill wrote: > >> Is there any PPC expert willing to take a stab at it? >> > > I don't think that there are any recently active developers who > know the first thing about psim. > > Looking at the ChangeLog, I got the impression there were not many people comfortable with serious changes. :( --joel ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: powerpc simulator instruction question 2006-11-17 20:08 ` Joel Sherrill 2006-11-17 20:11 ` Daniel Jacobowitz @ 2006-11-19 20:37 ` Frank Ch. Eigler 1 sibling, 0 replies; 6+ messages in thread From: Frank Ch. Eigler @ 2006-11-19 20:37 UTC (permalink / raw) To: Joel Sherrill; +Cc: gdb, Ralf Corsepius Joel Sherrill <joel.sherrill@oarcorp.com> writes: > >> Is the stfiwx not implemented in the simulator? Not valid? > > Looks unimplemented. GCC didn't generate it until 2005. > I have no idea how to read, modify, or use ppc-instructions > to add it. How can I find the instruction in there? The individual instruction patterns are the lines looking like "0.31,....". The parts before the colons describe the instruction encoding, breaking down the bits into operand fields and opcode numbers. For example: 0.31,6.RT,11./,16./,21.83,31./:X:::Move From Machine State Register means: bits 0..5 contain the value 31 6..10 contain the field "RT" (use the expression *rT in the body) 11..15 contain a don't care field 16..20 likewise 21..30 contains the value 83 31 contains a don't care field *601: PPC_UNIT_IU, PPC_UNIT_IU, 1, 1, 0 *603: PPC_UNIT_SRU, PPC_UNIT_SRU, 1, 1, 0 *603e:PPC_UNIT_SRU, PPC_UNIT_SRU, 1, 1, 0 *604: PPC_UNIT_MCIU, PPC_UNIT_MCIU, 3, 3, 0 These are functional unit utilization/performance numbers. if (IS_PROBLEM_STATE(processor)) program_interrupt(processor, cia, privileged_instruction_program_interrupt); else { *rT = MSR; check_masked_interrupts(processor); } This code actually implements the instruction. - FChE ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2006-11-19 20:37 UTC | newest] Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2006-11-17 19:53 powerpc simulator instruction question Joel Sherrill 2006-11-17 19:57 ` Daniel Jacobowitz 2006-11-17 20:08 ` Joel Sherrill 2006-11-17 20:11 ` Daniel Jacobowitz 2006-11-17 20:45 ` Joel Sherrill 2006-11-19 20:37 ` Frank Ch. Eigler
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox