Displaying 20 results from an estimated 10000 matches similar to: "[LLVMdev] optimizing references within a struct"
2013 Feb 08
0
[LLVMdev] optimizing references within a struct
This sounds similar to what the LocalStackSlotAllocation pass does (lib/CodeGen/LocalStackSlotAllocation.cpp).
-Jim
On Feb 7, 2013, at 4:56 PM, reed kotler <rkotler at mips.com> wrote:
> There is an optimization which the Greenhills compiler does for mips16.
>
> I have not looked at it myself ,but it was recounted to me.
>
> The basic idea is that if you have a large
2013 Feb 08
1
[LLVMdev] optimizing references within a struct
On 02/07/2013 05:28 PM, Jim Grosbach wrote:
> This sounds similar to what the LocalStackSlotAllocation pass does (lib/CodeGen/LocalStackSlotAllocation.cpp).
>
> -Jim
exactly but this is for structs but maybe you are saying that i can
reuse those ideas for structs.
i'm going to turn on the localstackallocation soon . maybe i need to
study that and write
something similar for plain
2013 Mar 27
2
[LLVMdev] LLVM pass question
What I am thinking of now is to just register the MIPS116 and MIPS32
DAGToDAGISel passes and then within run on machine function, I can just
return if the current mode indicates that mips16 is needed for example,
so the run on machine function for Mips32 would return immediately.
On 03/27/2013 10:05 AM, Reed Kotler wrote:
> I guess another way to do this is to just register both passes for
2013 Mar 27
1
[LLVMdev] LLVM pass question
So the switching between mips16 and mips32 on a per function basis seems
to basically be working except that asm printer has some kind of
issue here.
I'm debugging that now.
I get this:
lc: /home/rkotler/workspace/llvmpb6/include/llvm/MC/MCStreamer.h:224:
void llvm::MCStreamer::SwitchSection(const llvm::MCSection*): Assertion
`Section && "Cannot switch to a null
2013 Mar 27
0
[LLVMdev] LLVM pass question
This seems to work okay.
I register both the Mips16 and non Mips16 passes of the instruction
selector and then those return false if they are not supposed to be running.
Make-check at least passes in this case.
So in principle turn on the dual mode now and debug whatever misc is left.
For this I insert another pass before the mips16 and non mips16 passes.
On 03/27/2013 10:19 AM, Reed Kotler
2013 Feb 06
2
[LLVMdev] register scavenging
So what I realized is that you can't use the simple scavenger trick
where you create the virtual register and use the more advanced features.
This is because you can't call forward() in any form if there are
virtual registers being used by any of the instructions in the basic
block. This will cause forward to fail.
Maybe this is a bug in forward()
On 02/05/2013 02:51 PM, Reed Kotler
2013 Jan 11
2
[LLVMdev] adding IR attributes to llvm
Yes, you could have mips16 and fastcc.
Mips16 just means that processor mode to execute that function is "mips16".
So in a mips16 designated function, I will just emit mips16 instructions
and in a "nomips16"
function, just emit normal mips32 instructions.
I tend to call this "mips32" normal mode, "standard encoding" because in
reality the processor is
2013 Mar 27
2
[LLVMdev] LLVM pass question
I'm implementing this ability to switch between mips16 and mips32 on a
per function basis.
One issue that I've run into is regarding the DAGToDAGIsel pass.
We have a different subclass for mips16 and non mips16 ( conceivably
later there could be a separate one for micromips).
I need to run a different pass depending on whether it's mips16 or mips32.
My initial plan was to create
2012 May 14
0
[LLVMdev] getMinimalPhysRegClass
Reed,
On May 14, 2012, at 3:45 PM, reed kotler <rkotler at mips.com> wrote:
> On 05/14/2012 02:42 PM, Jakob Stoklund Olesen wrote:
>> On May 14, 2012, at 2:28 PM, reed kotler wrote:
>>
>>> I'm not using getMinimalPhysRegClass. Some target independent code is using it.
>> Probably PEI.
>>
>>> It makes trouble for us and I would like to
2012 May 14
3
[LLVMdev] getMinimalPhysRegClass
On 05/14/2012 02:42 PM, Jakob Stoklund Olesen wrote:
> On May 14, 2012, at 2:28 PM, reed kotler wrote:
>
>> I'm not using getMinimalPhysRegClass. Some target independent code is using it.
> Probably PEI.
>
>> It makes trouble for us and I would like to submit a patch to make it a virtual function so that I can override it and make it meaningful for Mips, as long as this
2013 Jan 11
0
[LLVMdev] adding IR attributes to llvm
I think that Bill Wendlings new attribute implementation would allow me
to do this but it is not ready yet.
Maybe it's okay to just add them to the list of function attributes as I
suggested.
But in the end, someone has to approve the checkin.
On 01/11/2013 07:35 AM, Reed Kotler wrote:
> Yes, you could have mips16 and fastcc.
>
> Mips16 just means that processor mode to execute
2013 Feb 06
0
[LLVMdev] register scavenging
No. forward() is working correctly. All virtual register references must be resolved before calling it.
-Jim
On Feb 5, 2013, at 4:05 PM, Reed Kotler <rkotler at mips.com> wrote:
> So what I realized is that you can't use the simple scavenger trick where you create the virtual register and use the more advanced features.
>
> This is because you can't call forward() in any
2012 Nov 03
1
[LLVMdev] symbols for exception handling
I thought of a simpler way to do this which is no more of a hack than
the way labels are noramally output.
Create an EmitDebugLabel and then in MCAsminfo, add another variable for
the suffix for debug labels which can by default be just ":". Then for
Mips I can change it to "=."
On 11/03/2012 01:40 PM, Reed Kotler wrote:
> I'm working on a patch for this problem
2013 Mar 27
0
[LLVMdev] LLVM pass question
I guess another way to do this is to just register both passes for
mips16 and mips32 and have them return immediately if it is not their
turn to run.
On 03/27/2013 08:58 AM, Reed Kotler wrote:
> I'm implementing this ability to switch between mips16 and mips32 on a
> per function basis.
>
> One issue that I've run into is regarding the DAGToDAGIsel pass.
>
> We have a
2013 Jan 20
2
[LLVMdev] soft float signature problem
I'm implementing this unusual gcc form of mips16 hard float.
I ran into one unexpected wrinkle. It effects efficiency as opposed to
correctness but I'd like to figure out the best way to resolve it.
The signatures for the libcall routines have floating point arguments
in at least some situations. I have not fully examined
if it's all of them. So in callinfo while I'm lowering
2012 Sep 21
2
[LLVMdev] mips16 puzzle
Actually, SP is already not in the mips 16 register class but there is
some C++ code that is common to mips32, mips64 and mips16 that is
wanting to use SP. It's kind of awkward but does work except in this
case of load/store haflword and byte to stack objects.
Maybe I'm shooting myself in the foot there. I don't know that code too
well so maybe I need to look into it.
There are
2013 Jan 08
2
[LLVMdev] mips16 hard float puzzle
On 01/04/2013 07:45 PM, Eli Friedman wrote:
> On Fri, Jan 4, 2013 at 6:28 PM, reed kotler <rkotler at mips.com> wrote:
>> On 01/04/2013 06:08 PM, Eli Friedman wrote:
>>> On Fri, Jan 4, 2013 at 4:08 PM, reed kotler <rkotler at mips.com> wrote:
>>>> I'm working on mips16 hard float which at a first approximation is just
>>>> soft
2013 Feb 05
2
[LLVMdev] register scavenging
I ran into a case in Mips16 where I need two registers.
The problem arises from the fact that SP is not a mips16 register.
You can implicitly use it in load/store and, move it to/from a mips16
register and add small immediate values to it but that's it.
It's not in general a problem for me because there are a bunch of mips32
registers that are hard to use in mips16 so at this time, I
2012 Nov 03
4
[LLVMdev] symbols for exception handling
mips16 has some unusual requirements for label symbols in .s.
I think that arm thumb has the same issue but have not located yet how
this is handled.
When you have a label of an instruction in mips16, when you reference
the label, the linker
adds a 1 to the address. When you call an odd numbered address, the
procesor switches to mips16 mode and when you call an even numbered
address it
2012 Nov 03
0
[LLVMdev] symbols for exception handling
I'm working on a patch for this problem for mips16; unfortunately it's a
target independent patch.
I'm not sure the best nomenclature for this.
In the gcc mips16 patch they call "xxx=." a debug label.
The other terminology they use is byte pointer vs ISA-encoded address
(ISA-encoded meaning this one bit in the case of mips16 ISA).
I'm planning to add a virtual method