[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: PowerPC assembler help



On Sun, Jun 09, 2013 at 10:03:14PM +1000, Erik de Castro Lopo wrote:
> Hi all,
> 
> Anyone know/understand PowerPC assembler?
> 
> I have the instruction:
> 
>     lwz     30, .label - (1b)(31)
> 
> >From reading the documentation I could find, I have figured out that
> it loads a 16 bit value into register 30. The rest has got me somewhat
> flumoxed. Clues?

I'm pretty sure that is loading a 32 bit value. I believe that 'h' is
for 16 bit and 'w' is 32 bit. I haven't seen that syntax for the source,
but my guess would be that it is an assembler directive of some sort
that will get translated into a memory reference of a register/offset,
but it seems like it would need to be PC-relative which that instruction
wouldn't support directly anyway.

Was this input for an assembler or output from a disassembler? If this
is from a disassembly of a dynamically relocatable object, it might
have gotten confused by an instruction being the target of a relocation.

	Brad Boyer
	flar@allandria.com


Reply to: