Displaying 20 results from an estimated 45 matches for "ptrregs".
Did you mean:
pt_regs
2017 May 28
2
Pseudo-instruction that overwrites its input register
..."ld _, P+" is an instruction that loads a single byte from P, and
post-increments P by one.
How can I represent this behaviour in LLVM? Currently, I have
let Constraints = "@earlyclobber $reg" in
def LDWRdPtr : Pseudo<(outs DREGS:$reg),
(ins PTRREGS:$ptrreg),
"ldw\t$reg, $ptrreg",
[(set i16:$reg, (load i16:$ptrreg))]>,
Requires<[HasSRAM]>;
The problem, of course, is that with this definition I end up with code
which assumes it is equivalent to save P befor...
2011 Mar 26
2
[LLVMdev] Possible missed optimization?
...****
entry:
16L %vreg0<def> = COPY %R25R24<kill>; DREGS:%vreg0
Considering merging %vreg0 with physreg %R25R24
RHS = %vreg0 = [16d,96d:0) 0 at 16d
LHS = %R25R24,inf = [0L,16d:0) 0 at 0L-phidef
updated: 96L %vreg8<def> = COPY %R25R24<kill>; PTRREGS:%vreg8
updated: 32L %vreg5<def> = COPY %R25R24; PTRREGS:%vreg5
Joined. Result = %R25R24,inf = [0L,96d:0) 0 at 0L-phidef
32L %vreg5<def> = COPY %R25R24; PTRREGS:%vreg5
Not coalescable.
64L %vreg6<def> = COPY %vreg4<kill>; DLDREGS:%vreg6,%vreg4
Co...
2011 Mar 26
2
[LLVMdev] Possible missed optimization?
..., thanks for the reply. The three regclasses involved here are
all subsets from each other and aren't disjoint. These are the basic
descriptions of the regclasses involved to show what i mean:
DREGS: R31R30, R29R28 down to R1R0 (16 regs)
DLDREGS: R31R30, R29R28 down to R17R16 (8 regs)
PTRREGS: R31R30, R29R28, R27R26 (3 regs)
All classes intersect each other giving as a result the smaller class:
DREGSxDLDREGS=DLDREGS / DLDREGSxPTRREGS=PTRREGS, etc. That's why i think the
coalescer should work since the regclasses overlap completely.
-------------- next part -------------...
2013 Apr 07
1
[LLVMdev] Pat operands matching example in ppc
On 7 April 2013 14:54, Sam Parker <S.Parker3 at lboro.ac.uk> wrote:
> Hi Anitha,
>
> memri is just describing that the address contains two components, an
> immediate and a register, and how to handle them in the instruction printer.
> The STWU expects a memri operand, and that is what is passed from the Pat.
>
My confusion is how operands of STWU from "Pat
2019 Mar 11
3
IsDead, IsKill
Thanks.
I saw the header comments but it wasn’t clear to me what the difference between those concepts is?
My slightly vague understanding is IsDef means that the register specified by this operand is set by the machine instruction. So I understand that to mean the MO will override that register?
Also things like early clobber, perhaps there is another document that clarifies some of these
2011 Mar 26
0
[LLVMdev] Possible missed optimization?
...ly. The three regclasses involved here are all subsets from each other and aren't disjoint. These are the basic descriptions of the regclasses involved to show what i mean:
>
> DREGS: R31R30, R29R28 down to R1R0 (16 regs)
> DLDREGS: R31R30, R29R28 down to R17R16 (8 regs)
> PTRREGS: R31R30, R29R28, R27R26 (3 regs)
>
> All classes intersect each other giving as a result the smaller class: DREGSxDLDREGS=DLDREGS / DLDREGSxPTRREGS=PTRREGS, etc. That's why i think the coalescer should work since the regclasses overlap completely.
Cross class coalescing also...
2013 Apr 07
2
[LLVMdev] Pat operands matching example in ppc
Hi,
How do "Pat" operands get matched? I am trying to follow the example given
in http://llvm.org/docs/CodeGenerator.html#selectiondag-process
In the latest trunk of ppcintrinfo.td following pattern is defined:
def : Pat<(pre_store i32:$rS, iPTR:$ptrreg, iaddroff:$ptroff),
(STWU $rS, iaddroff:$ptroff, $ptrreg)>;
I understand that input operand list i.e. ins of
2011 Mar 28
0
[LLVMdev] Possible missed optimization?
...vreg0<def> = COPY %R25R24<kill>; DREGS:%vreg0
> Considering merging %vreg0 with physreg %R25R24
> RHS = %vreg0 = [16d,96d:0) 0 at 16d
> LHS = %R25R24,inf = [0L,16d:0) 0 at 0L-phidef
> updated: 96L %vreg8<def> = COPY %R25R24<kill>; PTRREGS:%vreg8
> updated: 32L %vreg5<def> = COPY %R25R24; PTRREGS:%vreg5
> Joined. Result = %R25R24,inf = [0L,96d:0) 0 at 0L-phidef
> 32L %vreg5<def> = COPY %R25R24; PTRREGS:%vreg5
> Not coalescable.
> 64L %vreg6<def> = COPY %vreg4<kill>; DLD...
2013 Apr 07
0
[LLVMdev] Pat operands matching example in ppc
Hi Anitha,
memri is just describing that the address contains two components, an
immediate and a register, and how to handle them in the instruction
printer. The STWU expects a memri operand, and that is what is passed
from the Pat.
Hope that helps,
Sam
On 07/04/2013 10:19, Anitha B Gollamudi wrote:
> Hi,
>
>
> How do "Pat" operands get matched? I am trying to follow
2017 May 28
2
Pseudo-instruction that overwrites its input register
On Sun, 28 May 2017, David Chisnall wrote:
>> let Constraints = "@earlyclobber $reg" in
>> def LDWRdPtr : Pseudo<(outs DREGS:$reg),
>> (ins PTRREGS:$ptrreg),
>> "ldw\t$reg, $ptrreg",
>> [(set i16:$reg, (load i16:$ptrreg))]>,
>> Requires<[HasSRAM]>;
>>
>> The problem, of course, is that with this definition I end up with code which ass...
2015 Jan 31
0
[LLVMdev] Encoding instructions with inconsistent formats
I can't get it to work with pattern matching. My operand is defined like so:
def LDSTPtrReg : Operand<i16>
{
let MIOperandInfo = (ops PTRREGS);
let EncoderMethod = "encodeLDSTPtrReg";
}
I am able to use it in the place of PTRREGS in the definition of the LD
instruction, but if I use it in an instruction matching pattern,
compilation fails with the error "Unknown leaf kind:
LDSTPtrReg:i16:$ptrreg".
On Sun, Feb 1...
2016 Mar 14
2
Inline Spiller spilling multiple duplicate copies
Hi Ryan,
> On Mar 14, 2016, at 7:49 AM, Ryan Taylor via llvm-dev <llvm-dev at lists.llvm.org> wrote:
>
> I looked at this again and it appears that while spillAroundUses sets the register as 'dead', there is no checking to see if it's dead in subsequent iterations of the bundle loop.
>
> Is this intentional?
>
> On Mon, Mar 7, 2016 at 3:28 PM, Ryan
2015 Jan 31
3
[LLVMdev] Encoding instructions with inconsistent formats
I'm attempting to implement codegen support for the AVR ST/LD
<http://www.atmel.com/webdoc/avrassembler/avrassembler.wb_ST.html> family
of instructions.
The binary encoding is not particularly consistent -- take a look at this
table of variants of LD, along with their machine code representation:
# load 8 bits from pointer register X into general purpose Rd
ld Rd, X `1001 000d dddd
2011 Mar 25
2
[LLVMdev] Possible missed optimization?
...s for an out of tree backend im writing. I managed to reduce it
to the following C function:
void foo(int *a) // int here is 16bits
{
*a &= 0xFF;
}
This is the code before regalloc:
Live Ins: %R25R24
%vreg0<def> = COPY %R25R24; DREGS:%vreg0
%vreg2<def> = COPY %vreg0; PTRREGS:%vreg2 DREGS:%vreg0
%vreg1<def> = LDWRd %vreg2; mem:LD2[%a](align=1)(tbaa=!"int")
DLDREGS:%vreg1 PTRREGS:%vreg2
%vreg3<def> = ANDIWRdK %vreg1, 255; DLDREGS:%vreg3,%vreg1
%vreg5<def> = COPY %vreg0; PTRREGS:%vreg5 DREGS:%vreg0
STWRr %vreg5, %vreg3<kill&g...
2009 Jul 04
2
[LLVMdev] Help on DAG pattern matching string
Hello,
I'm new to LLVM and I'm using it to translate from LLVM to another
language rather than emitting actual machine code. The target language
has instructions that operate on pointers which aren't naturally exposed
in LLVM. Here's what I've done to add pointer support for an instruction
called PADD that takes a pointers and an offset and returns the new
pointer value:
2013 Oct 01
0
[LLVMdev] Post Increment Indirect Move Instructions
----- Original Message -----
> Hi Hal,
>
>
> Our Architecture has indirect move instruction which increments
> the
> pointer implicitly and the target only has i8 type values. So the
> load
> of i16 will be converted to two i8 target loads wherein after the
> first
> load instruction, the pointer to the first i8 address will
> automatically
>
2009 Jul 04
0
[LLVMdev] Help on DAG pattern matching string
Are there any other patterns in your TD file? If so, then one of the
ones before this pattern will match everything, and this pattern will
never be matched.
-bw
On Jul 3, 2009, at 8:27 PM, Javier Martinez wrote:
> Hello,
>
> I'm new to LLVM and I'm using it to translate from LLVM to another
> language rather than emitting actual machine code. The target language
> has
2013 Oct 08
1
[LLVMdev] Post Increment Indirect Move Instructions
Hi Hal,
On Tuesday 01 October 2013 06:22 PM, Hal Finkel wrote:
> ----- Original Message -----
>> Hi Hal,
>>
>>
>> Our Architecture has indirect move instruction which increments
>> the
>> pointer implicitly and the target only has i8 type values. So the
>> load
>> of i16 will be converted to two i8 target loads wherein after the
2013 Oct 01
2
[LLVMdev] Post Increment Indirect Move Instructions
Hi Hal,
Our Architecture has indirect move instruction which increments the
pointer implicitly and the target only has i8 type values. So the load
of i16 will be converted to two i8 target loads wherein after the first
load instruction, the pointer to the first i8 address will automatically
increment to point to the next i8 value. So the post increment nature is
in the Target. A normal
2004 Dec 02
3
[LLVMdev] Adding xadd instruction to X86
Hi,
I'm trying to add the xadd instruction to the X86 back end.
xadd r/m32, r32
exchanges r/m32 and r32, and loads the sum into r/m32. I'm
interested in the case where the destination operand is a
memory location.
I've added the following entry to X86InstrInfo.td:
def XADD32mr : I<0x87, MRMDestMem,
(ops i32mem:$src1, R32:$src2),
"xadd{l}