search for: simplety

Displaying 20 results from an estimated 46 matches for "simplety".

2012 Jul 26
2
[LLVMdev] Why is this assertion here?
I'm trying to understand why this assertion is here. LegalizeAction getCondCodeAction(ISD::CondCode CC, EVT VT) const { assert((unsigned)CC < array_lengthof(CondCodeActions) && (unsigned)VT.getSimpleVT().SimpleTy < sizeof(CondCodeActions[0])*4 && "Table isn't big enough!"); LegalizeAction Action = (LegalizeAction) ((CondCodeActions[CC] >> (2*VT.getSimpleVT().SimpleTy)) & 3); assert(Action != Promote && "Can't promote condition code...
2012 Jul 26
2
[LLVMdev] RFC: CondCodeActions refactor (was RE: Why is this assertion here?)
...n) { > assert(VT < MVT::LAST_VALUETYPE && > (unsigned)CC < array_lengthof(CondCodeActions) && > "Table isn't big enough!"); > CondCodeActions[(unsigned)CC][VT.SimplyTy >> 5] &= > ~(uint64_t(3UL) << (VT.SimpleTy - 32)*2); > CondCodeActions[(unsigned)CC][VT.SimpleTy >> 5] |= (uint64_t)Action > << (VT.SimpleTy - 32)*2; } > > getCondCodeAction then becomes: > LegalizeAction > getCondCodeAction(ISD::CondCode CC, EVT VT) const { > assert((unsigned)CC < array_lengthof(C...
2012 Jul 26
0
[LLVMdev] RFC: CondCodeActions refactor (was RE: Why is this assertion here?)
...LegalizeAction Action) { assert(VT < MVT::LAST_VALUETYPE && (unsigned)CC < array_lengthof(CondCodeActions) && "Table isn't big enough!"); CondCodeActions[(unsigned)CC][VT.SimplyTy >> 5] &= ~(uint64_t(3UL) << (VT.SimpleTy - 32)*2); CondCodeActions[(unsigned)CC][VT.SimpleTy >> 5] |= (uint64_t)Action << (VT.SimpleTy - 32)*2; } getCondCodeAction then becomes: LegalizeAction getCondCodeAction(ISD::CondCode CC, EVT VT) const { assert((unsigned)CC < array_lengthof(CondCodeActions) &&...
2012 Jul 26
0
[LLVMdev] RFC: CondCodeActions refactor (was RE: Why is this assertion here?)
...(VT < MVT::LAST_VALUETYPE && > > (unsigned)CC < array_lengthof(CondCodeActions) && > > "Table isn't big enough!"); > > CondCodeActions[(unsigned)CC][VT.SimplyTy >> 5] &= > > ~(uint64_t(3UL) << (VT.SimpleTy - 32)*2); > > CondCodeActions[(unsigned)CC][VT.SimpleTy >> 5] |= (uint64_t)Action << > > (VT.SimpleTy - 32)*2; } > > > > getCondCodeAction then becomes: > > LegalizeAction > > getCondCodeAction(ISD::CondCode CC, EVT VT) const { > > assert(...
2009 Apr 07
6
[LLVMdev] Porting to System z
...false (gdb) n 146 if (MVT(VT).isInteger()) { (gdb) p isSim $2 = true So you'd assume it's the tests in isInteger() that are failing: /// isInteger - Return true if this is an integer, or a vector integer type. bool isInteger() const { return isSimple() ? ((SimpleTy >= FIRST_INTEGER_VALUETYPE && SimpleTy <= LAST_INTEGER_VALUETYPE) || (SimpleTy >= v2i8 && SimpleTy <= v2i64)) : isExtendedInteger(); } But... (gdb) p llvm::MVT::i8 >= FIRST_INTEGER_VALUETYPE $10 = true (gdb) p llvm::MVT:...
2009 Aug 18
2
[LLVMdev] gcc4.4's -O2 is breaking include/llvm/CodeGen/ValueTypes.h
...m 1. Running pass 'ARM Instruction Selection' on function '@_ZL6createP6node_tii3v_tS1_d' The problem appears to be gcc 4.4 optimizing away comparisons of one plus the last item in the SimpleValueType enum, like this: bool operator==(const EVT VT) const { if (V.SimpleTy == VT.V.SimpleTy) { if (V.SimpleTy == MVT::LastSimpleValueType+1) return LLVMTy == VT.LLVMTy; return true; } return false; } I confirmed this by adding a dummy value to the enum that equals LastSimpleValueType+1, and both the warning and the fa...
2009 Apr 07
0
[LLVMdev] Porting to System z
Hi, > llvm[1]: Building Intrinsics.gen.tmp from Intrinsics.td > tblgen: IntrinsicEmitter.cpp:163: void EmitTypeForValueType(std::ostream&, > llvm::MVT::SimpleValueType): Assertion `false && "Unsupported ValueType!"' > failed. this came up before IIRC, but I don't remember the details - buggy system compiler? Try searching the archives. Also, if you
2009 Apr 07
0
[LLVMdev] Porting to System z
* Neale Ferguson: > So the SimpleTy variable which is a SimpleTypeValue is behaving strangely. > It's found within a private definition: > > union { > uintptr_t V; > SimpleValueType SimpleTy; > const Type *LLVMTy; > }; > > The comment in the above fix indicates that in this 6...
2010 Jul 17
2
[LLVMdev] v16i32/v16f32
I tried adding them in my backend however I run into the assertion assert((unsigned)VT.SimpleTy < sizeof(LoadExtActions[0])*4 && ExtType < array_lengthof(LoadExtActions) && "Table isn't big enough!"); What does the assertion mean ? thanks for all help!! shrey On Wed, Jul 14, 2010 at 6:56 PM, Eli Friedman <eli.friedman at gmail.c...
2009 Aug 24
1
[LLVMdev] [llvm-commits] [llvm] r79731 - /llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
...it I was > told that fixing it would be too hard/expensive. I know, and it's somewhat unfortunate. However, this path is extremely hot in LLC, and was significantly contended using only two threads. I don't have a non-contended solution offhand. >> VTs[VT.getSimpleVT().SimpleTy] = VT; >> - return &VTs[VT.getSimpleVT().SimpleTy]; >> + sys::MemoryFence(); > > I don't think this fence actually does anything useful unless > users of the pointer do a fence before reading the contents > of the pointer. That said, I think alpha is the only...
2009 Apr 07
2
[LLVMdev] Porting to System z
Hi, I am beginning the porting process for Linux on System z (aka IBM Mainframe). I thought I¹d build LLVM first with the c and cpp backends so that tools like TableGen would be created that I¹d then use to process the .td files that I¹ll be creating. So I used svn to grab the code from the repository and ran configure and make. However, the build breaks at this point: llvm[1]: Building
2009 Apr 07
2
[LLVMdev] Porting to System z
...#pragma which can be used to do it and gcc 4.3 seems to be happy with the hack described but as Duncan says trying to force this behavior in a union is probably less than desirable in the long term. Another ugly hack that I tried: union { uintptr_t V; #ifdef _LP64 SimpleValueType SimpleTyU[2]; # define SimpleTy SimpleTyU[1] #else SimpleValueType SimpleTyU[1]; # define SimpleTy SimpleTyU[0] #endif const Type *LLVMTy; }; This works on my big endian 64-bit system but I've not seen what damage it may do on other platform types. On 4/7/09 4:09 PM, "Anton Korob...
2010 Jul 17
0
[LLVMdev] v16i32/v16f32
On Fri, Jul 16, 2010 at 5:14 PM, shreyas krishnan <shreyas76 at gmail.com> wrote: > I tried adding them in my backend however I run into the assertion > >  assert((unsigned)VT.SimpleTy < sizeof(LoadExtActions[0])*4 && >           ExtType < array_lengthof(LoadExtActions) && >           "Table isn't big enough!"); > > What does the assertion mean ? That means you forgot to bump up LAST_VALUETYPE. -Eli
2009 Aug 19
0
[LLVMdev] gcc4.4's -O2 is breaking include/llvm/CodeGen/ValueTypes.h
...truction Selection' on function > '@_ZL6createP6node_tii3v_tS1_d' > > > The problem appears to be gcc 4.4 optimizing away comparisons of one > plus the last item in the SimpleValueType enum, like this: > > bool operator==(const EVT VT) const { > if (V.SimpleTy == VT.V.SimpleTy) { > if (V.SimpleTy == MVT::LastSimpleValueType+1) > return LLVMTy == VT.LLVMTy; > return true; > } > return false; > } ValueTypes.h was particularly heavily impacted by the recent API changes, and it looks like it&...
2009 Apr 07
0
[LLVMdev] Porting to System z
Hello, > +static const uintptr_t minus_one = -1; -1 here is of signed int type. What if you will use -1ULL ? -- With best regards, Anton Korobeynikov Faculty of Mathematics and Mechanics, Saint Petersburg State University
2009 Apr 08
0
[LLVMdev] Porting to System z
...ber of compilers it breaks it clearly needs to be changed. I'm not sure the enum needs to be an enum, how about turning it into a uintptr_t instead? Ciao, Duncan. > Another ugly hack that I tried: > > union { > uintptr_t V; > #ifdef _LP64 > SimpleValueType SimpleTyU[2]; > # define SimpleTy SimpleTyU[1] > #else > SimpleValueType SimpleTyU[1]; > # define SimpleTy SimpleTyU[0] > #endif > const Type *LLVMTy; > }; > > This works on my big endian 64-bit system but I've not seen what damage it > may do on other plat...
2010 Jul 17
1
[LLVMdev] v16i32/v16f32
Thanks Eli ...I actually did that ..bumped it up by 2 that I had added. Any thing else that I might have done wrong ? I can see a different assert where it clearly depends on LAST_VALUETYPE assert((unsigned)VT.SimpleTy < MVT::LAST_VALUETYPE thanks shrey On Fri, Jul 16, 2010 at 5:20 PM, Eli Friedman <eli.friedman at gmail.com> wrote: > On Fri, Jul 16, 2010 at 5:14 PM, shreyas krishnan <shreyas76 at gmail.com> wrote: >> I tried adding them in my backend however I run into the assertion &...
2012 Jul 30
2
[LLVMdev] Vector promotion broken for <2 x [i8|i16]>
...D::AND, MVT::v4i8) is MVT::v2i32; The reason why this occurs is: // See if this has an explicit type specified. std::map<std::pair<unsigned, MVT::SimpleValueType>, MVT::SimpleValueType>::const_iterator PTTI = PromoteToType.find(std::make_pair(Op, VT.getSimpleVT().SimpleTy)); if (PTTI != PromoteToType.end()) return PTTI->second; assert((VT.isInteger() || VT.isFloatingPoint()) && "Cannot autopromote this type, add it with AddPromotedToType."); EVT NVT = VT; do { NVT = (MVT::SimpleValueType)(NVT.getSimpleVT().Simp...
2013 Jun 17
0
[LLVMdev] Failure handling half type
...electionDAGLegalize::ExpandConstantFP() assumes that f32 is the smallest floating point constant type it’ll need to handle, and that MVT enum ordering reflects that. while (SVT != MVT::f32) { SVT = (MVT::SimpleValueType)(SVT.getSimpleVT().SimpleTy - 1); ... } That function, and possibly others, need to be taught how to handle half-floats, it looks like. -Jim On Jun 17, 2013, at 6:59 AM, Alessio Giovanni Baroni <alessiogiovanni.baroni at gmail.com> wrote: > Hi, > > if I write the following simple program: > >...
2013 Jun 18
2
[LLVMdev] Failure handling half type
...bug. > Specifically, SelectionDAGLegalize::ExpandConstantFP() assumes that f32 is > the smallest floating point constant type it’ll need to handle, and that > MVT enum ordering reflects that. > > while (SVT != MVT::f32) { > > SVT = (MVT::SimpleValueType)(SVT.getSimpleVT().SimpleTy - 1); > ... > } > > That function, and possibly others, need to be taught how to handle > half-floats, it looks like. > > -Jim > > On Jun 17, 2013, at 6:59 AM, Alessio Giovanni Baroni < > alessiogiovanni.baroni at gmail.com> wrote: > > Hi, > > i...