From 5a70dd1d8286faa4713b60da7621094d892e2ffc Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Fri, 13 Mar 2015 18:20:45 +0000 Subject: [PATCH] [opaque pointer type] Add textual IR support for explicit type parameter to gep operator Similar to gep (r230786) and load (r230794) changes. Similar migration script can be used to update test cases, which successfully migrated all of LLVM and Polly, but about 4 test cases needed manually changes in Clang. (this script will read the contents of stdin and massage it into stdout - wrap it in the 'apply.sh' script shown in previous commits + xargs to apply it over a large set of test cases) import fileinput import sys import re rep = re.compile(r"(getelementptr(?:\s+inbounds)?\s*\()((<\d*\s+x\s+)?([^@]*?)(|\s*addrspace\(\d+\))\s*\*(?(3)>)\s*)(?=$|%|@|null|undef|blockaddress|getelementptr|addrspacecast|bitcast|inttoptr|zeroinitializer|<|\[\[[a-zA-Z]|\{\{)", re.MULTILINE | re.DOTALL) def conv(match): line = match.group(1) line += match.group(4) line += ", " line += match.group(2) return line line = sys.stdin.read() off = 0 for match in re.finditer(rep, line): sys.stdout.write(line[off:match.start()]) sys.stdout.write(conv(match)) off = match.end() sys.stdout.write(line[off:]) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@232184 91177308-0d34-0410-b5e6-96231b3b80d8 --- docs/LangRef.rst | 4 +- lib/AsmParser/LLParser.cpp | 20 +- lib/IR/AsmWriter.cpp | 8 + .../BasicAA/2003-12-11-ConstExprGEP.ll | 4 +- .../BasicAA/2007-10-24-ArgumentsGlobals.ll | 4 +- .../BasicAA/2008-06-02-GEPTailCrash.ll | 4 +- test/Analysis/BasicAA/aligned-overread.ll | 6 +- test/Analysis/BasicAA/featuretest.ll | 2 +- test/Analysis/BasicAA/phi-spec-order.ll | 2 +- .../CFLAliasAnalysis/asm-global-bugfix.ll | 2 +- .../CFLAliasAnalysis/const-expr-gep.ll | 8 +- test/Analysis/DependenceAnalysis/UsefulGEP.ll | 2 +- .../Analysis/GlobalsModRef/volatile-instrs.ll | 4 +- test/Analysis/LazyCallGraph/basic.ll | 4 +- .../2012-03-26-LoadConstant.ll | 2 +- .../ScalarEvolution/max-trip-count.ll | 2 +- test/Analysis/ScalarEvolution/pr22179.ll | 6 +- test/Analysis/ScalarEvolution/sext-iv-2.ll | 2 +- .../ScalarEvolution/zext-signed-addrec.ll | 2 +- .../TypeBasedAliasAnalysis/PR17620.ll | 4 +- .../2002-08-15-ConstantExprProblem.ll | 2 +- .../2002-08-15-UnresolvedGlobalReference.ll | 2 +- test/Assembler/2002-08-16-ConstExprInlined.ll | 2 +- .../2003-08-20-ConstantExprGEP-Fold.ll | 2 +- .../2004-01-11-getelementptrfolding.ll | 2 +- test/Assembler/2007-01-05-Cmp-ConstExpr.ll | 2 +- test/Assembler/2007-12-11-AddressSpaces.ll | 4 +- test/Assembler/2009-07-24-ZeroArgGEP.ll | 2 +- ...-02-05-FunctionLocalMetadataBecomesNull.ll | 2 +- test/Assembler/ConstantExprFold.ll | 10 +- test/Assembler/ConstantExprNoFold.ll | 18 +- test/Assembler/alias-use-list-order.ll | 8 +- test/Assembler/auto_upgrade_intrinsics.ll | 2 +- test/Assembler/flags.ll | 8 +- test/Assembler/getelementptr.ll | 18 +- test/Assembler/getelementptr_vec_idx4.ll | 2 +- test/Assembler/uselistorder.ll | 6 +- test/Assembler/uselistorder_bb.ll | 6 +- test/Bitcode/memInstructions.3.2.ll | 2 +- test/Bitcode/metadata-2.ll | 4 +- test/Bitcode/old-aliases.ll | 4 +- test/Bitcode/use-list-order.ll | 10 +- .../AArch64/arm64-2012-06-06-FPToUI.ll | 8 +- test/CodeGen/AArch64/arm64-abi-varargs.ll | 4 +- test/CodeGen/AArch64/arm64-atomic.ll | 4 +- test/CodeGen/AArch64/arm64-collect-loh-str.ll | 4 +- .../AArch64/arm64-fast-isel-addr-offset.ll | 4 +- .../AArch64/arm64-fast-isel-intrinsic.ll | 16 +- test/CodeGen/AArch64/arm64-hello.ll | 2 +- test/CodeGen/AArch64/arm64-memcpy-inline.ll | 14 +- .../CodeGen/AArch64/arm64-pic-local-symbol.ll | 2 +- test/CodeGen/AArch64/arm64-vector-ldst.ll | 48 ++-- test/CodeGen/AArch64/br-to-eh-lpad.ll | 8 +- .../CodeGen/AArch64/dag-combine-invaraints.ll | 2 +- test/CodeGen/AArch64/global-merge-4.ll | 52 ++-- .../AArch64/inline-asm-globaladdress.ll | 2 +- test/CodeGen/AArch64/rm_redundant_cmp.ll | 64 ++--- .../CodeGen/ARM/2007-04-03-UndefinedSymbol.ll | 4 +- test/CodeGen/ARM/2007-04-30-CombinerCrash.ll | 8 +- .../ARM/2007-05-03-BadPostIndexedLd.ll | 2 +- test/CodeGen/ARM/2007-08-15-ReuseBug.ll | 2 +- .../ARM/2008-03-07-RegScavengerAssert.ll | 4 +- .../CodeGen/ARM/2008-04-04-ScavengerAssert.ll | 2 +- .../CodeGen/ARM/2008-04-10-ScavengerAssert.ll | 8 +- .../ARM/2008-05-19-LiveIntervalsBug.ll | 4 +- .../CodeGen/ARM/2008-05-19-ScavengerAssert.ll | 2 +- test/CodeGen/ARM/2008-08-07-AsmPrintBug.ll | 2 +- test/CodeGen/ARM/2009-02-16-SpillerBug.ll | 2 +- test/CodeGen/ARM/2009-05-07-RegAllocLocal.ll | 2 +- .../ARM/2009-05-11-CodePlacementCrash.ll | 2 +- test/CodeGen/ARM/2009-06-02-ISelCrash.ll | 2 +- .../ARM/2009-06-30-RegScavengerAssert.ll | 6 +- .../ARM/2009-06-30-RegScavengerAssert2.ll | 6 +- test/CodeGen/ARM/2009-07-18-RewriterBug.ll | 2 +- test/CodeGen/ARM/2009-08-21-PostRAKill3.ll | 2 +- test/CodeGen/ARM/2009-10-27-double-align.ll | 2 +- test/CodeGen/ARM/2010-05-17-FastAllocCrash.ll | 2 +- .../CodeGen/ARM/2010-05-18-LocalAllocCrash.ll | 2 +- .../CodeGen/ARM/2010-06-21-LdStMultipleBug.ll | 4 +- test/CodeGen/ARM/2010-06-21-nondarwin-tc.ll | 2 +- test/CodeGen/ARM/2010-06-29-SubregImpDefs.ll | 2 +- test/CodeGen/ARM/2010-07-26-GlobalMerge.ll | 16 +- test/CodeGen/ARM/2011-04-26-SchedTweak.ll | 2 +- test/CodeGen/ARM/2011-11-28-DAGCombineBug.ll | 16 +- test/CodeGen/ARM/2012-02-01-CoalescerBug.ll | 2 +- .../ARM/2012-10-04-FixedFrame-vs-byval.ll | 2 +- .../CodeGen/ARM/2013-04-21-AAPCS-VA-C.1.cp.ll | 2 +- test/CodeGen/ARM/Windows/read-only-data.ll | 2 +- test/CodeGen/ARM/arm-ttype-target2.ll | 2 +- test/CodeGen/ARM/cache-intrinsic.ll | 8 +- test/CodeGen/ARM/crash-O0.ll | 4 +- test/CodeGen/ARM/cse-call.ll | 4 +- test/CodeGen/ARM/cse-ldrlit.ll | 4 +- test/CodeGen/ARM/debug-info-branch-folding.ll | 4 +- test/CodeGen/ARM/debug-info-d16-reg.ll | 8 +- test/CodeGen/ARM/debug-info-qreg.ll | 2 +- test/CodeGen/ARM/debug-info-s16-reg.ll | 8 +- test/CodeGen/ARM/dwarf-eh.ll | 2 +- test/CodeGen/ARM/dyn-stackalloc.ll | 2 +- test/CodeGen/ARM/fast-isel-GEP-coalesce.ll | 8 +- test/CodeGen/ARM/fast-isel-align.ll | 2 +- test/CodeGen/ARM/fast-isel-intrinsic.ll | 14 +- test/CodeGen/ARM/global-merge-1.ll | 28 +-- test/CodeGen/ARM/hello.ll | 2 +- test/CodeGen/ARM/ifconv-regmask.ll | 2 +- test/CodeGen/ARM/indirectbr-2.ll | 2 +- test/CodeGen/ARM/ldm.ll | 16 +- test/CodeGen/ARM/ldrd.ll | 6 +- test/CodeGen/ARM/machine-cse-cmp.ll | 2 +- test/CodeGen/ARM/memcpy-inline.ll | 14 +- test/CodeGen/ARM/mult-alt-generic-arm.ll | 8 +- test/CodeGen/ARM/neon-spfp.ll | 2 +- test/CodeGen/ARM/optselect-regclass.ll | 4 +- .../CodeGen/ARM/sjlj-prepare-critical-edge.ll | 2 +- .../ARM/stack-protector-bmovpcb_call.ll | 4 +- test/CodeGen/ARM/stm.ll | 4 +- test/CodeGen/ARM/tls3.ll | 2 +- test/CodeGen/ARM/uint64tof64.ll | 2 +- test/CodeGen/ARM/vargs.ll | 4 +- test/CodeGen/BPF/ex1.ll | 4 +- test/CodeGen/BPF/load.ll | 2 +- test/CodeGen/BPF/sanity.ll | 2 +- test/CodeGen/BPF/struct_ret1.ll | 2 +- test/CodeGen/Generic/2003-07-06-BadIntCmp.ll | 4 +- .../Generic/2003-07-07-BadLongConst.ll | 2 +- .../Generic/2003-07-08-BadCastToBool.ll | 2 +- .../Generic/2003-07-29-BadConstSbyte.ll | 4 +- .../CodeGen/Generic/2005-04-09-GlobalInPHI.ll | 2 +- test/CodeGen/Generic/2005-12-01-Crash.ll | 2 +- .../Generic/2006-09-02-LocalAllocCrash.ll | 4 +- test/CodeGen/Generic/2007-05-03-EHTypeInfo.ll | 2 +- test/CodeGen/Generic/2008-02-04-Ctlz.ll | 2 +- .../Generic/2008-08-07-PtrToInt-SmallerInt.ll | 2 +- test/CodeGen/Generic/ConstantExprLowering.ll | 2 +- test/CodeGen/Generic/add-with-overflow-128.ll | 4 +- test/CodeGen/Generic/add-with-overflow-24.ll | 8 +- test/CodeGen/Generic/add-with-overflow.ll | 8 +- test/CodeGen/Generic/annotate.ll | 2 +- test/CodeGen/Generic/badarg6.ll | 2 +- test/CodeGen/Generic/crash.ll | 2 +- test/CodeGen/Generic/fastcall.ll | 2 +- test/CodeGen/Generic/invalid-memcpy.ll | 2 +- test/CodeGen/Generic/ptr-annotate.ll | 2 +- test/CodeGen/Hexagon/gp-plus-offset-load.ll | 6 +- test/CodeGen/Hexagon/gp-plus-offset-store.ll | 4 +- test/CodeGen/MSP430/2009-12-22-InlineAsm.ll | 2 +- test/CodeGen/MSP430/AddrMode-bis-rx.ll | 2 +- test/CodeGen/MSP430/AddrMode-bis-xr.ll | 4 +- test/CodeGen/MSP430/AddrMode-mov-rx.ll | 2 +- test/CodeGen/MSP430/AddrMode-mov-xr.ll | 2 +- test/CodeGen/MSP430/inline-asm.ll | 2 +- .../CodeGen/MSP430/mult-alt-generic-msp430.ll | 8 +- .../Mips/2008-07-15-InternalConstant.ll | 4 +- test/CodeGen/Mips/2008-07-15-SmallSection.ll | 6 +- test/CodeGen/Mips/2012-12-12-ExpandMemcpy.ll | 2 +- test/CodeGen/Mips/Fast-ISel/loadstrconst.ll | 2 +- test/CodeGen/Mips/Fast-ISel/overflt.ll | 2 +- test/CodeGen/Mips/alloca.ll | 2 +- test/CodeGen/Mips/and1.ll | 2 +- test/CodeGen/Mips/atomic.ll | 2 +- test/CodeGen/Mips/atomicops.ll | 6 +- test/CodeGen/Mips/brind.ll | 10 +- test/CodeGen/Mips/cache-intrinsic.ll | 8 +- test/CodeGen/Mips/cconv/arguments-struct.ll | 2 +- .../arguments-varargs-small-structs-byte.ll | 18 +- ...ents-varargs-small-structs-combinations.ll | 10 +- ...nts-varargs-small-structs-multiple-args.ll | 2 +- test/CodeGen/Mips/cconv/return-struct.ll | 2 +- test/CodeGen/Mips/cmov.ll | 2 +- test/CodeGen/Mips/ex2.ll | 2 +- test/CodeGen/Mips/fastcc.ll | 88 +++---- test/CodeGen/Mips/fp-indexed-ls.ll | 4 +- test/CodeGen/Mips/helloworld.ll | 2 +- test/CodeGen/Mips/hf16call32.ll | 208 ++++++++-------- test/CodeGen/Mips/hfptrcall.ll | 32 +-- test/CodeGen/Mips/i32k.ll | 4 +- test/CodeGen/Mips/inlineasm-operand-code.ll | 6 +- test/CodeGen/Mips/inlineasmmemop.ll | 4 +- test/CodeGen/Mips/internalfunc.ll | 4 +- test/CodeGen/Mips/largeimmprinting.ll | 2 +- test/CodeGen/Mips/lb1.ll | 2 +- test/CodeGen/Mips/lbu1.ll | 2 +- test/CodeGen/Mips/lh1.ll | 2 +- test/CodeGen/Mips/lhu1.ll | 2 +- test/CodeGen/Mips/load-store-left-right.ll | 26 +- test/CodeGen/Mips/mbrsize4a.ll | 2 +- test/CodeGen/Mips/memcpy.ll | 2 +- test/CodeGen/Mips/micromips-addiu.ll | 6 +- test/CodeGen/Mips/micromips-andi.ll | 4 +- test/CodeGen/Mips/micromips-delay-slot-jr.ll | 4 +- test/CodeGen/Mips/mips16_32_8.ll | 6 +- test/CodeGen/Mips/mips16_fpret.ll | 8 +- test/CodeGen/Mips/mips16ex.ll | 4 +- test/CodeGen/Mips/neg1.ll | 2 +- test/CodeGen/Mips/not1.ll | 2 +- test/CodeGen/Mips/or1.ll | 2 +- test/CodeGen/Mips/prevent-hoisting.ll | 2 +- test/CodeGen/Mips/sb1.ll | 2 +- test/CodeGen/Mips/selnek.ll | 8 +- test/CodeGen/Mips/sh1.ll | 2 +- test/CodeGen/Mips/sll1.ll | 2 +- test/CodeGen/Mips/sll2.ll | 2 +- test/CodeGen/Mips/sra1.ll | 2 +- test/CodeGen/Mips/sra2.ll | 2 +- test/CodeGen/Mips/srl1.ll | 2 +- test/CodeGen/Mips/srl2.ll | 2 +- test/CodeGen/Mips/stchar.ll | 12 +- test/CodeGen/Mips/stldst.ll | 4 +- test/CodeGen/Mips/sub1.ll | 2 +- test/CodeGen/Mips/sub2.ll | 2 +- test/CodeGen/Mips/ul1.ll | 2 +- test/CodeGen/Mips/unalignedload.ll | 2 +- test/CodeGen/Mips/xor1.ll | 2 +- test/CodeGen/NVPTX/access-non-generic.ll | 4 +- test/CodeGen/NVPTX/nvvm-reflect.ll | 4 +- test/CodeGen/NVPTX/symbol-naming.ll | 2 +- .../PowerPC/2007-02-23-lr-saved-twice.ll | 2 +- .../2007-05-03-InlineAsm-S-Constraint.ll | 2 +- .../PowerPC/2007-10-21-LocalRegAllocAssert.ll | 2 +- .../2007-10-21-LocalRegAllocAssert2.ll | 6 +- .../PowerPC/2008-02-05-LiveIntervalsAssert.ll | 2 +- .../PowerPC/2008-04-23-CoalescerCrash.ll | 8 +- .../CodeGen/PowerPC/2008-07-24-PPC64-CCBug.ll | 2 +- .../PowerPC/2009-01-16-DeclareISelBug.ll | 2 +- .../PowerPC/2011-12-05-NoSpillDupCR.ll | 30 +-- .../PowerPC/2011-12-06-SpillAndRestoreCR.ll | 8 +- test/CodeGen/PowerPC/2013-07-01-PHIElimBug.ll | 4 +- test/CodeGen/PowerPC/cr-spills.ll | 2 +- test/CodeGen/PowerPC/cr1eq-no-extra-moves.ll | 4 +- test/CodeGen/PowerPC/cr1eq.ll | 4 +- test/CodeGen/PowerPC/cr_spilling.ll | 2 +- test/CodeGen/PowerPC/ctrloop-s000.ll | 2 +- test/CodeGen/PowerPC/ctrloop-sums.ll | 2 +- .../CodeGen/PowerPC/fast-isel-GEP-coalesce.ll | 8 +- test/CodeGen/PowerPC/fast-isel-load-store.ll | 10 +- test/CodeGen/PowerPC/hello.ll | 2 +- test/CodeGen/PowerPC/isel-rc-nox0.ll | 2 +- test/CodeGen/PowerPC/load-shift-combine.ll | 10 +- .../PowerPC/mult-alt-generic-powerpc.ll | 8 +- .../PowerPC/mult-alt-generic-powerpc64.ll | 8 +- test/CodeGen/PowerPC/ppc64le-aggregates.ll | 14 +- test/CodeGen/PowerPC/pr16556-2.ll | 4 +- test/CodeGen/PowerPC/pr17168.ll | 2 +- test/CodeGen/PowerPC/pr17354.ll | 2 +- test/CodeGen/PowerPC/remat-imm.ll | 2 +- test/CodeGen/PowerPC/resolvefi-basereg.ll | 224 ++++++++--------- test/CodeGen/PowerPC/resolvefi-disp.ll | 4 +- test/CodeGen/PowerPC/s000-alias-misched.ll | 6 +- test/CodeGen/PowerPC/sjlj.ll | 4 +- test/CodeGen/PowerPC/stack-protector.ll | 2 +- test/CodeGen/PowerPC/structsinmem.ll | 4 +- test/CodeGen/PowerPC/structsinregs.ll | 4 +- test/CodeGen/PowerPC/stwu-gta.ll | 4 +- test/CodeGen/PowerPC/tls-cse.ll | 4 +- test/CodeGen/PowerPC/toc-load-sched-bug.ll | 12 +- test/CodeGen/PowerPC/trampoline.ll | 12 +- test/CodeGen/PowerPC/vsx-spill-norwstore.ll | 2 +- .../R600/32-bit-local-address-space.ll | 2 +- test/CodeGen/R600/big_alu.ll | 40 +-- test/CodeGen/R600/dot4-folding.ll | 2 +- test/CodeGen/R600/ds_read2.ll | 16 +- test/CodeGen/R600/ds_write2.ll | 16 +- test/CodeGen/R600/fetch-limits.r600.ll | 16 +- test/CodeGen/R600/fetch-limits.r700+.ll | 32 +-- test/CodeGen/R600/jump-address.ll | 4 +- test/CodeGen/R600/kcache-fold.ll | 32 +-- .../R600/large-constant-initializer.ll | 2 +- test/CodeGen/R600/llvm.AMDGPU.cube.ll | 8 +- test/CodeGen/R600/load-input-fold.ll | 30 +-- .../R600/no-initializer-constant-addrspace.ll | 4 +- test/CodeGen/R600/pv-packing.ll | 2 +- test/CodeGen/R600/pv.ll | 60 ++--- test/CodeGen/R600/r600-export-fix.ll | 44 ++-- test/CodeGen/R600/schedule-if-2.ll | 6 +- test/CodeGen/R600/schedule-if.ll | 4 +- .../schedule-vs-if-nested-loop-failure.ll | 24 +- .../R600/schedule-vs-if-nested-loop.ll | 24 +- test/CodeGen/R600/swizzle-export.ll | 2 +- test/CodeGen/SPARC/exception.ll | 4 +- test/CodeGen/SPARC/mult-alt-generic-sparc.ll | 8 +- test/CodeGen/SPARC/setjmp.ll | 2 +- .../Thumb/2007-05-05-InvalidPushPop.ll | 4 +- .../CodeGen/Thumb/2009-08-12-RegInfoAssert.ll | 2 +- test/CodeGen/Thumb/2011-05-11-DAGLegalizer.ll | 2 +- test/CodeGen/Thumb/asmprinter-bug.ll | 14 +- test/CodeGen/Thumb/dyn-stackalloc.ll | 2 +- test/CodeGen/Thumb/ldm-merge-struct.ll | 4 +- test/CodeGen/Thumb/thumb-ldm.ll | 16 +- test/CodeGen/Thumb/vargs.ll | 2 +- test/CodeGen/Thumb2/2009-07-21-ISelBug.ll | 2 +- .../Thumb2/2009-08-04-CoalescerAssert.ll | 2 +- .../CodeGen/Thumb2/2009-08-04-CoalescerBug.ll | 10 +- .../Thumb2/2009-08-04-ScavengerAssert.ll | 32 +-- test/CodeGen/Thumb2/2009-08-21-PostRAKill4.ll | 6 +- .../CodeGen/Thumb2/2009-09-01-PostRAProlog.ll | 14 +- .../Thumb2/2010-01-06-TailDuplicateLabels.ll | 4 +- .../CodeGen/Thumb2/2010-03-08-addi12-ccout.ll | 2 +- .../Thumb2/2010-06-14-NEONCoalescer.ll | 4 +- .../CodeGen/Thumb2/2010-06-21-TailMergeBug.ll | 2 +- .../Thumb2/2010-08-10-VarSizedAllocaBug.ll | 4 +- test/CodeGen/Thumb2/constant-islands.ll | 2 +- test/CodeGen/Thumb2/crash.ll | 6 +- test/CodeGen/Thumb2/thumb2-ldm.ll | 16 +- test/CodeGen/Thumb2/thumb2-tbh.ll | 2 +- test/CodeGen/Thumb2/v8_IT_3.ll | 2 +- .../X86/2005-02-14-IllegalAssembler.ll | 2 +- test/CodeGen/X86/2006-10-13-CycleInDAG.ll | 2 +- .../2006-10-19-SwitchUnnecessaryBranching.ll | 4 +- test/CodeGen/X86/2007-02-16-BranchFold.ll | 2 +- test/CodeGen/X86/2007-03-26-CoalescerBug.ll | 2 +- test/CodeGen/X86/2007-04-08-InlineAsmCrash.ll | 2 +- test/CodeGen/X86/2007-05-05-VecCastExpand.ll | 2 +- test/CodeGen/X86/2007-07-10-StackerAssert.ll | 2 +- .../X86/2007-08-09-IllegalX86-64Asm.ll | 2 +- .../X86/2007-08-13-AppendingLinkage.ll | 2 +- test/CodeGen/X86/2007-10-15-CoalescerCrash.ll | 2 +- .../X86/2007-11-04-rip-immediate-constant.ll | 2 +- test/CodeGen/X86/2008-02-18-TailMergingBug.ll | 2 +- .../X86/2008-03-31-SpillerFoldingBug.ll | 12 +- test/CodeGen/X86/2008-04-17-CoalescerBug.ll | 4 +- .../X86/2008-05-28-LocalRegAllocBug.ll | 2 +- test/CodeGen/X86/2008-07-16-CoalescerCrash.ll | 2 +- test/CodeGen/X86/2008-08-06-CmpStride.ll | 2 +- test/CodeGen/X86/2008-08-06-RewriterBug.ll | 10 +- test/CodeGen/X86/2008-09-29-ReMatBug.ll | 4 +- test/CodeGen/X86/2008-12-01-SpillerAssert.ll | 2 +- .../CodeGen/X86/2008-12-19-EarlyClobberBug.ll | 2 +- .../X86/2009-01-18-ConstantExprCrash.ll | 2 +- test/CodeGen/X86/2009-02-04-sext-i64-gep.ll | 2 +- test/CodeGen/X86/2009-03-23-LinearScanBug.ll | 6 +- test/CodeGen/X86/2009-03-25-TestBug.ll | 4 +- .../X86/2009-05-08-InlineAsmIOffset.ll | 2 +- .../X86/2009-10-19-atomic-cmp-eflags.ll | 6 +- test/CodeGen/X86/2009-11-16-MachineLICM.ll | 8 +- test/CodeGen/X86/2009-11-16-UnfoldMemOpBug.ll | 2 +- .../X86/2010-04-30-LocalAlloc-LandingPad.ll | 2 +- .../X86/2010-06-15-FastAllocEarlyCLobber.ll | 2 +- .../X86/2010-06-24-g-constraint-crash.ll | 2 +- test/CodeGen/X86/2010-07-06-DbgCrash.ll | 2 +- test/CodeGen/X86/2010-07-15-Crash.ll | 4 +- .../X86/2010-08-04-MaskedSignedCompare.ll | 2 +- .../X86/2010-09-30-CMOV-JumpTable-PHI.ll | 4 +- .../X86/2011-01-24-DbgValue-Before-Use.ll | 4 +- .../X86/2011-05-26-UnreachableBlockElim.ll | 2 +- test/CodeGen/X86/2011-10-12-MachineCSE.ll | 2 +- test/CodeGen/X86/2011-10-19-LegelizeLoad.ll | 2 +- test/CodeGen/X86/2012-09-28-CGPBug.ll | 2 +- test/CodeGen/X86/2012-11-30-misched-dbg.ll | 2 +- test/CodeGen/X86/2013-03-13-VEX-DestReg.ll | 2 +- test/CodeGen/X86/2014-08-29-CompactUnwind.ll | 2 +- test/CodeGen/X86/GC/badwriteproto.ll | 2 +- test/CodeGen/X86/abi-isel.ll | 118 ++++----- .../address-type-promotion-constantexpr.ll | 2 +- test/CodeGen/X86/aliases.ll | 2 +- test/CodeGen/X86/alignment-2.ll | 2 +- test/CodeGen/X86/asm-global-imm.ll | 2 +- test/CodeGen/X86/byval-align.ll | 6 +- test/CodeGen/X86/cache-intrinsic.ll | 8 +- test/CodeGen/X86/catch.ll | 2 +- test/CodeGen/X86/cfstring.ll | 4 +- test/CodeGen/X86/cmov.ll | 2 +- test/CodeGen/X86/coalescer-remat.ll | 2 +- test/CodeGen/X86/codegen-prepare-cast.ll | 2 +- test/CodeGen/X86/codegen-prepare-extload.ll | 6 +- test/CodeGen/X86/codemodel.ll | 12 +- test/CodeGen/X86/coff-comdat.ll | 2 +- test/CodeGen/X86/crash.ll | 2 +- test/CodeGen/X86/critical-edge-split-2.ll | 2 +- test/CodeGen/X86/dagcombine-and-setcc.ll | 2 +- test/CodeGen/X86/darwin-stub.ll | 2 +- .../X86/dbg-changes-codegen-branch-folding.ll | 16 +- test/CodeGen/X86/discontiguous-loops.ll | 4 +- test/CodeGen/X86/fast-isel-mem.ll | 2 +- test/CodeGen/X86/fltused.ll | 2 +- test/CodeGen/X86/fltused_function_pointer.ll | 2 +- test/CodeGen/X86/fold-load.ll | 2 +- test/CodeGen/X86/fold-sext-trunc.ll | 4 +- test/CodeGen/X86/fold-zext-trunc.ll | 4 +- test/CodeGen/X86/frameescape.ll | 4 +- test/CodeGen/X86/ga-offset.ll | 2 +- test/CodeGen/X86/hidden-vis-pic.ll | 2 +- test/CodeGen/X86/hoist-invariant-load.ll | 4 +- test/CodeGen/X86/inline-asm-fpstack.ll | 2 +- test/CodeGen/X86/large-code-model-isel.ll | 2 +- test/CodeGen/X86/lea-recursion.ll | 30 +-- test/CodeGen/X86/leaf-fp-elim.ll | 2 +- test/CodeGen/X86/licm-nested.ll | 2 +- test/CodeGen/X86/licm-symbol.ll | 4 +- test/CodeGen/X86/lsr-i386.ll | 2 +- test/CodeGen/X86/lsr-normalization.ll | 4 +- test/CodeGen/X86/memcmp.ll | 6 +- test/CodeGen/X86/memcpy-2.ll | 4 +- test/CodeGen/X86/memcpy.ll | 4 +- test/CodeGen/X86/misaligned-memset.ll | 2 +- test/CodeGen/X86/movfs.ll | 2 +- test/CodeGen/X86/movgs.ll | 6 +- test/CodeGen/X86/mult-alt-generic-i686.ll | 8 +- test/CodeGen/X86/mult-alt-generic-x86_64.ll | 8 +- test/CodeGen/X86/musttail-fastcall.ll | 4 +- test/CodeGen/X86/narrow_op-1.ll | 8 +- test/CodeGen/X86/negative-subscript.ll | 2 +- test/CodeGen/X86/object-size.ll | 4 +- test/CodeGen/X86/opaque-constant-asm.ll | 2 +- test/CodeGen/X86/packed_struct.ll | 10 +- test/CodeGen/X86/phys-reg-local-regalloc.ll | 2 +- test/CodeGen/X86/postra-licm.ll | 6 +- test/CodeGen/X86/pr13458.ll | 2 +- test/CodeGen/X86/pr1489.ll | 2 +- test/CodeGen/X86/pr1505b.ll | 4 +- test/CodeGen/X86/pr18023.ll | 16 +- test/CodeGen/X86/pr21792.ll | 4 +- test/CodeGen/X86/pr2656.ll | 2 +- test/CodeGen/X86/pr3522.ll | 2 +- test/CodeGen/X86/ptrtoint-constexpr.ll | 2 +- test/CodeGen/X86/ragreedy-hoist-spill.ll | 4 +- .../X86/ragreedy-last-chance-recoloring.ll | 8 +- test/CodeGen/X86/rd-mod-wr-eflags.ll | 4 +- test/CodeGen/X86/reverse_branches.ll | 8 +- test/CodeGen/X86/seh-catch-all.ll | 2 +- test/CodeGen/X86/seh-finally.ll | 4 +- test/CodeGen/X86/seh-safe-div.ll | 10 +- test/CodeGen/X86/selectiondag-cse.ll | 8 +- test/CodeGen/X86/sjlj.ll | 4 +- test/CodeGen/X86/smul-with-overflow.ll | 8 +- test/CodeGen/X86/sse2.ll | 8 +- test/CodeGen/X86/stack-protector-dbginfo.ll | 4 +- test/CodeGen/X86/stack-protector.ll | 130 +++++----- test/CodeGen/X86/store_op_load_fold.ll | 4 +- test/CodeGen/X86/stores-merging.ll | 6 +- test/CodeGen/X86/sub-with-overflow.ll | 8 +- test/CodeGen/X86/switch-crit-edge-constant.ll | 2 +- test/CodeGen/X86/tailcall-returndup-void.ll | 2 +- test/CodeGen/X86/tlv-1.ll | 2 +- test/CodeGen/X86/twoaddr-coalesce.ll | 2 +- test/CodeGen/X86/umul-with-carry.ll | 4 +- test/CodeGen/X86/unaligned-load.ll | 2 +- test/CodeGen/X86/utf16-cfstrings.ll | 2 +- test/CodeGen/X86/v4i32load-crash.ll | 8 +- test/CodeGen/X86/vararg_tailcall.ll | 4 +- test/CodeGen/X86/vec-loadsingles-alignment.ll | 16 +- test/CodeGen/X86/x86-64-gv-offset.ll | 4 +- test/CodeGen/X86/x86-64-jumps.ll | 2 +- test/CodeGen/X86/x86-64-mem.ll | 8 +- test/CodeGen/X86/x86-64-varargs.ll | 2 +- test/CodeGen/X86/xmulo.ll | 6 +- .../CodeGen/XCore/2011-01-31-DAGCombineBug.ll | 2 +- test/CodeGen/XCore/codemodel.ll | 14 +- test/CodeGen/XCore/threads.ll | 16 +- test/CodeGen/XCore/unaligned_load.ll | 2 +- test/DebugInfo/AArch64/cfi-eof-prologue.ll | 4 +- test/DebugInfo/ARM/cfi-eof-prologue.ll | 4 +- test/DebugInfo/Sparc/gnu-window-save.ll | 2 +- test/DebugInfo/SystemZ/variable-loc.ll | 2 +- test/DebugInfo/X86/byvalstruct.ll | 8 +- test/DebugInfo/X86/dbg-subrange.ll | 2 +- .../X86/dbg-value-inlined-parameter.ll | 4 +- test/DebugInfo/X86/debug-info-blocks.ll | 24 +- test/DebugInfo/X86/debug-ranges-offset.ll | 20 +- test/DebugInfo/X86/decl-derived-member.ll | 2 +- test/DebugInfo/X86/multiple-at-const-val.ll | 2 +- test/DebugInfo/X86/objc-property-void.ll | 10 +- test/DebugInfo/X86/pr19307.ll | 2 +- test/DebugInfo/X86/rvalue-ref.ll | 2 +- test/DebugInfo/X86/sret.ll | 6 +- test/DebugInfo/X86/subregisters.ll | 2 +- test/DebugInfo/inheritance.ll | 8 +- test/DebugInfo/tu-composite.ll | 2 +- test/DebugInfo/two-cus-from-same-file.ll | 4 +- .../MCJIT/2002-12-16-ArgTest.ll | 2 +- .../MCJIT/2013-04-04-RelocAddend.ll | 2 +- test/ExecutionEngine/MCJIT/hello-sm-pic.ll | 2 +- test/ExecutionEngine/MCJIT/hello.ll | 2 +- test/ExecutionEngine/MCJIT/pr13727.ll | 2 +- .../MCJIT/remote/stubs-remote.ll | 2 +- .../MCJIT/remote/stubs-sm-pic.ll | 2 +- .../remote/test-common-symbols-remote.ll | 2 +- .../MCJIT/remote/test-ptr-reloc-remote.ll | 4 +- .../MCJIT/remote/test-ptr-reloc-sm-pic.ll | 4 +- test/ExecutionEngine/MCJIT/stubs-sm-pic.ll | 2 +- test/ExecutionEngine/MCJIT/stubs.ll | 2 +- .../MCJIT/test-common-symbols.ll | 2 +- .../MCJIT/test-ptr-reloc-sm-pic.ll | 4 +- test/ExecutionEngine/MCJIT/test-ptr-reloc.ll | 4 +- .../OrcJIT/2002-12-16-ArgTest.ll | 2 +- .../OrcJIT/2013-04-04-RelocAddend.ll | 2 +- test/ExecutionEngine/OrcJIT/hello-sm-pic.ll | 2 +- test/ExecutionEngine/OrcJIT/hello.ll | 2 +- test/ExecutionEngine/OrcJIT/pr13727.ll | 2 +- .../OrcJIT/remote/stubs-remote.ll | 2 +- .../OrcJIT/remote/stubs-sm-pic.ll | 2 +- .../remote/test-common-symbols-remote.ll | 2 +- .../OrcJIT/remote/test-ptr-reloc-remote.ll | 4 +- .../OrcJIT/remote/test-ptr-reloc-sm-pic.ll | 4 +- test/ExecutionEngine/OrcJIT/stubs-sm-pic.ll | 2 +- test/ExecutionEngine/OrcJIT/stubs.ll | 2 +- .../OrcJIT/test-common-symbols.ll | 2 +- .../OrcJIT/test-ptr-reloc-sm-pic.ll | 4 +- test/ExecutionEngine/OrcJIT/test-ptr-reloc.ll | 4 +- test/ExecutionEngine/frem.ll | 2 +- test/Feature/alias2.ll | 6 +- test/Feature/attributes.ll | 2 +- test/Feature/const_pv.ll | 2 +- test/Feature/constexpr.ll | 18 +- test/Feature/packed_struct.ll | 10 +- .../AddressSanitizer/asan-vs-gvn.ll | 8 +- .../AddressSanitizer/global_metadata.ll | 2 +- .../AddressSanitizer/instrument_global.ll | 10 +- .../Instrumentation/InstrProfiling/linkage.ll | 8 +- .../InstrProfiling/noruntime.ll | 2 +- .../InstrProfiling/platform.ll | 2 +- .../InstrProfiling/profiling.ll | 10 +- .../ThreadSanitizer/tsan-vs-gvn.ll | 4 +- test/Integer/constexpr_bt.ll | 18 +- test/Integer/packed_struct_bt.ll | 10 +- test/Linker/2002-08-20-ConstantExpr.ll | 2 +- test/Linker/2004-05-07-TypeResolution1.ll | 2 +- test/Linker/AppendingLinkage.ll | 2 +- test/Linker/Inputs/comdat5.ll | 2 +- test/Linker/comdat6.ll | 2 +- test/Linker/partial-type-refinement.ll | 4 +- test/Linker/type-unique-simple2-a.ll | 2 +- test/Linker/type-unique-simple2-b.ll | 2 +- test/MC/ARM/elf-reloc-02.ll | 8 +- test/MC/COFF/global_ctors_dtors.ll | 6 +- test/MC/ELF/entsize.ll | 8 +- test/MC/MachO/AArch64/cstexpr-gotpcrel.ll | 6 +- test/MC/MachO/ARM/cstexpr-gotpcrel.ll | 6 +- test/MC/MachO/cstexpr-gotpcrel-32.ll | 6 +- test/MC/MachO/cstexpr-gotpcrel-64.ll | 6 +- test/MC/Mips/elf-bigendian.ll | 4 +- test/MC/Mips/sym-offset.ll | 2 +- test/Object/Inputs/trivial.ll | 2 +- .../Other/constant-fold-gep-address-spaces.ll | 152 ++++++------ test/Other/constant-fold-gep.ll | 204 +++++++-------- test/Transforms/BBVectorize/func-alias.ll | 64 ++--- test/Transforms/BBVectorize/mem-op-depth.ll | 16 +- .../ConstProp/2005-01-28-SetCCGEP.ll | 2 +- test/Transforms/ConstProp/div-zero.ll | 2 +- test/Transforms/ConstProp/loads.ll | 18 +- .../ConstantMerge/2002-09-23-CPR-Update.ll | 4 +- .../DeadArgElim/2010-04-30-DbgInfo.ll | 2 +- .../GCOVProfiling/function-numbering.ll | 4 +- .../GVN/2007-07-26-InterlockingLoops.ll | 6 +- .../GVN/2008-12-14-rle-reanalyze.ll | 2 +- .../GVN/2009-11-12-MemDepMallocBitCast.ll | 2 +- test/Transforms/GVN/2011-04-27-phioperands.ll | 2 +- .../2011-06-01-NonLocalMemdepMiscompile.ll | 2 +- test/Transforms/GVN/load-pre-nonlocal.ll | 4 +- test/Transforms/GVN/pr17732.ll | 8 +- test/Transforms/GVN/pre-compare.ll | 6 +- test/Transforms/GVN/rle.ll | 14 +- .../GlobalDCE/2002-08-17-WorkListTest.ll | 4 +- .../GlobalDCE/complex-constantexpr.ll | 6 +- .../2005-06-15-LocalizeConstExprCrash.ll | 2 +- test/Transforms/GlobalOpt/2007-05-13-Crash.ll | 4 +- .../GlobalOpt/2007-06-04-PackedStruct.ll | 2 +- .../GlobalOpt/2007-11-09-GEP-GEP-Crash.ll | 2 +- .../GlobalOpt/2008-04-26-SROA-Global-Align.ll | 12 +- .../GlobalOpt/2008-07-17-addrspace.ll | 8 +- .../GlobalOpt/2008-12-16-HeapSRACrash-2.ll | 2 +- .../GlobalOpt/2008-12-16-HeapSRACrash.ll | 2 +- .../2009-11-16-BrokenPerformHeapAllocSRoA.ll | 4 +- test/Transforms/GlobalOpt/alias-resolve.ll | 4 +- test/Transforms/GlobalOpt/array-elem-refs.ll | 4 +- .../GlobalOpt/constantfold-initializers.ll | 12 +- test/Transforms/GlobalOpt/crash-2.ll | 4 +- test/Transforms/GlobalOpt/crash.ll | 4 +- .../GlobalOpt/ctor-list-opt-inbounds.ll | 8 +- test/Transforms/GlobalOpt/ctor-list-opt.ll | 2 +- test/Transforms/GlobalOpt/cxx-dtor.ll | 2 +- .../externally-initialized-global-ctr.ll | 8 +- .../Transforms/GlobalOpt/globalsra-partial.ll | 2 +- .../GlobalOpt/globalsra-unknown-index.ll | 2 +- test/Transforms/GlobalOpt/globalsra.ll | 8 +- test/Transforms/GlobalOpt/iterate.ll | 2 +- test/Transforms/GlobalOpt/memcpy.ll | 2 +- test/Transforms/GlobalOpt/memset.ll | 4 +- test/Transforms/GlobalOpt/tls.ll | 8 +- .../IPConstantProp/2009-09-24-byval-ptr.ll | 4 +- .../IndVarSimplify/2005-11-18-Crash.ll | 2 +- .../IndVarSimplify/2011-10-27-lftrnull.ll | 2 +- .../IndVarSimplify/2012-07-17-lftr-undef.ll | 2 +- .../IndVarSimplify/eliminate-max.ll | 2 +- test/Transforms/IndVarSimplify/lftr-zext.ll | 2 +- .../IndVarSimplify/loop_evaluate9.ll | 4 +- test/Transforms/IndVarSimplify/udiv.ll | 2 +- test/Transforms/Inline/alloca-dbgdeclare.ll | 8 +- test/Transforms/Inline/byval.ll | 6 +- test/Transforms/Inline/devirtualize.ll | 20 +- test/Transforms/Inline/inline-vla.ll | 4 +- test/Transforms/Inline/inline_ssp.ll | 8 +- .../2007-11-25-CompatibleAttributes.ll | 2 +- .../InstCombine/2008-05-17-InfLoop.ll | 2 +- ...2009-01-19-fmod-constant-float-specials.ll | 32 +-- .../InstCombine/2009-12-17-CmpSelectNull.ll | 2 +- .../InstCombine/2010-03-03-ExtElim.ll | 6 +- .../InstCombine/2010-05-30-memcpy-Struct.ll | 2 +- .../Transforms/InstCombine/2012-02-13-FCmp.ll | 4 +- .../InstCombine/2012-07-25-LoadPart.ll | 2 +- .../InstCombine/2012-07-30-addrsp-bitcast.ll | 2 +- ...013-03-05-Combine-BitcastTy-Into-Alloca.ll | 2 +- test/Transforms/InstCombine/PR7357.ll | 2 +- test/Transforms/InstCombine/addrspacecast.ll | 2 +- .../Transforms/InstCombine/alias-recursion.ll | 2 +- test/Transforms/InstCombine/align-addr.ll | 2 +- .../InstCombine/constant-expr-datalayout.ll | 2 +- .../constant-fold-address-space-pointer.ll | 10 +- .../InstCombine/constant-fold-alias.ll | 4 +- .../InstCombine/constant-fold-gep.ll | 92 +++---- test/Transforms/InstCombine/crash.ll | 2 +- test/Transforms/InstCombine/debug-line.ll | 2 +- test/Transforms/InstCombine/err-rep-cold.ll | 12 +- test/Transforms/InstCombine/fprintf-1.ll | 12 +- test/Transforms/InstCombine/fputs-1.ll | 2 +- test/Transforms/InstCombine/gepgep.ll | 2 +- test/Transforms/InstCombine/getelementptr.ll | 36 +-- test/Transforms/InstCombine/icmp.ll | 8 +- test/Transforms/InstCombine/known_align.ll | 4 +- test/Transforms/InstCombine/load-select.ll | 2 +- test/Transforms/InstCombine/load3.ll | 6 +- .../InstCombine/malloc-free-delete.ll | 2 +- .../InstCombine/memcpy-from-global.ll | 24 +- test/Transforms/InstCombine/memmove.ll | 2 +- .../InstCombine/objsize-address-space.ll | 6 +- test/Transforms/InstCombine/objsize.ll | 26 +- test/Transforms/InstCombine/osx-names.ll | 4 +- test/Transforms/InstCombine/pr8547.ll | 2 +- test/Transforms/InstCombine/printf-1.ll | 10 +- test/Transforms/InstCombine/printf-2.ll | 4 +- test/Transforms/InstCombine/puts-1.ll | 2 +- .../InstCombine/simplify-libcalls.ll | 16 +- test/Transforms/InstCombine/sprintf-1.ll | 6 +- .../Transforms/InstCombine/stack-overalign.ll | 2 +- test/Transforms/InstCombine/stpcpy-1.ll | 2 +- test/Transforms/InstCombine/stpcpy_chk-1.ll | 24 +- test/Transforms/InstCombine/strchr-1.ll | 6 +- test/Transforms/InstCombine/strcmp-1.ll | 2 +- test/Transforms/InstCombine/strcpy-1.ll | 2 +- test/Transforms/InstCombine/strcpy_chk-1.ll | 24 +- test/Transforms/InstCombine/strncpy-1.ll | 2 +- test/Transforms/InstCombine/strncpy_chk-1.ll | 14 +- test/Transforms/InstCombine/strpbrk-1.ll | 2 +- test/Transforms/InstCombine/strrchr-1.ll | 6 +- test/Transforms/InstCombine/strstr-1.ll | 2 +- test/Transforms/InstCombine/sub.ll | 4 +- .../InstCombine/urem-simplify-bug.ll | 2 +- .../InstMerge/st_sink_bugfix_22613.ll | 4 +- .../InstSimplify/2011-10-27-BinOpCrash.ll | 2 +- test/Transforms/InstSimplify/call-callconv.ll | 2 +- test/Transforms/InstSimplify/past-the-end.ll | 2 +- test/Transforms/InstSimplify/vector_gep.ll | 2 +- .../JumpThreading/2010-08-26-and.ll | 16 +- .../JumpThreading/2011-04-14-InfLoop.ll | 2 +- test/Transforms/JumpThreading/indirectbr.ll | 6 +- test/Transforms/JumpThreading/landing-pad.ll | 6 +- test/Transforms/JumpThreading/lvi-load.ll | 2 +- test/Transforms/JumpThreading/phi-eq.ll | 8 +- test/Transforms/LCSSA/invoke-dest.ll | 12 +- test/Transforms/LICM/2011-04-09-RAUW-AST.ll | 2 +- test/Transforms/LICM/hoist-invariant-load.ll | 4 +- test/Transforms/LICM/scalar_promote.ll | 4 +- .../LoopIdiom/basic-address-space.ll | 2 +- test/Transforms/LoopIdiom/basic.ll | 2 +- .../LoopSimplify/2003-08-15-PreheadersFail.ll | 2 +- .../LoopSimplify/phi-node-simplify.ll | 4 +- .../2008-08-13-CmpStride.ll | 2 +- .../LoopStrengthReduce/2008-09-09-Overflow.ll | 2 +- ...9-01-13-nonconstant-stride-outside-loop.ll | 2 +- .../2009-04-28-no-reduce-mul.ll | 2 +- .../2012-07-18-LimitReassociate.ll | 20 +- .../X86/2012-01-13-phielim.ll | 2 +- .../LoopStrengthReduce/X86/pr17473.ll | 2 +- test/Transforms/LoopStrengthReduce/pr18165.ll | 10 +- .../LoopUnswitch/2007-07-12-ExitDomInfo.ll | 2 +- .../LoopUnswitch/2007-08-01-LCSSA.ll | 2 +- .../LoopVectorize/2012-10-22-isconsec.ll | 2 +- .../LoopVectorize/X86/masked_load_store.ll | 2 +- test/Transforms/LoopVectorize/global_alias.ll | 102 ++++---- .../Transforms/LoopVectorize/if-conversion.ll | 8 +- test/Transforms/LoopVectorize/ptr_loops.ll | 18 +- test/Transforms/LowerBitSets/constant.ll | 4 +- test/Transforms/LowerBitSets/simple.ll | 12 +- .../Mem2Reg/2007-08-27-VolatileLoadsStores.ll | 2 +- test/Transforms/MemCpyOpt/form-memset.ll | 30 +-- test/Transforms/MemCpyOpt/memcpy.ll | 2 +- test/Transforms/MemCpyOpt/memmove.ll | 2 +- test/Transforms/MemCpyOpt/smaller.ll | 8 +- .../MergeFunc/2011-02-08-RemoveEqual.ll | 8 +- test/Transforms/MergeFunc/crash.ll | 2 +- test/Transforms/MergeFunc/inttoptr.ll | 2 +- test/Transforms/ObjCARC/basic.ll | 8 +- ...e-that-exception-unwind-path-is-visited.ll | 10 +- test/Transforms/ObjCARC/nested.ll | 2 +- test/Transforms/ObjCARC/weak-copies.ll | 4 +- .../2010-03-22-empty-baseclass.ll | 2 +- test/Transforms/PhaseOrdering/gdce.ll | 4 +- test/Transforms/SLPVectorizer/X86/addsub.ll | 232 +++++++++--------- test/Transforms/SLPVectorizer/X86/atomics.ll | 16 +- .../SLPVectorizer/X86/compare-reduce.ll | 2 +- .../X86/crash_netbsd_decompress.ll | 8 +- .../SLPVectorizer/X86/in-tree-user.ll | 2 +- .../SLPVectorizer/X86/operandorder.ll | 2 +- test/Transforms/SLPVectorizer/X86/return.ll | 8 +- test/Transforms/SROA/slice-width.ll | 4 +- test/Transforms/SampleProfile/branch.ll | 2 +- test/Transforms/SampleProfile/calls.ll | 2 +- test/Transforms/SampleProfile/fnptr.ll | 2 +- test/Transforms/SampleProfile/propagate.ll | 2 +- test/Transforms/ScalarRepl/memcpy-align.ll | 2 +- test/Transforms/ScalarRepl/phi-cycle.ll | 4 +- .../SimplifyCFG/2003-08-17-FoldSwitch-dbg.ll | 2 +- .../2008-07-13-InfLoopMiscompile.ll | 2 +- test/Transforms/SimplifyCFG/MagicPointer.ll | 16 +- .../SimplifyCFG/X86/switch_to_lookup_table.ll | 20 +- .../bitcast-address-space-through-gep-2.ll | 4 +- .../bitcast-address-space-through-gep.ll | 2 +- test/tools/llvm-readobj/Inputs/trivial.ll | 2 +- 717 files changed, 2749 insertions(+), 2725 deletions(-) diff --git a/docs/LangRef.rst b/docs/LangRef.rst index 4da9f5ba58e..25248572ea8 100644 --- a/docs/LangRef.rst +++ b/docs/LangRef.rst @@ -2707,11 +2707,11 @@ The following is the syntax for constant expressions: Convert a constant pointer or constant vector of pointer, CST, to another TYPE in a different address space. The constraints of the operands are the same as those for the :ref:`addrspacecast instruction `. -``getelementptr (CSTPTR, IDX0, IDX1, ...)``, ``getelementptr inbounds (CSTPTR, IDX0, IDX1, ...)`` +``getelementptr (TY, CSTPTR, IDX0, IDX1, ...)``, ``getelementptr inbounds (TY, CSTPTR, IDX0, IDX1, ...)`` Perform the :ref:`getelementptr operation ` on constants. As with the :ref:`getelementptr ` instruction, the index list may have zero or more indexes, which are - required to make sense for the type of "CSTPTR". + required to make sense for the type of "pointer to TY". ``select (COND, VAL1, VAL2)`` Perform the :ref:`select operation ` on constants. ``icmp COND (VAL1, VAL2)`` diff --git a/lib/AsmParser/LLParser.cpp b/lib/AsmParser/LLParser.cpp index c1d2810a5cf..363d4369a3c 100644 --- a/lib/AsmParser/LLParser.cpp +++ b/lib/AsmParser/LLParser.cpp @@ -2777,11 +2777,23 @@ bool LLParser::ParseValID(ValID &ID, PerFunctionState *PFS) { unsigned Opc = Lex.getUIntVal(); SmallVector Elts; bool InBounds = false; + Type *Ty; Lex.Lex(); + if (Opc == Instruction::GetElementPtr) InBounds = EatIfPresent(lltok::kw_inbounds); - if (ParseToken(lltok::lparen, "expected '(' in constantexpr") || - ParseGlobalValueVector(Elts) || + + if (ParseToken(lltok::lparen, "expected '(' in constantexpr")) + return true; + + LocTy ExplicitTypeLoc = Lex.getLoc(); + if (Opc == Instruction::GetElementPtr) { + if (ParseType(Ty) || + ParseToken(lltok::comma, "expected comma after getelementptr's type")) + return true; + } + + if (ParseGlobalValueVector(Elts) || ParseToken(lltok::rparen, "expected ')' in constantexpr")) return true; @@ -2792,6 +2804,10 @@ bool LLParser::ParseValID(ValID &ID, PerFunctionState *PFS) { Type *BaseType = Elts[0]->getType(); auto *BasePointerType = cast(BaseType->getScalarType()); + if (Ty != BasePointerType->getElementType()) + return Error( + ExplicitTypeLoc, + "explicit pointee type doesn't match operand's pointee type"); ArrayRef Indices(Elts.begin() + 1, Elts.end()); for (Constant *Val : Indices) { diff --git a/lib/IR/AsmWriter.cpp b/lib/IR/AsmWriter.cpp index 7728580d207..5ab6953bdbd 100644 --- a/lib/IR/AsmWriter.cpp +++ b/lib/IR/AsmWriter.cpp @@ -1223,6 +1223,14 @@ static void WriteConstantInternal(raw_ostream &Out, const Constant *CV, Out << ' ' << getPredicateText(CE->getPredicate()); Out << " ("; + if (const GEPOperator *GEP = dyn_cast(CE)) { + TypePrinter.print( + cast(GEP->getPointerOperandType()->getScalarType()) + ->getElementType(), + Out); + Out << ", "; + } + for (User::const_op_iterator OI=CE->op_begin(); OI != CE->op_end(); ++OI) { TypePrinter.print((*OI)->getType(), Out); Out << ' '; diff --git a/test/Analysis/BasicAA/2003-12-11-ConstExprGEP.ll b/test/Analysis/BasicAA/2003-12-11-ConstExprGEP.ll index 52d10d2e056..957502f2d99 100644 --- a/test/Analysis/BasicAA/2003-12-11-ConstExprGEP.ll +++ b/test/Analysis/BasicAA/2003-12-11-ConstExprGEP.ll @@ -15,8 +15,8 @@ target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" define void @test() { %D = getelementptr %T, %T* @G, i64 0, i32 0 %E = getelementptr %T, %T* @G, i64 0, i32 1, i64 5 - %F = getelementptr i32, i32* getelementptr (%T* @G, i64 0, i32 0), i64 0 - %X = getelementptr [10 x i8], [10 x i8]* getelementptr (%T* @G, i64 0, i32 1), i64 0, i64 5 + %F = getelementptr i32, i32* getelementptr (%T, %T* @G, i64 0, i32 0), i64 0 + %X = getelementptr [10 x i8], [10 x i8]* getelementptr (%T, %T* @G, i64 0, i32 1), i64 0, i64 5 ret void } diff --git a/test/Analysis/BasicAA/2007-10-24-ArgumentsGlobals.ll b/test/Analysis/BasicAA/2007-10-24-ArgumentsGlobals.ll index 9e3745737f3..2d33e943937 100644 --- a/test/Analysis/BasicAA/2007-10-24-ArgumentsGlobals.ll +++ b/test/Analysis/BasicAA/2007-10-24-ArgumentsGlobals.ll @@ -8,9 +8,9 @@ define i32 @_Z3fooP1A(%struct.A* %b) { ; CHECK: %tmp7 = load ; CHECK: ret i32 %tmp7 entry: - store i32 1, i32* getelementptr (%struct.B* @a, i32 0, i32 0, i32 0), align 8 + store i32 1, i32* getelementptr (%struct.B, %struct.B* @a, i32 0, i32 0, i32 0), align 8 %tmp4 = getelementptr %struct.A, %struct.A* %b, i32 0, i32 0 ; [#uses=1] store i32 0, i32* %tmp4, align 4 - %tmp7 = load i32, i32* getelementptr (%struct.B* @a, i32 0, i32 0, i32 0), align 8 ; [#uses=1] + %tmp7 = load i32, i32* getelementptr (%struct.B, %struct.B* @a, i32 0, i32 0, i32 0), align 8 ; [#uses=1] ret i32 %tmp7 } diff --git a/test/Analysis/BasicAA/2008-06-02-GEPTailCrash.ll b/test/Analysis/BasicAA/2008-06-02-GEPTailCrash.ll index 9b6dbeccd73..7d2cde4864a 100644 --- a/test/Analysis/BasicAA/2008-06-02-GEPTailCrash.ll +++ b/test/Analysis/BasicAA/2008-06-02-GEPTailCrash.ll @@ -9,7 +9,7 @@ target triple = "i686-pc-linux-gnu" define void @test291() nounwind { entry: - store i32 1138410269, i32* getelementptr ([5 x %struct.S291]* @a291, i32 0, i32 2, i32 1) - %tmp54 = load i32, i32* bitcast (%struct.S291* getelementptr ([5 x %struct.S291]* @a291, i32 0, i32 2) to i32*), align 4 ; [#uses=0] + store i32 1138410269, i32* getelementptr ([5 x %struct.S291], [5 x %struct.S291]* @a291, i32 0, i32 2, i32 1) + %tmp54 = load i32, i32* bitcast (%struct.S291* getelementptr ([5 x %struct.S291], [5 x %struct.S291]* @a291, i32 0, i32 2) to i32*), align 4 ; [#uses=0] unreachable } diff --git a/test/Analysis/BasicAA/aligned-overread.ll b/test/Analysis/BasicAA/aligned-overread.ll index 47588e71a71..aa0a83e6697 100644 --- a/test/Analysis/BasicAA/aligned-overread.ll +++ b/test/Analysis/BasicAA/aligned-overread.ll @@ -9,11 +9,11 @@ target triple = "x86_64-apple-macosx10.8.0" define i32 @main() nounwind uwtable ssp { entry: - %tmp = load i8, i8* getelementptr inbounds ({ i8, i8, i8, i8, i8 }* @a, i64 0, i32 4), align 4 + %tmp = load i8, i8* getelementptr inbounds ({ i8, i8, i8, i8, i8 }, { i8, i8, i8, i8, i8 }* @a, i64 0, i32 4), align 4 %tmp1 = or i8 %tmp, -128 - store i8 %tmp1, i8* getelementptr inbounds ({ i8, i8, i8, i8, i8 }* @a, i64 0, i32 4), align 4 + store i8 %tmp1, i8* getelementptr inbounds ({ i8, i8, i8, i8, i8 }, { i8, i8, i8, i8, i8 }* @a, i64 0, i32 4), align 4 %tmp2 = load i64, i64* bitcast ({ i8, i8, i8, i8, i8 }* @a to i64*), align 8 - store i8 11, i8* getelementptr inbounds ({ i8, i8, i8, i8, i8 }* @a, i64 0, i32 4), align 4 + store i8 11, i8* getelementptr inbounds ({ i8, i8, i8, i8, i8 }, { i8, i8, i8, i8, i8 }* @a, i64 0, i32 4), align 4 %tmp3 = trunc i64 %tmp2 to i32 ret i32 %tmp3 diff --git a/test/Analysis/BasicAA/featuretest.ll b/test/Analysis/BasicAA/featuretest.ll index 97e97f562cd..c621d0e3e84 100644 --- a/test/Analysis/BasicAA/featuretest.ll +++ b/test/Analysis/BasicAA/featuretest.ll @@ -97,7 +97,7 @@ define i32 @constexpr_test() { call void @external(i32* %X) %Y = load i32, i32* %X - store i32 5, i32* getelementptr ({ i32 }* @Global, i64 0, i32 0) + store i32 5, i32* getelementptr ({ i32 }, { i32 }* @Global, i64 0, i32 0) %REMOVE = load i32, i32* %X %retval = sub i32 %Y, %REMOVE ret i32 %retval diff --git a/test/Analysis/BasicAA/phi-spec-order.ll b/test/Analysis/BasicAA/phi-spec-order.ll index 30aff8c5a48..b326dc36006 100644 --- a/test/Analysis/BasicAA/phi-spec-order.ll +++ b/test/Analysis/BasicAA/phi-spec-order.ll @@ -14,7 +14,7 @@ for.cond2.preheader: ; preds = %for.end, %entry br label %for.body4 for.body4: ; preds = %for.body4, %for.cond2.preheader - %lsr.iv4 = phi [16000 x double]* [ %i11, %for.body4 ], [ bitcast (double* getelementptr inbounds ([16000 x double]* @Y, i64 0, i64 8) + %lsr.iv4 = phi [16000 x double]* [ %i11, %for.body4 ], [ bitcast (double* getelementptr inbounds ([16000 x double], [16000 x double]* @Y, i64 0, i64 8) to [16000 x double]*), %for.cond2.preheader ] %lsr.iv1 = phi [16000 x double]* [ %i10, %for.body4 ], [ @X, %for.cond2.preheader ] diff --git a/test/Analysis/CFLAliasAnalysis/asm-global-bugfix.ll b/test/Analysis/CFLAliasAnalysis/asm-global-bugfix.ll index 1cd19644d5c..ec2de54e3ee 100644 --- a/test/Analysis/CFLAliasAnalysis/asm-global-bugfix.ll +++ b/test/Analysis/CFLAliasAnalysis/asm-global-bugfix.ll @@ -11,6 +11,6 @@ define void @test_no_crash() #0 { entry: call i8* asm "nop", "=r,r"( - i8* getelementptr inbounds ([1 x i8]* @G, i64 0, i64 0)) + i8* getelementptr inbounds ([1 x i8], [1 x i8]* @G, i64 0, i64 0)) ret void } diff --git a/test/Analysis/CFLAliasAnalysis/const-expr-gep.ll b/test/Analysis/CFLAliasAnalysis/const-expr-gep.ll index 8c0ad184f16..c7ff407db2f 100644 --- a/test/Analysis/CFLAliasAnalysis/const-expr-gep.ll +++ b/test/Analysis/CFLAliasAnalysis/const-expr-gep.ll @@ -19,8 +19,8 @@ ; CHECK: MayAlias: i32* %F, i8* %X define void @test() { %D = getelementptr %T, %T* @G, i64 0, i32 0 - %F = getelementptr i32, i32* getelementptr (%T* @G, i64 0, i32 0), i64 0 - %X = getelementptr [10 x i8], [10 x i8]* getelementptr (%T* @G, i64 0, i32 1), i64 0, i64 5 + %F = getelementptr i32, i32* getelementptr (%T, %T* @G, i64 0, i32 0), i64 0 + %X = getelementptr [10 x i8], [10 x i8]* getelementptr (%T, %T* @G, i64 0, i32 1), i64 0, i64 5 ret void } @@ -30,7 +30,7 @@ define void @test() { ; CHECK: MayAlias: i32* %H, i32* %arg0 ; CHECK: MayAlias: i32* %F, i32* %H define void @simplecheck(i32* %arg0) { - %F = getelementptr i32, i32* getelementptr (%T* @G, i64 0, i32 0), i64 0 + %F = getelementptr i32, i32* getelementptr (%T, %T* @G, i64 0, i32 0), i64 0 %H = getelementptr %T, %T* @G2, i64 0, i32 0 ret void @@ -48,7 +48,7 @@ define void @simplecheck(i32* %arg0) { define void @checkNesting(i32* %arg0) { %A = getelementptr [1 x i32], [1 x i32]* getelementptr - ([1 x [1 x i32]]* getelementptr (%NestedT* @NT, i64 0, i32 0), + ([1 x [1 x i32]], [1 x [1 x i32]]* getelementptr (%NestedT, %NestedT* @NT, i64 0, i32 0), i64 0, i32 0), i64 0, diff --git a/test/Analysis/DependenceAnalysis/UsefulGEP.ll b/test/Analysis/DependenceAnalysis/UsefulGEP.ll index 83c43cfca64..cd46a275034 100644 --- a/test/Analysis/DependenceAnalysis/UsefulGEP.ll +++ b/test/Analysis/DependenceAnalysis/UsefulGEP.ll @@ -36,7 +36,7 @@ for.body3.preheader: for.body3: %j.011 = phi i32 [ %inc, %for.body3 ], [ 0, %for.body3.preheader ] %0 = load i32, i32* %arrayidx - store i32 %0, i32* getelementptr inbounds (%struct.s* @S, i64 0, i32 0, i64 0, i64 0) + store i32 %0, i32* getelementptr inbounds (%struct.s, %struct.s* @S, i64 0, i32 0, i64 0, i64 0) %inc = add nuw nsw i32 %j.011, 1 %exitcond = icmp eq i32 %inc, %N br i1 %exitcond, label %for.inc4, label %for.body3 diff --git a/test/Analysis/GlobalsModRef/volatile-instrs.ll b/test/Analysis/GlobalsModRef/volatile-instrs.ll index df49b4b90f9..a331bf370c0 100644 --- a/test/Analysis/GlobalsModRef/volatile-instrs.ll +++ b/test/Analysis/GlobalsModRef/volatile-instrs.ll @@ -22,9 +22,9 @@ declare void @llvm.memcpy.p0i8.p0i8.i64(i8* nocapture, i8* nocapture, i64, i32, define i32 @main() nounwind uwtable ssp { main_entry: tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* bitcast (%struct.anon* @b to i8*), i8* bitcast (%struct.anon* @a to i8*), i64 12, i32 4, i1 false) - %0 = load volatile i32, i32* getelementptr inbounds (%struct.anon* @b, i64 0, i32 0), align 4 + %0 = load volatile i32, i32* getelementptr inbounds (%struct.anon, %struct.anon* @b, i64 0, i32 0), align 4 store i32 %0, i32* @c, align 4 tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* bitcast (%struct.anon* @b to i8*), i8* bitcast (%struct.anon* @a to i8*), i64 12, i32 4, i1 false) nounwind - %call = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([4 x i8]* @.str, i64 0, i64 0), i32 %0) nounwind + %call = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %0) nounwind ret i32 0 } diff --git a/test/Analysis/LazyCallGraph/basic.ll b/test/Analysis/LazyCallGraph/basic.ll index d0116021d9c..6e2cb905c37 100644 --- a/test/Analysis/LazyCallGraph/basic.ll +++ b/test/Analysis/LazyCallGraph/basic.ll @@ -119,8 +119,8 @@ define void @test2() { ; CHECK-NOT: -> load i8*, i8** bitcast (void ()** @g to i8**) - load i8*, i8** bitcast (void ()** getelementptr ([4 x void ()*]* @g1, i32 0, i32 2) to i8**) - load i8*, i8** bitcast (void ()** getelementptr ({i8, void ()*, i8}* @g2, i32 0, i32 1) to i8**) + load i8*, i8** bitcast (void ()** getelementptr ([4 x void ()*], [4 x void ()*]* @g1, i32 0, i32 2) to i8**) + load i8*, i8** bitcast (void ()** getelementptr ({i8, void ()*, i8}, {i8, void ()*, i8}* @g2, i32 0, i32 1) to i8**) load i8*, i8** bitcast (void ()** @h to i8**) ret void } diff --git a/test/Analysis/ScalarEvolution/2012-03-26-LoadConstant.ll b/test/Analysis/ScalarEvolution/2012-03-26-LoadConstant.ll index 3ca552a7dfd..c4a4c3006dd 100644 --- a/test/Analysis/ScalarEvolution/2012-03-26-LoadConstant.ll +++ b/test/Analysis/ScalarEvolution/2012-03-26-LoadConstant.ll @@ -25,7 +25,7 @@ for.cond: ; preds = %for.body, %lbl_818 for.body: ; preds = %for.cond %idxprom = sext i32 %0 to i64 - %arrayidx = getelementptr inbounds [0 x i32], [0 x i32]* getelementptr inbounds ([1 x [0 x i32]]* @g_244, i32 0, i64 0), i32 0, i64 %idxprom + %arrayidx = getelementptr inbounds [0 x i32], [0 x i32]* getelementptr inbounds ([1 x [0 x i32]], [1 x [0 x i32]]* @g_244, i32 0, i64 0), i32 0, i64 %idxprom %1 = load i32, i32* %arrayidx, align 1 store i32 %1, i32* @func_21_l_773, align 4 store i32 1, i32* @g_814, align 4 diff --git a/test/Analysis/ScalarEvolution/max-trip-count.ll b/test/Analysis/ScalarEvolution/max-trip-count.ll index dde44ba8257..72560c77a8e 100644 --- a/test/Analysis/ScalarEvolution/max-trip-count.ll +++ b/test/Analysis/ScalarEvolution/max-trip-count.ll @@ -65,7 +65,7 @@ for.inc: ; preds = %for.body br label %for.cond for.end: ; preds = %for.body, %for.cond - %call = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([4 x i8]* @.str, i64 0, i64 0), i32 %g_4.0) nounwind ; [#uses=0] + %call = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %g_4.0) nounwind ; [#uses=0] ret i32 0 } diff --git a/test/Analysis/ScalarEvolution/pr22179.ll b/test/Analysis/ScalarEvolution/pr22179.ll index 5dc41920e86..21ed055dc7b 100644 --- a/test/Analysis/ScalarEvolution/pr22179.ll +++ b/test/Analysis/ScalarEvolution/pr22179.ll @@ -9,12 +9,12 @@ ; Function Attrs: nounwind ssp uwtable define i32 @main() { ; CHECK-LABEL: Classifying expressions for: @main - store i8 0, i8* getelementptr inbounds (%struct.anon* @a, i64 0, i32 0), align 1 + store i8 0, i8* getelementptr inbounds (%struct.anon, %struct.anon* @a, i64 0, i32 0), align 1 br label %loop loop: %storemerge1 = phi i8 [ 0, %0 ], [ %inc, %loop ] - %m = load volatile i32, i32* getelementptr inbounds (%struct.S* @b, i64 0, i32 0), align 4 + %m = load volatile i32, i32* getelementptr inbounds (%struct.S, %struct.S* @b, i64 0, i32 0), align 4 %inc = add nuw i8 %storemerge1, 1 ; CHECK: %inc = add nuw i8 %storemerge1, 1 ; CHECK-NEXT: --> {1,+,1}<%loop> @@ -23,6 +23,6 @@ loop: br i1 %exitcond, label %exit, label %loop exit: - store i8 -128, i8* getelementptr inbounds (%struct.anon* @a, i64 0, i32 0), align 1 + store i8 -128, i8* getelementptr inbounds (%struct.anon, %struct.anon* @a, i64 0, i32 0), align 1 ret i32 0 } diff --git a/test/Analysis/ScalarEvolution/sext-iv-2.ll b/test/Analysis/ScalarEvolution/sext-iv-2.ll index c9d6e4775ec..8749ff3987f 100644 --- a/test/Analysis/ScalarEvolution/sext-iv-2.ll +++ b/test/Analysis/ScalarEvolution/sext-iv-2.ll @@ -56,7 +56,7 @@ bb4.bb5_crit_edge: ; preds = %bb4 br label %bb5 bb5: ; preds = %bb4.bb5_crit_edge, %entry - %tmp12 = load i32, i32* getelementptr ([32 x [256 x i32]]* @table, i64 0, i64 9, i64 132), align 16 ; [#uses=1] + %tmp12 = load i32, i32* getelementptr ([32 x [256 x i32]], [32 x [256 x i32]]* @table, i64 0, i64 9, i64 132), align 16 ; [#uses=1] %tmp13 = icmp eq i32 %tmp12, -1116 ; [#uses=1] br i1 %tmp13, label %bb7, label %bb6 diff --git a/test/Analysis/ScalarEvolution/zext-signed-addrec.ll b/test/Analysis/ScalarEvolution/zext-signed-addrec.ll index 9201ffca44e..31ebb3e3efe 100644 --- a/test/Analysis/ScalarEvolution/zext-signed-addrec.ll +++ b/test/Analysis/ScalarEvolution/zext-signed-addrec.ll @@ -63,7 +63,7 @@ for.cond.for.end9_crit_edge: ; preds = %for.inc8 for.end9: ; preds = %entry.for.end9_crit_edge, %for.cond.for.end9_crit_edge %3 = phi i32 [ %.pre, %entry.for.end9_crit_edge ], [ %shl, %for.cond.for.end9_crit_edge ] - %call = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([4 x i8]* @.str, i64 0, i64 0), i32 %3) #2 + %call = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %3) #2 br label %return return.loopexit.split: ; preds = %for.cond1.preheader.lr.ph diff --git a/test/Analysis/TypeBasedAliasAnalysis/PR17620.ll b/test/Analysis/TypeBasedAliasAnalysis/PR17620.ll index 15041642ee0..e78529c07f5 100644 --- a/test/Analysis/TypeBasedAliasAnalysis/PR17620.ll +++ b/test/Analysis/TypeBasedAliasAnalysis/PR17620.ll @@ -17,10 +17,10 @@ define %structA** @test(%classA* %this, i32** %p1) #0 align 2 { entry: ; CHECK-LABEL: @test ; CHECK: load i32*, i32** %p1, align 8, !tbaa -; CHECK: load i32*, i32** getelementptr (%classC* null, i32 0, i32 1, i32 0, i32 0), align 8, !tbaa +; CHECK: load i32*, i32** getelementptr (%classC, %classC* null, i32 0, i32 1, i32 0, i32 0), align 8, !tbaa ; CHECK: call void @callee %0 = load i32*, i32** %p1, align 8, !tbaa !1 - %1 = load i32*, i32** getelementptr (%classC* null, i32 0, i32 1, i32 0, i32 0), align 8, !tbaa !5 + %1 = load i32*, i32** getelementptr (%classC, %classC* null, i32 0, i32 1, i32 0, i32 0), align 8, !tbaa !5 call void @callee(i32* %0, i32* %1) unreachable } diff --git a/test/Assembler/2002-08-15-ConstantExprProblem.ll b/test/Assembler/2002-08-15-ConstantExprProblem.ll index 343a1044b9c..47a3f9c96c0 100644 --- a/test/Assembler/2002-08-15-ConstantExprProblem.ll +++ b/test/Assembler/2002-08-15-ConstantExprProblem.ll @@ -8,7 +8,7 @@ define i8* @test() { br label %BB1 BB1: ; preds = %BB2, %0 - %ret = phi i8* [ getelementptr ([12 x i8]* @.LC0, i64 0, i64 0), %0 ], [ null, %BB2 ] ; [#uses=1] + %ret = phi i8* [ getelementptr ([12 x i8], [12 x i8]* @.LC0, i64 0, i64 0), %0 ], [ null, %BB2 ] ; [#uses=1] ret i8* %ret BB2: ; No predecessors! diff --git a/test/Assembler/2002-08-15-UnresolvedGlobalReference.ll b/test/Assembler/2002-08-15-UnresolvedGlobalReference.ll index 6bbe0cfe7f6..cbed33229c4 100644 --- a/test/Assembler/2002-08-15-UnresolvedGlobalReference.ll +++ b/test/Assembler/2002-08-15-UnresolvedGlobalReference.ll @@ -4,6 +4,6 @@ @.LC0 = internal global [12 x i8] c"hello world\00" ; <[12 x i8]*> [#uses=1] define i8* @test() { - ret i8* getelementptr ([12 x i8]* @.LC0, i64 0, i64 0) + ret i8* getelementptr ([12 x i8], [12 x i8]* @.LC0, i64 0, i64 0) } diff --git a/test/Assembler/2002-08-16-ConstExprInlined.ll b/test/Assembler/2002-08-16-ConstExprInlined.ll index b78d858c8cf..d43fe978405 100644 --- a/test/Assembler/2002-08-16-ConstExprInlined.ll +++ b/test/Assembler/2002-08-16-ConstExprInlined.ll @@ -18,6 +18,6 @@ declare i32 @puts(i8*) define void @main() { bb1: - %reg211 = call i32 @puts( i8* getelementptr ([4 x i8]* @.LC0, i64 0, i64 0) ) ; [#uses=0] + %reg211 = call i32 @puts( i8* getelementptr ([4 x i8], [4 x i8]* @.LC0, i64 0, i64 0) ) ; [#uses=0] ret void } diff --git a/test/Assembler/2003-08-20-ConstantExprGEP-Fold.ll b/test/Assembler/2003-08-20-ConstantExprGEP-Fold.ll index 05b4ee2519c..435992c38ad 100644 --- a/test/Assembler/2003-08-20-ConstantExprGEP-Fold.ll +++ b/test/Assembler/2003-08-20-ConstantExprGEP-Fold.ll @@ -4,7 +4,7 @@ @.str_1 = internal constant [6 x i8] c"_Bool\00" ; <[6 x i8]*> [#uses=2] define i32 @test() { - %tmp.54 = load i8, i8* getelementptr ([6 x i8]* @.str_1, i64 0, i64 1) ; [#uses=1] + %tmp.54 = load i8, i8* getelementptr ([6 x i8], [6 x i8]* @.str_1, i64 0, i64 1) ; [#uses=1] %tmp.55 = icmp ne i8 %tmp.54, 66 ; [#uses=1] br i1 %tmp.55, label %then.7, label %endif.7 diff --git a/test/Assembler/2004-01-11-getelementptrfolding.ll b/test/Assembler/2004-01-11-getelementptrfolding.ll index 188a95fa950..def8e37c1a6 100644 --- a/test/Assembler/2004-01-11-getelementptrfolding.ll +++ b/test/Assembler/2004-01-11-getelementptrfolding.ll @@ -7,7 +7,7 @@ @data_triangleItems = internal constant [2908 x %struct.TTriangleItem] zeroinitializer; <[2908 x %struct.TTriangleItem]*> [#uses=2] define void @foo() { - store i16 0, i16* getelementptr ([2908 x %struct.TTriangleItem]* @data_triangleItems, i64 0, i64 0, i32 2, i64 0, i32 0) + store i16 0, i16* getelementptr ([2908 x %struct.TTriangleItem], [2908 x %struct.TTriangleItem]* @data_triangleItems, i64 0, i64 0, i32 2, i64 0, i32 0) ret void } diff --git a/test/Assembler/2007-01-05-Cmp-ConstExpr.ll b/test/Assembler/2007-01-05-Cmp-ConstExpr.ll index 5d1dd91ba91..81196293a72 100644 --- a/test/Assembler/2007-01-05-Cmp-ConstExpr.ll +++ b/test/Assembler/2007-01-05-Cmp-ConstExpr.ll @@ -8,7 +8,7 @@ define i32 @main(i32 %argc, i8** %argv) { entry: %tmp65 = getelementptr i8*, i8** %argv, i32 1 ; [#uses=1] %tmp66 = load i8*, i8** %tmp65 ; [#uses=0] - br i1 icmp ne (i32 sub (i32 ptrtoint (i8* getelementptr ([4 x i8]* @str, i32 0, i64 1) to i32), i32 ptrtoint ([4 x i8]* @str to i32)), i32 1), label %exit_1, label %exit_2 + br i1 icmp ne (i32 sub (i32 ptrtoint (i8* getelementptr ([4 x i8], [4 x i8]* @str, i32 0, i64 1) to i32), i32 ptrtoint ([4 x i8]* @str to i32)), i32 1), label %exit_1, label %exit_2 exit_1: ; preds = %entry ret i32 0 diff --git a/test/Assembler/2007-12-11-AddressSpaces.ll b/test/Assembler/2007-12-11-AddressSpaces.ll index 3d13f43602f..5155c6b8188 100644 --- a/test/Assembler/2007-12-11-AddressSpaces.ll +++ b/test/Assembler/2007-12-11-AddressSpaces.ll @@ -12,8 +12,8 @@ define void @foo() { entry: - %tmp1 = load i32 addrspace(33)*, i32 addrspace(33)* addrspace(42)* getelementptr (%struct.mystruct addrspace(42)* @input, i32 0, i32 3), align 4 ; [#uses=1] - store i32 addrspace(33)* %tmp1, i32 addrspace(33)* addrspace(66)* getelementptr (%struct.mystruct addrspace(66)* @output, i32 0, i32 1), align 4 + %tmp1 = load i32 addrspace(33)*, i32 addrspace(33)* addrspace(42)* getelementptr (%struct.mystruct, %struct.mystruct addrspace(42)* @input, i32 0, i32 3), align 4 ; [#uses=1] + store i32 addrspace(33)* %tmp1, i32 addrspace(33)* addrspace(66)* getelementptr (%struct.mystruct, %struct.mystruct addrspace(66)* @output, i32 0, i32 1), align 4 ret void } diff --git a/test/Assembler/2009-07-24-ZeroArgGEP.ll b/test/Assembler/2009-07-24-ZeroArgGEP.ll index 92f4d59d2f7..cd8b5d9827c 100644 --- a/test/Assembler/2009-07-24-ZeroArgGEP.ll +++ b/test/Assembler/2009-07-24-ZeroArgGEP.ll @@ -2,5 +2,5 @@ ; RUN: verify-uselistorder %s @foo = global i32 0 -@bar = constant i32* getelementptr(i32* @foo) +@bar = constant i32* getelementptr(i32, i32* @foo) diff --git a/test/Assembler/2010-02-05-FunctionLocalMetadataBecomesNull.ll b/test/Assembler/2010-02-05-FunctionLocalMetadataBecomesNull.ll index c8bfbe5c3b5..2dd4743862d 100644 --- a/test/Assembler/2010-02-05-FunctionLocalMetadataBecomesNull.ll +++ b/test/Assembler/2010-02-05-FunctionLocalMetadataBecomesNull.ll @@ -7,7 +7,7 @@ target triple = "x86_64-apple-darwin10.2" %struct.anon = type { i32, i32 } %struct.test = type { i64, %struct.anon, %struct.test* } -@TestArrayPtr = global %struct.test* getelementptr inbounds ([10 x %struct.test]* @TestArray, i64 0, i64 3) ; <%struct.test**> [#uses=1] +@TestArrayPtr = global %struct.test* getelementptr inbounds ([10 x %struct.test], [10 x %struct.test]* @TestArray, i64 0, i64 3) ; <%struct.test**> [#uses=1] @TestArray = common global [10 x %struct.test] zeroinitializer, align 32 ; <[10 x %struct.test]*> [#uses=2] define i32 @main() nounwind readonly { diff --git a/test/Assembler/ConstantExprFold.ll b/test/Assembler/ConstantExprFold.ll index dc413311513..3314f8c1af8 100644 --- a/test/Assembler/ConstantExprFold.ll +++ b/test/Assembler/ConstantExprFold.ll @@ -19,11 +19,11 @@ global i64* inttoptr (i64 xor (i64 ptrtoint (i64* @A to i64), i64 0) to i64*) ; %Ty = type { i32, i32 } @B = external global %Ty -global i1 icmp slt (i64* @A, i64* getelementptr (i64* @A, i64 1)) ; true -global i1 icmp ult (i64* @A, i64* getelementptr (i64* @A, i64 1)) ; true -global i1 icmp slt (i64* @A, i64* getelementptr (i64* @A, i64 0)) ; false -global i1 icmp slt (i32* getelementptr (%Ty* @B, i64 0, i32 0), - i32* getelementptr (%Ty* @B, i64 0, i32 1)) ; true +global i1 icmp slt (i64* @A, i64* getelementptr (i64, i64* @A, i64 1)) ; true +global i1 icmp ult (i64* @A, i64* getelementptr (i64, i64* @A, i64 1)) ; true +global i1 icmp slt (i64* @A, i64* getelementptr (i64, i64* @A, i64 0)) ; false +global i1 icmp slt (i32* getelementptr (%Ty, %Ty* @B, i64 0, i32 0), + i32* getelementptr (%Ty, %Ty* @B, i64 0, i32 1)) ; true ;global i1 icmp ne (i64* @A, i64* bitcast (%Ty* @B to i64*)) ; true ; PR2206 diff --git a/test/Assembler/ConstantExprNoFold.ll b/test/Assembler/ConstantExprNoFold.ll index 83236d5793b..38f8cbbc9cd 100644 --- a/test/Assembler/ConstantExprNoFold.ll +++ b/test/Assembler/ConstantExprNoFold.ll @@ -14,21 +14,21 @@ target datalayout = "p:32:32" ; icmp should return true. It's not valid to *dereference* in @B from a pointer ; based on @A, but icmp isn't a dereference. -; CHECK: @C = global i1 icmp eq (i64* getelementptr inbounds (i64* @A, i64 1), i64* @B) -@C = global i1 icmp eq (i64* getelementptr inbounds (i64* @A, i64 1), i64* @B) +; CHECK: @C = global i1 icmp eq (i64* getelementptr inbounds (i64, i64* @A, i64 1), i64* @B) +@C = global i1 icmp eq (i64* getelementptr inbounds (i64, i64* @A, i64 1), i64* @B) ; Don't fold this completely away either. In theory this could be simplified ; to only use a gep on one side of the icmp though. -; CHECK: @D = global i1 icmp eq (i64* getelementptr inbounds (i64* @A, i64 1), i64* getelementptr inbounds (i64* @B, i64 2)) -@D = global i1 icmp eq (i64* getelementptr inbounds (i64* @A, i64 1), i64* getelementptr inbounds (i64* @B, i64 2)) +; CHECK: @D = global i1 icmp eq (i64* getelementptr inbounds (i64, i64* @A, i64 1), i64* getelementptr inbounds (i64, i64* @B, i64 2)) +@D = global i1 icmp eq (i64* getelementptr inbounds (i64, i64* @A, i64 1), i64* getelementptr inbounds (i64, i64* @B, i64 2)) ; CHECK: @E = global i64 addrspace(1)* addrspacecast (i64* @A to i64 addrspace(1)*) @E = global i64 addrspace(1)* addrspacecast(i64* @A to i64 addrspace(1)*) ; Don't add an inbounds on @weak.gep, since @weak may be null. -; CHECK: @weak.gep = global i32* getelementptr (i32* @weak, i32 1) -@weak.gep = global i32* getelementptr (i32* @weak, i32 1) +; CHECK: @weak.gep = global i32* getelementptr (i32, i32* @weak, i32 1) +@weak.gep = global i32* getelementptr (i32, i32* @weak, i32 1) @weak = extern_weak global i32 ; An object with weak linkage cannot have it's identity determined at compile time. @@ -43,8 +43,8 @@ target datalayout = "p:32:32" @empty.cmp = global i1 icmp eq ([0 x i8]* @empty.1, [0 x i8]* @empty.2) ; Don't add an inbounds on @glob.a3, since it's not inbounds. -; CHECK: @glob.a3 = alias getelementptr (i32* @glob.a2, i32 1) +; CHECK: @glob.a3 = alias getelementptr (i32, i32* @glob.a2, i32 1) @glob = global i32 0 -@glob.a3 = alias getelementptr (i32* @glob.a2, i32 1) -@glob.a2 = alias getelementptr (i32* @glob.a1, i32 1) +@glob.a3 = alias getelementptr (i32, i32* @glob.a2, i32 1) +@glob.a2 = alias getelementptr (i32, i32* @glob.a1, i32 1) @glob.a1 = alias i32* @glob diff --git a/test/Assembler/alias-use-list-order.ll b/test/Assembler/alias-use-list-order.ll index d29fd6e435f..c72bad28e50 100644 --- a/test/Assembler/alias-use-list-order.ll +++ b/test/Assembler/alias-use-list-order.ll @@ -2,10 +2,10 @@ ; Globals. @global = global i32 0 -@alias.ref1 = global i32* getelementptr inbounds (i32* @alias, i64 1) -@alias.ref2 = global i32* getelementptr inbounds (i32* @alias, i64 1) +@alias.ref1 = global i32* getelementptr inbounds (i32, i32* @alias, i64 1) +@alias.ref2 = global i32* getelementptr inbounds (i32, i32* @alias, i64 1) ; Aliases. @alias = alias i32* @global -@alias.ref3 = alias i32* getelementptr inbounds (i32* @alias, i64 1) -@alias.ref4 = alias i32* getelementptr inbounds (i32* @alias, i64 1) +@alias.ref3 = alias i32* getelementptr inbounds (i32, i32* @alias, i64 1) +@alias.ref4 = alias i32* getelementptr inbounds (i32, i32* @alias, i64 1) diff --git a/test/Assembler/auto_upgrade_intrinsics.ll b/test/Assembler/auto_upgrade_intrinsics.ll index f16e5fee6c3..9a66a0defce 100644 --- a/test/Assembler/auto_upgrade_intrinsics.ll +++ b/test/Assembler/auto_upgrade_intrinsics.ll @@ -55,6 +55,6 @@ define i32 @test.objectsize() { ; CHECK-LABEL: @test.objectsize( ; CHECK: @llvm.objectsize.i32.p0i8 ; CHECK-DAG: declare i32 @llvm.objectsize.i32.p0i8 - %s = call i32 @llvm.objectsize.i32(i8* getelementptr inbounds ([60 x i8]* @a, i32 0, i32 0), i1 false) + %s = call i32 @llvm.objectsize.i32(i8* getelementptr inbounds ([60 x i8], [60 x i8]* @a, i32 0, i32 0), i1 false) ret i32 %s } diff --git a/test/Assembler/flags.ll b/test/Assembler/flags.ll index 9935fb552ae..bcbfb18d65a 100644 --- a/test/Assembler/flags.ll +++ b/test/Assembler/flags.ll @@ -195,8 +195,8 @@ define i64 @lshr_exact_ce() { } define i64* @gep_nw_ce() { -; CHECK: ret i64* getelementptr inbounds (i64* @addr, i64 171) - ret i64* getelementptr inbounds (i64* @addr, i64 171) +; CHECK: ret i64* getelementptr inbounds (i64, i64* @addr, i64 171) + ret i64* getelementptr inbounds (i64, i64* @addr, i64 171) } define i64 @add_plain_ce() { @@ -220,8 +220,8 @@ define i64 @sdiv_plain_ce() { } define i64* @gep_plain_ce() { -; CHECK: ret i64* getelementptr (i64* @addr, i64 171) - ret i64* getelementptr (i64* @addr, i64 171) +; CHECK: ret i64* getelementptr (i64, i64* @addr, i64 171) + ret i64* getelementptr (i64, i64* @addr, i64 171) } define i64 @add_both_reversed_ce() { diff --git a/test/Assembler/getelementptr.ll b/test/Assembler/getelementptr.ll index 5649d1b1a49..ee88346eb00 100644 --- a/test/Assembler/getelementptr.ll +++ b/test/Assembler/getelementptr.ll @@ -3,21 +3,21 @@ ; Verify that over-indexed getelementptrs are folded. @A = external global [2 x [3 x [5 x [7 x i32]]]] -@B = global i32* getelementptr ([2 x [3 x [5 x [7 x i32]]]]* @A, i64 0, i64 0, i64 2, i64 1, i64 7523) -; CHECK: @B = global i32* getelementptr ([2 x [3 x [5 x [7 x i32]]]]* @A, i64 36, i64 0, i64 1, i64 0, i64 5) -@C = global i32* getelementptr ([2 x [3 x [5 x [7 x i32]]]]* @A, i64 3, i64 2, i64 0, i64 0, i64 7523) -; CHECK: @C = global i32* getelementptr ([2 x [3 x [5 x [7 x i32]]]]* @A, i64 39, i64 1, i64 1, i64 4, i64 5) +@B = global i32* getelementptr ([2 x [3 x [5 x [7 x i32]]]], [2 x [3 x [5 x [7 x i32]]]]* @A, i64 0, i64 0, i64 2, i64 1, i64 7523) +; CHECK: @B = global i32* getelementptr ([2 x [3 x [5 x [7 x i32]]]], [2 x [3 x [5 x [7 x i32]]]]* @A, i64 36, i64 0, i64 1, i64 0, i64 5) +@C = global i32* getelementptr ([2 x [3 x [5 x [7 x i32]]]], [2 x [3 x [5 x [7 x i32]]]]* @A, i64 3, i64 2, i64 0, i64 0, i64 7523) +; CHECK: @C = global i32* getelementptr ([2 x [3 x [5 x [7 x i32]]]], [2 x [3 x [5 x [7 x i32]]]]* @A, i64 39, i64 1, i64 1, i64 4, i64 5) ; Verify that constant expression GEPs work with i84 indices. @D = external global [1 x i32] -@E = global i32* getelementptr inbounds ([1 x i32]* @D, i84 0, i64 1) -; CHECK: @E = global i32* getelementptr inbounds ([1 x i32]* @D, i84 1, i64 0) +@E = global i32* getelementptr inbounds ([1 x i32], [1 x i32]* @D, i84 0, i64 1) +; CHECK: @E = global i32* getelementptr inbounds ([1 x i32], [1 x i32]* @D, i84 1, i64 0) ; Verify that i16 indices work. @x = external global {i32, i32} -@y = global i32* getelementptr ({ i32, i32 }* @x, i16 42, i32 0) -; CHECK: @y = global i32* getelementptr ({ i32, i32 }* @x, i16 42, i32 0) +@y = global i32* getelementptr ({ i32, i32 }, { i32, i32 }* @x, i16 42, i32 0) +; CHECK: @y = global i32* getelementptr ({ i32, i32 }, { i32, i32 }* @x, i16 42, i32 0) ; See if i92 indices work too. define i32 *@test({i32, i32}* %t, i92 %n) { @@ -29,7 +29,7 @@ define i32 *@test({i32, i32}* %t, i92 %n) { ; Verify that constant expression vector GEPs work. -@z = global <2 x i32*> getelementptr (<2 x [3 x {i32, i32}]*> zeroinitializer, <2 x i32> , <2 x i32> , <2 x i32> ) +@z = global <2 x i32*> getelementptr ([3 x {i32, i32}], <2 x [3 x {i32, i32}]*> zeroinitializer, <2 x i32> , <2 x i32> , <2 x i32> ) ; Verify that struct GEP works with a vector of pointers. define <2 x i32*> @test7(<2 x {i32, i32}*> %a) { diff --git a/test/Assembler/getelementptr_vec_idx4.ll b/test/Assembler/getelementptr_vec_idx4.ll index 08fe43461c9..f270a0c7810 100644 --- a/test/Assembler/getelementptr_vec_idx4.ll +++ b/test/Assembler/getelementptr_vec_idx4.ll @@ -2,4 +2,4 @@ ; CHECK: getelementptr vector index has a wrong number of elements -global <2 x i32*> getelementptr (<4 x [3 x {i32, i32}]*> zeroinitializer, <2 x i32> , <2 x i32> , <2 x i32> ) +global <2 x i32*> getelementptr ([3 x {i32, i32}], <4 x [3 x {i32, i32}]*> zeroinitializer, <2 x i32> , <2 x i32> , <2 x i32> ) diff --git a/test/Assembler/uselistorder.ll b/test/Assembler/uselistorder.ll index 873e160737c..2475fc48caf 100644 --- a/test/Assembler/uselistorder.ll +++ b/test/Assembler/uselistorder.ll @@ -4,7 +4,7 @@ ; RUN: verify-uselistorder < %s @a = global [4 x i1] [i1 0, i1 1, i1 0, i1 1] -@b = alias i1* getelementptr ([4 x i1]* @a, i64 0, i64 2) +@b = alias i1* getelementptr ([4 x i1], [4 x i1]* @a, i64 0, i64 2) ; Check use-list order of constants used by globals. @glob1 = global i5 7 @@ -48,9 +48,9 @@ first: define i1 @loada() { entry: - %a = load i1, i1* getelementptr ([4 x i1]* @a, i64 0, i64 2) + %a = load i1, i1* getelementptr ([4 x i1], [4 x i1]* @a, i64 0, i64 2) ret i1 %a } uselistorder i5 7, { 1, 0, 2 } -uselistorder i1* getelementptr ([4 x i1]* @a, i64 0, i64 2), { 1, 0 } +uselistorder i1* getelementptr ([4 x i1], [4 x i1]* @a, i64 0, i64 2), { 1, 0 } diff --git a/test/Assembler/uselistorder_bb.ll b/test/Assembler/uselistorder_bb.ll index 11ae57b299c..4da85bc3baf 100644 --- a/test/Assembler/uselistorder_bb.ll +++ b/test/Assembler/uselistorder_bb.ll @@ -4,11 +4,11 @@ ; RUN: verify-uselistorder < %s @ba1 = constant i8* blockaddress (@bafunc1, %bb) -@ba2 = constant i8* getelementptr (i8* blockaddress (@bafunc2, %bb), i61 0) -@ba3 = constant i8* getelementptr (i8* blockaddress (@bafunc2, %bb), i61 0) +@ba2 = constant i8* getelementptr (i8, i8* blockaddress (@bafunc2, %bb), i61 0) +@ba3 = constant i8* getelementptr (i8, i8* blockaddress (@bafunc2, %bb), i61 0) define i8* @babefore() { - ret i8* getelementptr (i8* blockaddress (@bafunc2, %bb), i61 0) + ret i8* getelementptr (i8, i8* blockaddress (@bafunc2, %bb), i61 0) bb1: ret i8* blockaddress (@bafunc1, %bb) bb2: diff --git a/test/Bitcode/memInstructions.3.2.ll b/test/Bitcode/memInstructions.3.2.ll index f430086e96a..1ab05b6d1b4 100644 --- a/test/Bitcode/memInstructions.3.2.ll +++ b/test/Bitcode/memInstructions.3.2.ll @@ -311,7 +311,7 @@ entry: ret void } -define void @getelementptr({i8, i8}* %s, <4 x i8*> %ptrs, <4 x i64> %offsets ){ +define void @getelementptr({i8, i8}, {i8, i8}* %s, <4 x i8*> %ptrs, <4 x i64> %offsets ){ entry: ; CHECK: %res1 = getelementptr { i8, i8 }, { i8, i8 }* %s, i32 1, i32 1 %res1 = getelementptr {i8, i8}, {i8, i8}* %s, i32 1, i32 1 diff --git a/test/Bitcode/metadata-2.ll b/test/Bitcode/metadata-2.ll index a5367da4af3..e9065261043 100644 --- a/test/Bitcode/metadata-2.ll +++ b/test/Bitcode/metadata-2.ll @@ -21,7 +21,7 @@ %"void*[]" = type { i64, i8** } @_D10ModuleInfo6__vtblZ = external constant %object.ModuleInfo.__vtbl ; <%object.ModuleInfo.__vtbl*> [#uses=1] @.str = internal constant [20 x i8] c"tango.core.BitManip\00" ; <[20 x i8]*> [#uses=1] -@_D5tango4core8BitManip8__ModuleZ = global %0 { %object.ModuleInfo.__vtbl* @_D10ModuleInfo6__vtblZ, i8* null, %"byte[]" { i64 19, i8* getelementptr ([20 x i8]* @.str, i32 0, i32 0) }, %1 zeroinitializer, %"ClassInfo[]" zeroinitializer, i32 4, void ()* null, void ()* null, void ()* null, i8* null, void ()* null } ; <%0*> [#uses=1] +@_D5tango4core8BitManip8__ModuleZ = global %0 { %object.ModuleInfo.__vtbl* @_D10ModuleInfo6__vtblZ, i8* null, %"byte[]" { i64 19, i8* getelementptr ([20 x i8], [20 x i8]* @.str, i32 0, i32 0) }, %1 zeroinitializer, %"ClassInfo[]" zeroinitializer, i32 4, void ()* null, void ()* null, void ()* null, i8* null, void ()* null } ; <%0*> [#uses=1] @_D5tango4core8BitManip11__moduleRefZ = internal global %ModuleReference { %ModuleReference* null, %object.ModuleInfo* bitcast (%0* @_D5tango4core8BitManip8__ModuleZ to %object.ModuleInfo*) } ; <%ModuleReference*> [#uses=2] @_Dmodule_ref = external global %ModuleReference* ; <%ModuleReference**> [#uses=2] @llvm.global_ctors = appending constant [1 x %2] [%2 { i32 65535, void ()* @_D5tango4core8BitManip16__moduleinfoCtorZ }] ; <[1 x %2]*> [#uses=0] @@ -78,7 +78,7 @@ entry: define internal void @_D5tango4core8BitManip16__moduleinfoCtorZ() nounwind { moduleinfoCtorEntry: %current = load %ModuleReference*, %ModuleReference** @_Dmodule_ref ; <%ModuleReference*> [#uses=1] - store %ModuleReference* %current, %ModuleReference** getelementptr (%ModuleReference* @_D5tango4core8BitManip11__moduleRefZ, i32 0, i32 0) + store %ModuleReference* %current, %ModuleReference** getelementptr (%ModuleReference, %ModuleReference* @_D5tango4core8BitManip11__moduleRefZ, i32 0, i32 0) store %ModuleReference* @_D5tango4core8BitManip11__moduleRefZ, %ModuleReference** @_Dmodule_ref ret void } diff --git a/test/Bitcode/old-aliases.ll b/test/Bitcode/old-aliases.ll index b73b1a90afb..8527f074d04 100644 --- a/test/Bitcode/old-aliases.ll +++ b/test/Bitcode/old-aliases.ll @@ -13,8 +13,8 @@ @v3 = alias bitcast (i32* @v1 to i16*) ; CHECK: @v3 = alias bitcast (i32* @v1 to i16*) -@v4 = alias getelementptr ([1 x i32]* @v2, i32 0, i32 0) -; CHECK: @v4 = alias getelementptr inbounds ([1 x i32]* @v2, i32 0, i32 0) +@v4 = alias getelementptr ([1 x i32], [1 x i32]* @v2, i32 0, i32 0) +; CHECK: @v4 = alias getelementptr inbounds ([1 x i32], [1 x i32]* @v2, i32 0, i32 0) @v5 = alias i32 addrspace(2)* addrspacecast (i32 addrspace(0)* @v1 to i32 addrspace(2)*) ; CHECK: @v5 = alias addrspacecast (i32* @v1 to i32 addrspace(2)*) diff --git a/test/Bitcode/use-list-order.ll b/test/Bitcode/use-list-order.ll index f57b4a67e36..09ec44897e7 100644 --- a/test/Bitcode/use-list-order.ll +++ b/test/Bitcode/use-list-order.ll @@ -1,7 +1,7 @@ ; RUN: verify-uselistorder < %s @a = global [4 x i1] [i1 0, i1 1, i1 0, i1 1] -@b = alias i1* getelementptr ([4 x i1]* @a, i64 0, i64 2) +@b = alias i1* getelementptr ([4 x i1], [4 x i1]* @a, i64 0, i64 2) ; Check use-list order of constants used by globals. @glob1 = global i5 7 @@ -85,7 +85,7 @@ entry: define i1 @loada() { entry: - %a = load i1, i1* getelementptr ([4 x i1]* @a, i64 0, i64 2) + %a = load i1, i1* getelementptr ([4 x i1], [4 x i1]* @a, i64 0, i64 2) ret i1 %a } @@ -134,11 +134,11 @@ loop2: ; Check that block addresses work. @ba1 = constant i8* blockaddress (@bafunc1, %bb) -@ba2 = constant i8* getelementptr (i8* blockaddress (@bafunc2, %bb), i61 0) -@ba3 = constant i8* getelementptr (i8* blockaddress (@bafunc2, %bb), i61 0) +@ba2 = constant i8* getelementptr (i8, i8* blockaddress (@bafunc2, %bb), i61 0) +@ba3 = constant i8* getelementptr (i8, i8* blockaddress (@bafunc2, %bb), i61 0) define i8* @babefore() { - ret i8* getelementptr (i8* blockaddress (@bafunc2, %bb), i61 0) + ret i8* getelementptr (i8, i8* blockaddress (@bafunc2, %bb), i61 0) bb1: ret i8* blockaddress (@bafunc1, %bb) bb2: diff --git a/test/CodeGen/AArch64/arm64-2012-06-06-FPToUI.ll b/test/CodeGen/AArch64/arm64-2012-06-06-FPToUI.ll index 04364b01eb5..41e22e95f62 100644 --- a/test/CodeGen/AArch64/arm64-2012-06-06-FPToUI.ll +++ b/test/CodeGen/AArch64/arm64-2012-06-06-FPToUI.ll @@ -16,11 +16,11 @@ entry: %0 = load double, double* %d.addr, align 8 %1 = load double, double* %d.addr, align 8 %conv = fptoui double %1 to i64 - %call = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([9 x i8]* @.str, i32 0, i32 0), double %0, i64 %conv) + %call = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i32 0, i32 0), double %0, i64 %conv) %2 = load double, double* %d.addr, align 8 %3 = load double, double* %d.addr, align 8 %conv1 = fptoui double %3 to i32 - %call2 = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([8 x i8]* @.str1, i32 0, i32 0), double %2, i32 %conv1) + %call2 = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str1, i32 0, i32 0), double %2, i32 %conv1) ret void } @@ -37,12 +37,12 @@ entry: %conv = fpext float %0 to double %1 = load float, float* %f.addr, align 4 %conv1 = fptoui float %1 to i64 - %call = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([8 x i8]* @.str2, i32 0, i32 0), double %conv, i64 %conv1) + %call = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str2, i32 0, i32 0), double %conv, i64 %conv1) %2 = load float, float* %f.addr, align 4 %conv2 = fpext float %2 to double %3 = load float, float* %f.addr, align 4 %conv3 = fptoui float %3 to i32 - %call4 = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([7 x i8]* @.str3, i32 0, i32 0), double %conv2, i32 %conv3) + %call4 = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str3, i32 0, i32 0), double %conv2, i32 %conv3) ret void } diff --git a/test/CodeGen/AArch64/arm64-abi-varargs.ll b/test/CodeGen/AArch64/arm64-abi-varargs.ll index b6826e1fa56..f95fec66158 100644 --- a/test/CodeGen/AArch64/arm64-abi-varargs.ll +++ b/test/CodeGen/AArch64/arm64-abi-varargs.ll @@ -133,7 +133,7 @@ entry: store <4 x i32> %y, <4 x i32>* %y.addr, align 16 %0 = load i32, i32* %x.addr, align 4 %1 = load <4 x i32>, <4 x i32>* %y.addr, align 16 - call void (i8*, ...)* @foo(i8* getelementptr inbounds ([4 x i8]* @.str, i32 0, i32 0), i32 %0, <4 x i32> %1) + call void (i8*, ...)* @foo(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i32 0, i32 0), i32 %0, <4 x i32> %1) ret void } @@ -186,6 +186,6 @@ entry: %1 = load i32, i32* %x.addr, align 4 %2 = bitcast %struct.s41* %s41 to i128* %3 = load i128, i128* %2, align 1 - call void (i8*, ...)* @foo2(i8* getelementptr inbounds ([4 x i8]* @.str, i32 0, i32 0), i32 %1, i128 %3) + call void (i8*, ...)* @foo2(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i32 0, i32 0), i32 %1, i128 %3) ret void } diff --git a/test/CodeGen/AArch64/arm64-atomic.ll b/test/CodeGen/AArch64/arm64-atomic.ll index 81b555a42d1..451e7e02f99 100644 --- a/test/CodeGen/AArch64/arm64-atomic.ll +++ b/test/CodeGen/AArch64/arm64-atomic.ll @@ -319,13 +319,13 @@ define void @atomic_store_relaxed_64(i64* %p, i32 %off32, i64 %val) { define i32 @next_id() nounwind optsize ssp align 2 { entry: - %0 = atomicrmw add i32* getelementptr inbounds (%"class.X::Atomic"* @counter, i64 0, i32 0, i32 0), i32 1 seq_cst + %0 = atomicrmw add i32* getelementptr inbounds (%"class.X::Atomic", %"class.X::Atomic"* @counter, i64 0, i32 0, i32 0), i32 1 seq_cst %add.i = add i32 %0, 1 %tobool = icmp eq i32 %add.i, 0 br i1 %tobool, label %if.else, label %return if.else: ; preds = %entry - %1 = atomicrmw add i32* getelementptr inbounds (%"class.X::Atomic"* @counter, i64 0, i32 0, i32 0), i32 1 seq_cst + %1 = atomicrmw add i32* getelementptr inbounds (%"class.X::Atomic", %"class.X::Atomic"* @counter, i64 0, i32 0, i32 0), i32 1 seq_cst %add.i2 = add i32 %1, 1 br label %return diff --git a/test/CodeGen/AArch64/arm64-collect-loh-str.ll b/test/CodeGen/AArch64/arm64-collect-loh-str.ll index d7bc00e318f..8889cb4bf52 100644 --- a/test/CodeGen/AArch64/arm64-collect-loh-str.ll +++ b/test/CodeGen/AArch64/arm64-collect-loh-str.ll @@ -15,8 +15,8 @@ ; CHECK-NOT: AdrpAddStr define i32 @pptp_wan_init() { entry: - store i32* null, i32** getelementptr inbounds (%struct.anon* @pptp_wan_head, i64 0, i32 0), align 8 - store i32** getelementptr inbounds (%struct.anon* @pptp_wan_head, i64 0, i32 0), i32*** getelementptr inbounds (%struct.anon* @pptp_wan_head, i64 0, i32 1), align 8 + store i32* null, i32** getelementptr inbounds (%struct.anon, %struct.anon* @pptp_wan_head, i64 0, i32 0), align 8 + store i32** getelementptr inbounds (%struct.anon, %struct.anon* @pptp_wan_head, i64 0, i32 0), i32*** getelementptr inbounds (%struct.anon, %struct.anon* @pptp_wan_head, i64 0, i32 1), align 8 ret i32 0 } diff --git a/test/CodeGen/AArch64/arm64-fast-isel-addr-offset.ll b/test/CodeGen/AArch64/arm64-fast-isel-addr-offset.ll index 3a14c7e58d8..e4dc948c460 100644 --- a/test/CodeGen/AArch64/arm64-fast-isel-addr-offset.ll +++ b/test/CodeGen/AArch64/arm64-fast-isel-addr-offset.ll @@ -13,7 +13,7 @@ entry: ; CHECK: add x[[REG3:[0-9]+]], x[[REG1]], x[[REG2]] ; CHECK: ldr w0, [x[[REG3]]] ; CHECK: ret - %0 = load i32, i32* getelementptr inbounds ([5001 x i32]* @sortlist, i32 0, i64 5000), align 4 + %0 = load i32, i32* getelementptr inbounds ([5001 x i32], [5001 x i32]* @sortlist, i32 0, i64 5000), align 4 ret i32 %0 } @@ -26,7 +26,7 @@ entry: ; CHECK: add x[[REG3:[0-9]+]], x[[REG1]], x[[REG2]] ; CHECK: ldr x0, [x[[REG3]]] ; CHECK: ret - %0 = load i64, i64* getelementptr inbounds ([5001 x i64]* @sortlist2, i32 0, i64 5000), align 4 + %0 = load i64, i64* getelementptr inbounds ([5001 x i64], [5001 x i64]* @sortlist2, i32 0, i64 5000), align 4 ret i64 %0 } diff --git a/test/CodeGen/AArch64/arm64-fast-isel-intrinsic.ll b/test/CodeGen/AArch64/arm64-fast-isel-intrinsic.ll index e6a6aaf5645..bb2889eaf4b 100644 --- a/test/CodeGen/AArch64/arm64-fast-isel-intrinsic.ll +++ b/test/CodeGen/AArch64/arm64-fast-isel-intrinsic.ll @@ -11,7 +11,7 @@ define void @t1() { ; ARM64: movz x2, #0x50 ; ARM64: uxtb w1, w9 ; ARM64: bl _memset - call void @llvm.memset.p0i8.i64(i8* getelementptr inbounds ([80 x i8]* @message, i32 0, i32 0), i8 0, i64 80, i32 16, i1 false) + call void @llvm.memset.p0i8.i64(i8* getelementptr inbounds ([80 x i8], [80 x i8]* @message, i32 0, i32 0), i8 0, i64 80, i32 16, i1 false) ret void } @@ -25,7 +25,7 @@ define void @t2() { ; ARM64: add x1, x8, _message@PAGEOFF ; ARM64: movz x2, #0x50 ; ARM64: bl _memcpy - call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8]* @message, i32 0, i32 0), i64 80, i32 16, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8], [80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8], [80 x i8]* @message, i32 0, i32 0), i64 80, i32 16, i1 false) ret void } @@ -39,7 +39,7 @@ define void @t3() { ; ARM64: add x1, x8, _message@PAGEOFF ; ARM64: movz x2, #0x14 ; ARM64: bl _memmove - call void @llvm.memmove.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8]* @message, i32 0, i32 0), i64 20, i32 16, i1 false) + call void @llvm.memmove.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8], [80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8], [80 x i8]* @message, i32 0, i32 0), i64 20, i32 16, i1 false) ret void } @@ -58,7 +58,7 @@ define void @t4() { ; ARM64: ldrb w11, [x9, #16] ; ARM64: strb w11, [x8, #16] ; ARM64: ret - call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8]* @message, i32 0, i32 0), i64 17, i32 16, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8], [80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8], [80 x i8]* @message, i32 0, i32 0), i64 17, i32 16, i1 false) ret void } @@ -75,7 +75,7 @@ define void @t5() { ; ARM64: ldrb w11, [x9, #16] ; ARM64: strb w11, [x8, #16] ; ARM64: ret - call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8]* @message, i32 0, i32 0), i64 17, i32 8, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8], [80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8], [80 x i8]* @message, i32 0, i32 0), i64 17, i32 8, i1 false) ret void } @@ -92,7 +92,7 @@ define void @t6() { ; ARM64: ldrb w10, [x9, #8] ; ARM64: strb w10, [x8, #8] ; ARM64: ret - call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8]* @message, i32 0, i32 0), i64 9, i32 4, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8], [80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8], [80 x i8]* @message, i32 0, i32 0), i64 9, i32 4, i1 false) ret void } @@ -111,7 +111,7 @@ define void @t7() { ; ARM64: ldrb w10, [x9, #6] ; ARM64: strb w10, [x8, #6] ; ARM64: ret - call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8]* @message, i32 0, i32 0), i64 7, i32 2, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8], [80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8], [80 x i8]* @message, i32 0, i32 0), i64 7, i32 2, i1 false) ret void } @@ -130,7 +130,7 @@ define void @t8() { ; ARM64: ldrb w10, [x9, #3] ; ARM64: strb w10, [x8, #3] ; ARM64: ret - call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8]* @message, i32 0, i32 0), i64 4, i32 1, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([80 x i8], [80 x i8]* @temp, i32 0, i32 0), i8* getelementptr inbounds ([80 x i8], [80 x i8]* @message, i32 0, i32 0), i64 4, i32 1, i1 false) ret void } diff --git a/test/CodeGen/AArch64/arm64-hello.ll b/test/CodeGen/AArch64/arm64-hello.ll index a6346fb467f..f1c4e9bbaed 100644 --- a/test/CodeGen/AArch64/arm64-hello.ll +++ b/test/CodeGen/AArch64/arm64-hello.ll @@ -31,7 +31,7 @@ define i32 @main() nounwind ssp { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval - %call = call i32 @puts(i8* getelementptr inbounds ([7 x i8]* @.str, i32 0, i32 0)) + %call = call i32 @puts(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i32 0, i32 0)) ret i32 %call } diff --git a/test/CodeGen/AArch64/arm64-memcpy-inline.ll b/test/CodeGen/AArch64/arm64-memcpy-inline.ll index f921a592451..2f91ce25233 100644 --- a/test/CodeGen/AArch64/arm64-memcpy-inline.ll +++ b/test/CodeGen/AArch64/arm64-memcpy-inline.ll @@ -22,7 +22,7 @@ entry: ; CHECK: strh [[REG1]], [x[[BASEREG2]], #8] ; CHECK: ldr [[REG2:x[0-9]+]], ; CHECK: str [[REG2]], - call void @llvm.memcpy.p0i8.p0i8.i32(i8* getelementptr inbounds (%struct.x* @dst, i32 0, i32 0), i8* getelementptr inbounds (%struct.x* @src, i32 0, i32 0), i32 11, i32 8, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i32(i8* getelementptr inbounds (%struct.x, %struct.x* @dst, i32 0, i32 0), i8* getelementptr inbounds (%struct.x, %struct.x* @src, i32 0, i32 0), i32 11, i32 8, i1 false) ret i32 0 } @@ -33,7 +33,7 @@ entry: ; CHECK: stur [[DEST]], [x0, #15] ; CHECK: ldr [[DEST:q[0-9]+]], [x[[BASEREG]]] ; CHECK: str [[DEST]], [x0] - tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* %C, i8* getelementptr inbounds ([31 x i8]* @.str1, i64 0, i64 0), i64 31, i32 1, i1 false) + tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* %C, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str1, i64 0, i64 0), i64 31, i32 1, i1 false) ret void } @@ -45,7 +45,7 @@ entry: ; CHECK: str [[REG3]], [x0, #32] ; CHECK: ldp [[DEST1:q[0-9]+]], [[DEST2:q[0-9]+]], [x{{[0-9]+}}] ; CHECK: stp [[DEST1]], [[DEST2]], [x0] - tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* %C, i8* getelementptr inbounds ([36 x i8]* @.str2, i64 0, i64 0), i64 36, i32 1, i1 false) + tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* %C, i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str2, i64 0, i64 0), i64 36, i32 1, i1 false) ret void } @@ -56,7 +56,7 @@ entry: ; CHECK: str [[REG4]], [x0, #16] ; CHECK: ldr [[DEST:q[0-9]+]], [x[[BASEREG]]] ; CHECK: str [[DEST]], [x0] - tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* %C, i8* getelementptr inbounds ([24 x i8]* @.str3, i64 0, i64 0), i64 24, i32 1, i1 false) + tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* %C, i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str3, i64 0, i64 0), i64 24, i32 1, i1 false) ret void } @@ -67,7 +67,7 @@ entry: ; CHECK: strh [[REG5]], [x0, #16] ; CHECK: ldr [[REG6:q[0-9]+]], [x{{[0-9]+}}] ; CHECK: str [[REG6]], [x0] - tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* %C, i8* getelementptr inbounds ([18 x i8]* @.str4, i64 0, i64 0), i64 18, i32 1, i1 false) + tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* %C, i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str4, i64 0, i64 0), i64 18, i32 1, i1 false) ret void } @@ -80,7 +80,7 @@ entry: ; CHECK: movz [[REG8:w[0-9]+]], ; CHECK: movk [[REG8]], ; CHECK: str [[REG8]], [x0] - tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* %C, i8* getelementptr inbounds ([7 x i8]* @.str5, i64 0, i64 0), i64 7, i32 1, i1 false) + tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* %C, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str5, i64 0, i64 0), i64 7, i32 1, i1 false) ret void } @@ -91,7 +91,7 @@ entry: ; CHECK: stur [[REG9]], [x{{[0-9]+}}, #6] ; CHECK: ldr ; CHECK: str - call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([512 x i8]* @spool.splbuf, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8]* @.str6, i64 0, i64 0), i64 14, i32 1, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds ([512 x i8], [512 x i8]* @spool.splbuf, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str6, i64 0, i64 0), i64 14, i32 1, i1 false) ret void } diff --git a/test/CodeGen/AArch64/arm64-pic-local-symbol.ll b/test/CodeGen/AArch64/arm64-pic-local-symbol.ll index c242f789579..dae243e8da2 100644 --- a/test/CodeGen/AArch64/arm64-pic-local-symbol.ll +++ b/test/CodeGen/AArch64/arm64-pic-local-symbol.ll @@ -15,7 +15,7 @@ define void @foo() nounwind { ; CHECK: foo: ; CHECK: adrp x{{[0-9]}}, .L.str ; CHECK-NEXT: add x{{[0-9]}}, x{{[0-9]}}, :lo12:.L.str - tail call void @bar(i8* getelementptr inbounds ([6 x i8]* @.str, i64 0, i64 0)) + tail call void @bar(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0)) ret void } diff --git a/test/CodeGen/AArch64/arm64-vector-ldst.ll b/test/CodeGen/AArch64/arm64-vector-ldst.ll index c58c199b029..26b9d62c8f6 100644 --- a/test/CodeGen/AArch64/arm64-vector-ldst.ll +++ b/test/CodeGen/AArch64/arm64-vector-ldst.ll @@ -270,7 +270,7 @@ define <1 x i64> @fct0() nounwind readonly ssp { entry: ; CHECK-LABEL: fct0: ; CHECK: ldur {{d[0-9]+}}, [{{x[0-9]+}}, #3] - %0 = load <1 x i64>, <1 x i64>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <1 x i64>*), align 8 + %0 = load <1 x i64>, <1 x i64>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <1 x i64>*), align 8 ret <1 x i64> %0 } @@ -278,7 +278,7 @@ define <2 x i32> @fct1() nounwind readonly ssp { entry: ; CHECK-LABEL: fct1: ; CHECK: ldur {{d[0-9]+}}, [{{x[0-9]+}}, #3] - %0 = load <2 x i32>, <2 x i32>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <2 x i32>*), align 8 + %0 = load <2 x i32>, <2 x i32>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <2 x i32>*), align 8 ret <2 x i32> %0 } @@ -286,7 +286,7 @@ define <4 x i16> @fct2() nounwind readonly ssp { entry: ; CHECK-LABEL: fct2: ; CHECK: ldur {{d[0-9]+}}, [{{x[0-9]+}}, #3] - %0 = load <4 x i16>, <4 x i16>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <4 x i16>*), align 8 + %0 = load <4 x i16>, <4 x i16>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <4 x i16>*), align 8 ret <4 x i16> %0 } @@ -294,7 +294,7 @@ define <8 x i8> @fct3() nounwind readonly ssp { entry: ; CHECK-LABEL: fct3: ; CHECK: ldur {{d[0-9]+}}, [{{x[0-9]+}}, #3] - %0 = load <8 x i8>, <8 x i8>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <8 x i8>*), align 8 + %0 = load <8 x i8>, <8 x i8>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <8 x i8>*), align 8 ret <8 x i8> %0 } @@ -302,7 +302,7 @@ define <2 x i64> @fct4() nounwind readonly ssp { entry: ; CHECK-LABEL: fct4: ; CHECK: ldur {{q[0-9]+}}, [{{x[0-9]+}}, #3] - %0 = load <2 x i64>, <2 x i64>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <2 x i64>*), align 16 + %0 = load <2 x i64>, <2 x i64>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <2 x i64>*), align 16 ret <2 x i64> %0 } @@ -310,7 +310,7 @@ define <4 x i32> @fct5() nounwind readonly ssp { entry: ; CHECK-LABEL: fct5: ; CHECK: ldur {{q[0-9]+}}, [{{x[0-9]+}}, #3] - %0 = load <4 x i32>, <4 x i32>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <4 x i32>*), align 16 + %0 = load <4 x i32>, <4 x i32>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <4 x i32>*), align 16 ret <4 x i32> %0 } @@ -318,7 +318,7 @@ define <8 x i16> @fct6() nounwind readonly ssp { entry: ; CHECK-LABEL: fct6: ; CHECK: ldur {{q[0-9]+}}, [{{x[0-9]+}}, #3] - %0 = load <8 x i16>, <8 x i16>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <8 x i16>*), align 16 + %0 = load <8 x i16>, <8 x i16>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <8 x i16>*), align 16 ret <8 x i16> %0 } @@ -326,7 +326,7 @@ define <16 x i8> @fct7() nounwind readonly ssp { entry: ; CHECK-LABEL: fct7: ; CHECK: ldur {{q[0-9]+}}, [{{x[0-9]+}}, #3] - %0 = load <16 x i8>, <16 x i8>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <16 x i8>*), align 16 + %0 = load <16 x i8>, <16 x i8>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <16 x i8>*), align 16 ret <16 x i8> %0 } @@ -335,8 +335,8 @@ entry: ; CHECK-LABEL: fct8: ; CHECK: ldur [[DESTREG:d[0-9]+]], {{\[}}[[BASEREG:x[0-9]+]], #3] ; CHECK: stur [[DESTREG]], {{\[}}[[BASEREG]], #4] - %0 = load <1 x i64>, <1 x i64>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <1 x i64>*), align 8 - store <1 x i64> %0, <1 x i64>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 4) to <1 x i64>*), align 8 + %0 = load <1 x i64>, <1 x i64>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <1 x i64>*), align 8 + store <1 x i64> %0, <1 x i64>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 4) to <1 x i64>*), align 8 ret void } @@ -345,8 +345,8 @@ entry: ; CHECK-LABEL: fct9: ; CHECK: ldur [[DESTREG:d[0-9]+]], {{\[}}[[BASEREG:x[0-9]+]], #3] ; CHECK: stur [[DESTREG]], {{\[}}[[BASEREG]], #4] - %0 = load <2 x i32>, <2 x i32>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <2 x i32>*), align 8 - store <2 x i32> %0, <2 x i32>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 4) to <2 x i32>*), align 8 + %0 = load <2 x i32>, <2 x i32>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <2 x i32>*), align 8 + store <2 x i32> %0, <2 x i32>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 4) to <2 x i32>*), align 8 ret void } @@ -355,8 +355,8 @@ entry: ; CHECK-LABEL: fct10: ; CHECK: ldur [[DESTREG:d[0-9]+]], {{\[}}[[BASEREG:x[0-9]+]], #3] ; CHECK: stur [[DESTREG]], {{\[}}[[BASEREG]], #4] - %0 = load <4 x i16>, <4 x i16>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <4 x i16>*), align 8 - store <4 x i16> %0, <4 x i16>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 4) to <4 x i16>*), align 8 + %0 = load <4 x i16>, <4 x i16>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <4 x i16>*), align 8 + store <4 x i16> %0, <4 x i16>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 4) to <4 x i16>*), align 8 ret void } @@ -365,8 +365,8 @@ entry: ; CHECK-LABEL: fct11: ; CHECK: ldur [[DESTREG:d[0-9]+]], {{\[}}[[BASEREG:x[0-9]+]], #3] ; CHECK: stur [[DESTREG]], {{\[}}[[BASEREG]], #4] - %0 = load <8 x i8>, <8 x i8>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <8 x i8>*), align 8 - store <8 x i8> %0, <8 x i8>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 4) to <8 x i8>*), align 8 + %0 = load <8 x i8>, <8 x i8>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <8 x i8>*), align 8 + store <8 x i8> %0, <8 x i8>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 4) to <8 x i8>*), align 8 ret void } @@ -375,8 +375,8 @@ entry: ; CHECK-LABEL: fct12: ; CHECK: ldur [[DESTREG:q[0-9]+]], {{\[}}[[BASEREG:x[0-9]+]], #3] ; CHECK: stur [[DESTREG]], {{\[}}[[BASEREG]], #4] - %0 = load <2 x i64>, <2 x i64>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <2 x i64>*), align 16 - store <2 x i64> %0, <2 x i64>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 4) to <2 x i64>*), align 16 + %0 = load <2 x i64>, <2 x i64>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <2 x i64>*), align 16 + store <2 x i64> %0, <2 x i64>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 4) to <2 x i64>*), align 16 ret void } @@ -385,8 +385,8 @@ entry: ; CHECK-LABEL: fct13: ; CHECK: ldur [[DESTREG:q[0-9]+]], {{\[}}[[BASEREG:x[0-9]+]], #3] ; CHECK: stur [[DESTREG]], {{\[}}[[BASEREG]], #4] - %0 = load <4 x i32>, <4 x i32>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <4 x i32>*), align 16 - store <4 x i32> %0, <4 x i32>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 4) to <4 x i32>*), align 16 + %0 = load <4 x i32>, <4 x i32>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <4 x i32>*), align 16 + store <4 x i32> %0, <4 x i32>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 4) to <4 x i32>*), align 16 ret void } @@ -395,8 +395,8 @@ entry: ; CHECK-LABEL: fct14: ; CHECK: ldur [[DESTREG:q[0-9]+]], {{\[}}[[BASEREG:x[0-9]+]], #3] ; CHECK: stur [[DESTREG]], {{\[}}[[BASEREG]], #4] - %0 = load <8 x i16>, <8 x i16>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <8 x i16>*), align 16 - store <8 x i16> %0, <8 x i16>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 4) to <8 x i16>*), align 16 + %0 = load <8 x i16>, <8 x i16>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <8 x i16>*), align 16 + store <8 x i16> %0, <8 x i16>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 4) to <8 x i16>*), align 16 ret void } @@ -405,8 +405,8 @@ entry: ; CHECK-LABEL: fct15: ; CHECK: ldur [[DESTREG:q[0-9]+]], {{\[}}[[BASEREG:x[0-9]+]], #3] ; CHECK: stur [[DESTREG]], {{\[}}[[BASEREG]], #4] - %0 = load <16 x i8>, <16 x i8>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 3) to <16 x i8>*), align 16 - store <16 x i8> %0, <16 x i8>* bitcast (i8* getelementptr inbounds ([63 x i8]* @str, i64 0, i64 4) to <16 x i8>*), align 16 + %0 = load <16 x i8>, <16 x i8>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 3) to <16 x i8>*), align 16 + store <16 x i8> %0, <16 x i8>* bitcast (i8* getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 4) to <16 x i8>*), align 16 ret void } diff --git a/test/CodeGen/AArch64/br-to-eh-lpad.ll b/test/CodeGen/AArch64/br-to-eh-lpad.ll index 20bffd9e412..e948b87a63d 100644 --- a/test/CodeGen/AArch64/br-to-eh-lpad.ll +++ b/test/CodeGen/AArch64/br-to-eh-lpad.ll @@ -30,12 +30,12 @@ invoke.cont7: unreachable if.end50.thread: - tail call void (i8*, ...)* @printf(i8* getelementptr inbounds ([17 x i8]* @.str1, i64 0, i64 0), i32 125) - tail call void (i8*, ...)* @printf(i8* getelementptr inbounds ([17 x i8]* @.str1, i64 0, i64 0), i32 128) + tail call void (i8*, ...)* @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str1, i64 0, i64 0), i32 125) + tail call void (i8*, ...)* @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str1, i64 0, i64 0), i32 128) unreachable invoke.cont33: - tail call void (i8*, ...)* @printf(i8* getelementptr inbounds ([17 x i8]* @.str1, i64 0, i64 0), i32 119) + tail call void (i8*, ...)* @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str1, i64 0, i64 0), i32 119) unreachable invoke.cont41: @@ -51,7 +51,7 @@ lpad40: br label %finally.catchall finally.catchall: - tail call void (i8*, ...)* @printf(i8* getelementptr inbounds ([17 x i8]* @.str1, i64 0, i64 0), i32 125) + tail call void (i8*, ...)* @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str1, i64 0, i64 0), i32 125) unreachable } diff --git a/test/CodeGen/AArch64/dag-combine-invaraints.ll b/test/CodeGen/AArch64/dag-combine-invaraints.ll index 11c63851ce8..36141331633 100644 --- a/test/CodeGen/AArch64/dag-combine-invaraints.ll +++ b/test/CodeGen/AArch64/dag-combine-invaraints.ll @@ -20,7 +20,7 @@ main_: %DHSelect = select i1 %tmp8, i32 %tmp9, i32 %tmp10 store i32 %DHSelect, i32* %i32X, align 4 %tmp15 = load i32, i32* %i32X, align 4 - %tmp17 = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([9 x i8]* @.str2, i32 0, i32 0), i32 %tmp15) + %tmp17 = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str2, i32 0, i32 0), i32 %tmp15) ret i32 0 ; CHECK: main: diff --git a/test/CodeGen/AArch64/global-merge-4.ll b/test/CodeGen/AArch64/global-merge-4.ll index 6c1177f09c6..d3ae32d3b5c 100644 --- a/test/CodeGen/AArch64/global-merge-4.ll +++ b/test/CodeGen/AArch64/global-merge-4.ll @@ -10,25 +10,25 @@ target triple = "arm64-apple-ios7.0.0" ; Function Attrs: nounwind ssp define internal void @initialize() #0 { %1 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #2 - store i32 %1, i32* getelementptr inbounds ([5 x i32]* @bar, i64 0, i64 0), align 4 + store i32 %1, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i64 0, i64 0), align 4 %2 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #2 - store i32 %2, i32* getelementptr inbounds ([5 x i32]* @baz, i64 0, i64 0), align 4 + store i32 %2, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i64 0, i64 0), align 4 %3 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #2 - store i32 %3, i32* getelementptr inbounds ([5 x i32]* @bar, i64 0, i64 1), align 4 + store i32 %3, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i64 0, i64 1), align 4 %4 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #2 - store i32 %4, i32* getelementptr inbounds ([5 x i32]* @baz, i64 0, i64 1), align 4 + store i32 %4, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i64 0, i64 1), align 4 %5 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #2 - store i32 %5, i32* getelementptr inbounds ([5 x i32]* @bar, i64 0, i64 2), align 4 + store i32 %5, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i64 0, i64 2), align 4 %6 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #2 - store i32 %6, i32* getelementptr inbounds ([5 x i32]* @baz, i64 0, i64 2), align 4 + store i32 %6, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i64 0, i64 2), align 4 %7 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #2 - store i32 %7, i32* getelementptr inbounds ([5 x i32]* @bar, i64 0, i64 3), align 4 + store i32 %7, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i64 0, i64 3), align 4 %8 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #2 - store i32 %8, i32* getelementptr inbounds ([5 x i32]* @baz, i64 0, i64 3), align 4 + store i32 %8, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i64 0, i64 3), align 4 %9 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #2 - store i32 %9, i32* getelementptr inbounds ([5 x i32]* @bar, i64 0, i64 4), align 4 + store i32 %9, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i64 0, i64 4), align 4 %10 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #2 - store i32 %10, i32* getelementptr inbounds ([5 x i32]* @baz, i64 0, i64 4), align 4 + store i32 %10, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i64 0, i64 4), align 4 ret void } @@ -36,32 +36,32 @@ declare i32 @calc(...) ; Function Attrs: nounwind ssp define internal void @calculate() #0 { - %1 = load i32, i32* getelementptr inbounds ([5 x i32]* @bar, i64 0, i64 0), align 4 - %2 = load i32, i32* getelementptr inbounds ([5 x i32]* @baz, i64 0, i64 0), align 4 + %1 = load i32, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i64 0, i64 0), align 4 + %2 = load i32, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i64 0, i64 0), align 4 %3 = mul nsw i32 %2, %1 - store i32 %3, i32* getelementptr inbounds ([5 x i32]* @foo, i64 0, i64 0), align 4 - %4 = load i32, i32* getelementptr inbounds ([5 x i32]* @bar, i64 0, i64 1), align 4 - %5 = load i32, i32* getelementptr inbounds ([5 x i32]* @baz, i64 0, i64 1), align 4 + store i32 %3, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @foo, i64 0, i64 0), align 4 + %4 = load i32, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i64 0, i64 1), align 4 + %5 = load i32, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i64 0, i64 1), align 4 %6 = mul nsw i32 %5, %4 - store i32 %6, i32* getelementptr inbounds ([5 x i32]* @foo, i64 0, i64 1), align 4 - %7 = load i32, i32* getelementptr inbounds ([5 x i32]* @bar, i64 0, i64 2), align 4 - %8 = load i32, i32* getelementptr inbounds ([5 x i32]* @baz, i64 0, i64 2), align 4 + store i32 %6, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @foo, i64 0, i64 1), align 4 + %7 = load i32, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i64 0, i64 2), align 4 + %8 = load i32, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i64 0, i64 2), align 4 %9 = mul nsw i32 %8, %7 - store i32 %9, i32* getelementptr inbounds ([5 x i32]* @foo, i64 0, i64 2), align 4 - %10 = load i32, i32* getelementptr inbounds ([5 x i32]* @bar, i64 0, i64 3), align 4 - %11 = load i32, i32* getelementptr inbounds ([5 x i32]* @baz, i64 0, i64 3), align 4 + store i32 %9, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @foo, i64 0, i64 2), align 4 + %10 = load i32, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i64 0, i64 3), align 4 + %11 = load i32, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i64 0, i64 3), align 4 %12 = mul nsw i32 %11, %10 - store i32 %12, i32* getelementptr inbounds ([5 x i32]* @foo, i64 0, i64 3), align 4 - %13 = load i32, i32* getelementptr inbounds ([5 x i32]* @bar, i64 0, i64 4), align 4 - %14 = load i32, i32* getelementptr inbounds ([5 x i32]* @baz, i64 0, i64 4), align 4 + store i32 %12, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @foo, i64 0, i64 3), align 4 + %13 = load i32, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i64 0, i64 4), align 4 + %14 = load i32, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i64 0, i64 4), align 4 %15 = mul nsw i32 %14, %13 - store i32 %15, i32* getelementptr inbounds ([5 x i32]* @foo, i64 0, i64 4), align 4 + store i32 %15, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @foo, i64 0, i64 4), align 4 ret void } ; Function Attrs: nounwind readnone ssp define internal i32* @returnFoo() #1 { - ret i32* getelementptr inbounds ([5 x i32]* @foo, i64 0, i64 0) + ret i32* getelementptr inbounds ([5 x i32], [5 x i32]* @foo, i64 0, i64 0) } ;CHECK: .type _MergedGlobals,@object // @_MergedGlobals diff --git a/test/CodeGen/AArch64/inline-asm-globaladdress.ll b/test/CodeGen/AArch64/inline-asm-globaladdress.ll index ba1bc40a495..adebabaa29b 100644 --- a/test/CodeGen/AArch64/inline-asm-globaladdress.ll +++ b/test/CodeGen/AArch64/inline-asm-globaladdress.ll @@ -13,7 +13,7 @@ define void @test_inlineasm_globaladdress() { ; CHECK-LABEL: test_inlineasm_globaladdress_offset: ; CHECK: b {{_?}}test_symbol+4 define void @test_inlineasm_globaladdress_offset() { - call void asm sideeffect "b $0", "i"(void ()* bitcast (i8* getelementptr (i8* bitcast (void ()* @test_symbol to i8*), i64 4) to void ()*)) + call void asm sideeffect "b $0", "i"(void ()* bitcast (i8* getelementptr (i8, i8* bitcast (void ()* @test_symbol to i8*), i64 4) to void ()*)) ret void } diff --git a/test/CodeGen/AArch64/rm_redundant_cmp.ll b/test/CodeGen/AArch64/rm_redundant_cmp.ll index 5184d7491d5..f66af7fd627 100644 --- a/test/CodeGen/AArch64/rm_redundant_cmp.ll +++ b/test/CodeGen/AArch64/rm_redundant_cmp.ll @@ -15,13 +15,13 @@ define void @test_i16_2cmp_signed_1() { ; CHECK-NOT: cmp ; CHECK: b.ne entry: - %0 = load i16, i16* getelementptr inbounds (%struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 1), align 2 - %1 = load i16, i16* getelementptr inbounds (%struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 2), align 2 + %0 = load i16, i16* getelementptr inbounds (%struct.s_signed_i16, %struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 1), align 2 + %1 = load i16, i16* getelementptr inbounds (%struct.s_signed_i16, %struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 2), align 2 %cmp = icmp sgt i16 %0, %1 br i1 %cmp, label %if.then, label %if.else if.then: ; preds = %entry - store i16 %0, i16* getelementptr inbounds (%struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 0), align 2 + store i16 %0, i16* getelementptr inbounds (%struct.s_signed_i16, %struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 0), align 2 br label %if.end8 if.else: ; preds = %entry @@ -29,7 +29,7 @@ if.else: ; preds = %entry br i1 %cmp5, label %if.then7, label %if.end8 if.then7: ; preds = %if.else - store i16 %0, i16* getelementptr inbounds (%struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 0), align 2 + store i16 %0, i16* getelementptr inbounds (%struct.s_signed_i16, %struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 0), align 2 br label %if.end8 if.end8: ; preds = %if.else, %if.then7, %if.then @@ -43,13 +43,13 @@ define void @test_i16_2cmp_signed_2() { ; CHECK-NOT: cmp ; CHECK: b.ge entry: - %0 = load i16, i16* getelementptr inbounds (%struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 1), align 2 - %1 = load i16, i16* getelementptr inbounds (%struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 2), align 2 + %0 = load i16, i16* getelementptr inbounds (%struct.s_signed_i16, %struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 1), align 2 + %1 = load i16, i16* getelementptr inbounds (%struct.s_signed_i16, %struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 2), align 2 %cmp = icmp sgt i16 %0, %1 br i1 %cmp, label %if.then, label %if.else if.then: ; preds = %entry - store i16 %0, i16* getelementptr inbounds (%struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 0), align 2 + store i16 %0, i16* getelementptr inbounds (%struct.s_signed_i16, %struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 0), align 2 br label %if.end8 if.else: ; preds = %entry @@ -57,7 +57,7 @@ if.else: ; preds = %entry br i1 %cmp5, label %if.then7, label %if.end8 if.then7: ; preds = %if.else - store i16 %1, i16* getelementptr inbounds (%struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 0), align 2 + store i16 %1, i16* getelementptr inbounds (%struct.s_signed_i16, %struct.s_signed_i16* @cost_s_i8_i16, i64 0, i32 0), align 2 br label %if.end8 if.end8: ; preds = %if.else, %if.then7, %if.then @@ -71,13 +71,13 @@ define void @test_i16_2cmp_unsigned_1() { ; CHECK-NOT: cmp ; CHECK: b.ne entry: - %0 = load i16, i16* getelementptr inbounds (%struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 1), align 2 - %1 = load i16, i16* getelementptr inbounds (%struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 2), align 2 + %0 = load i16, i16* getelementptr inbounds (%struct.s_unsigned_i16, %struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 1), align 2 + %1 = load i16, i16* getelementptr inbounds (%struct.s_unsigned_i16, %struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 2), align 2 %cmp = icmp ugt i16 %0, %1 br i1 %cmp, label %if.then, label %if.else if.then: ; preds = %entry - store i16 %0, i16* getelementptr inbounds (%struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 0), align 2 + store i16 %0, i16* getelementptr inbounds (%struct.s_unsigned_i16, %struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 0), align 2 br label %if.end8 if.else: ; preds = %entry @@ -85,7 +85,7 @@ if.else: ; preds = %entry br i1 %cmp5, label %if.then7, label %if.end8 if.then7: ; preds = %if.else - store i16 %0, i16* getelementptr inbounds (%struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 0), align 2 + store i16 %0, i16* getelementptr inbounds (%struct.s_unsigned_i16, %struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 0), align 2 br label %if.end8 if.end8: ; preds = %if.else, %if.then7, %if.then @@ -99,13 +99,13 @@ define void @test_i16_2cmp_unsigned_2() { ; CHECK-NOT: cmp ; CHECK: b.hs entry: - %0 = load i16, i16* getelementptr inbounds (%struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 1), align 2 - %1 = load i16, i16* getelementptr inbounds (%struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 2), align 2 + %0 = load i16, i16* getelementptr inbounds (%struct.s_unsigned_i16, %struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 1), align 2 + %1 = load i16, i16* getelementptr inbounds (%struct.s_unsigned_i16, %struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 2), align 2 %cmp = icmp ugt i16 %0, %1 br i1 %cmp, label %if.then, label %if.else if.then: ; preds = %entry - store i16 %0, i16* getelementptr inbounds (%struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 0), align 2 + store i16 %0, i16* getelementptr inbounds (%struct.s_unsigned_i16, %struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 0), align 2 br label %if.end8 if.else: ; preds = %entry @@ -113,7 +113,7 @@ if.else: ; preds = %entry br i1 %cmp5, label %if.then7, label %if.end8 if.then7: ; preds = %if.else - store i16 %1, i16* getelementptr inbounds (%struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 0), align 2 + store i16 %1, i16* getelementptr inbounds (%struct.s_unsigned_i16, %struct.s_unsigned_i16* @cost_u_i16, i64 0, i32 0), align 2 br label %if.end8 if.end8: ; preds = %if.else, %if.then7, %if.then @@ -136,13 +136,13 @@ define void @test_i8_2cmp_signed_1() { ; CHECK-NOT: cmp ; CHECK: b.ne entry: - %0 = load i8, i8* getelementptr inbounds (%struct.s_signed_i8* @cost_s, i64 0, i32 1), align 2 - %1 = load i8, i8* getelementptr inbounds (%struct.s_signed_i8* @cost_s, i64 0, i32 2), align 2 + %0 = load i8, i8* getelementptr inbounds (%struct.s_signed_i8, %struct.s_signed_i8* @cost_s, i64 0, i32 1), align 2 + %1 = load i8, i8* getelementptr inbounds (%struct.s_signed_i8, %struct.s_signed_i8* @cost_s, i64 0, i32 2), align 2 %cmp = icmp sgt i8 %0, %1 br i1 %cmp, label %if.then, label %if.else if.then: ; preds = %entry - store i8 %0, i8* getelementptr inbounds (%struct.s_signed_i8* @cost_s, i64 0, i32 0), align 2 + store i8 %0, i8* getelementptr inbounds (%struct.s_signed_i8, %struct.s_signed_i8* @cost_s, i64 0, i32 0), align 2 br label %if.end8 if.else: ; preds = %entry @@ -150,7 +150,7 @@ if.else: ; preds = %entry br i1 %cmp5, label %if.then7, label %if.end8 if.then7: ; preds = %if.else - store i8 %0, i8* getelementptr inbounds (%struct.s_signed_i8* @cost_s, i64 0, i32 0), align 2 + store i8 %0, i8* getelementptr inbounds (%struct.s_signed_i8, %struct.s_signed_i8* @cost_s, i64 0, i32 0), align 2 br label %if.end8 if.end8: ; preds = %if.else, %if.then7, %if.then @@ -164,13 +164,13 @@ define void @test_i8_2cmp_signed_2() { ; CHECK-NOT: cmp ; CHECK: b.ge entry: - %0 = load i8, i8* getelementptr inbounds (%struct.s_signed_i8* @cost_s, i64 0, i32 1), align 2 - %1 = load i8, i8* getelementptr inbounds (%struct.s_signed_i8* @cost_s, i64 0, i32 2), align 2 + %0 = load i8, i8* getelementptr inbounds (%struct.s_signed_i8, %struct.s_signed_i8* @cost_s, i64 0, i32 1), align 2 + %1 = load i8, i8* getelementptr inbounds (%struct.s_signed_i8, %struct.s_signed_i8* @cost_s, i64 0, i32 2), align 2 %cmp = icmp sgt i8 %0, %1 br i1 %cmp, label %if.then, label %if.else if.then: ; preds = %entry - store i8 %0, i8* getelementptr inbounds (%struct.s_signed_i8* @cost_s, i64 0, i32 0), align 2 + store i8 %0, i8* getelementptr inbounds (%struct.s_signed_i8, %struct.s_signed_i8* @cost_s, i64 0, i32 0), align 2 br label %if.end8 if.else: ; preds = %entry @@ -178,7 +178,7 @@ if.else: ; preds = %entry br i1 %cmp5, label %if.then7, label %if.end8 if.then7: ; preds = %if.else - store i8 %1, i8* getelementptr inbounds (%struct.s_signed_i8* @cost_s, i64 0, i32 0), align 2 + store i8 %1, i8* getelementptr inbounds (%struct.s_signed_i8, %struct.s_signed_i8* @cost_s, i64 0, i32 0), align 2 br label %if.end8 if.end8: ; preds = %if.else, %if.then7, %if.then @@ -192,13 +192,13 @@ define void @test_i8_2cmp_unsigned_1() { ; CHECK-NOT: cmp ; CHECK: b.ne entry: - %0 = load i8, i8* getelementptr inbounds (%struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 1), align 2 - %1 = load i8, i8* getelementptr inbounds (%struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 2), align 2 + %0 = load i8, i8* getelementptr inbounds (%struct.s_unsigned_i8, %struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 1), align 2 + %1 = load i8, i8* getelementptr inbounds (%struct.s_unsigned_i8, %struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 2), align 2 %cmp = icmp ugt i8 %0, %1 br i1 %cmp, label %if.then, label %if.else if.then: ; preds = %entry - store i8 %0, i8* getelementptr inbounds (%struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 0), align 2 + store i8 %0, i8* getelementptr inbounds (%struct.s_unsigned_i8, %struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 0), align 2 br label %if.end8 if.else: ; preds = %entry @@ -206,7 +206,7 @@ if.else: ; preds = %entry br i1 %cmp5, label %if.then7, label %if.end8 if.then7: ; preds = %if.else - store i8 %0, i8* getelementptr inbounds (%struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 0), align 2 + store i8 %0, i8* getelementptr inbounds (%struct.s_unsigned_i8, %struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 0), align 2 br label %if.end8 if.end8: ; preds = %if.else, %if.then7, %if.then @@ -220,13 +220,13 @@ define void @test_i8_2cmp_unsigned_2() { ; CHECK-NOT: cmp ; CHECK: b.hs entry: - %0 = load i8, i8* getelementptr inbounds (%struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 1), align 2 - %1 = load i8, i8* getelementptr inbounds (%struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 2), align 2 + %0 = load i8, i8* getelementptr inbounds (%struct.s_unsigned_i8, %struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 1), align 2 + %1 = load i8, i8* getelementptr inbounds (%struct.s_unsigned_i8, %struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 2), align 2 %cmp = icmp ugt i8 %0, %1 br i1 %cmp, label %if.then, label %if.else if.then: ; preds = %entry - store i8 %0, i8* getelementptr inbounds (%struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 0), align 2 + store i8 %0, i8* getelementptr inbounds (%struct.s_unsigned_i8, %struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 0), align 2 br label %if.end8 if.else: ; preds = %entry @@ -234,7 +234,7 @@ if.else: ; preds = %entry br i1 %cmp5, label %if.then7, label %if.end8 if.then7: ; preds = %if.else - store i8 %1, i8* getelementptr inbounds (%struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 0), align 2 + store i8 %1, i8* getelementptr inbounds (%struct.s_unsigned_i8, %struct.s_unsigned_i8* @cost_u_i8, i64 0, i32 0), align 2 br label %if.end8 if.end8: ; preds = %if.else, %if.then7, %if.then diff --git a/test/CodeGen/ARM/2007-04-03-UndefinedSymbol.ll b/test/CodeGen/ARM/2007-04-03-UndefinedSymbol.ll index d34c078f054..b687029d62a 100644 --- a/test/CodeGen/ARM/2007-04-03-UndefinedSymbol.ll +++ b/test/CodeGen/ARM/2007-04-03-UndefinedSymbol.ll @@ -10,7 +10,7 @@ define internal void @_ZN1B1iEv(%struct.B* %this) { entry: %tmp1 = getelementptr %struct.B, %struct.B* %this, i32 0, i32 0 ; [#uses=1] %tmp2 = load i32, i32* %tmp1 ; [#uses=1] - %tmp4 = tail call i32 (i8*, ...)* @printf( i8* getelementptr ([7 x i8]* @str, i32 0, i32 0), i32 %tmp2 ) ; [#uses=0] + %tmp4 = tail call i32 (i8*, ...)* @printf( i8* getelementptr ([7 x i8], [7 x i8]* @str, i32 0, i32 0), i32 %tmp2 ) ; [#uses=0] ret void } @@ -20,7 +20,7 @@ define internal void @_ZN1B1jEv(%struct.B* %this) { entry: %tmp1 = getelementptr %struct.B, %struct.B* %this, i32 0, i32 0 ; [#uses=1] %tmp2 = load i32, i32* %tmp1 ; [#uses=1] - %tmp4 = tail call i32 (i8*, ...)* @printf( i8* getelementptr ([7 x i8]* @str1, i32 0, i32 0), i32 %tmp2 ) ; [#uses=0] + %tmp4 = tail call i32 (i8*, ...)* @printf( i8* getelementptr ([7 x i8], [7 x i8]* @str1, i32 0, i32 0), i32 %tmp2 ) ; [#uses=0] ret void } diff --git a/test/CodeGen/ARM/2007-04-30-CombinerCrash.ll b/test/CodeGen/ARM/2007-04-30-CombinerCrash.ll index 7973f223ee0..05c2ff4f7ca 100644 --- a/test/CodeGen/ARM/2007-04-30-CombinerCrash.ll +++ b/test/CodeGen/ARM/2007-04-30-CombinerCrash.ll @@ -9,15 +9,15 @@ target triple = "arm-apple-darwin8" define fastcc void @EvaluateDevelopment() { entry: - %tmp7 = load i64, i64* getelementptr (%struct.CHESS_POSITION* @search, i32 0, i32 7) ; [#uses=1] - %tmp50 = load i64, i64* getelementptr (%struct.CHESS_POSITION* @search, i32 0, i32 0) ; [#uses=1] - %tmp52 = load i64, i64* getelementptr (%struct.CHESS_POSITION* @search, i32 0, i32 1) ; [#uses=1] + %tmp7 = load i64, i64* getelementptr (%struct.CHESS_POSITION, %struct.CHESS_POSITION* @search, i32 0, i32 7) ; [#uses=1] + %tmp50 = load i64, i64* getelementptr (%struct.CHESS_POSITION, %struct.CHESS_POSITION* @search, i32 0, i32 0) ; [#uses=1] + %tmp52 = load i64, i64* getelementptr (%struct.CHESS_POSITION, %struct.CHESS_POSITION* @search, i32 0, i32 1) ; [#uses=1] %tmp53 = or i64 %tmp52, %tmp50 ; [#uses=1] %tmp57.b = load i1, i1* @rank_mask.1.b ; [#uses=1] %tmp57 = select i1 %tmp57.b, i64 71776119061217280, i64 0 ; [#uses=1] %tmp58 = and i64 %tmp57, %tmp7 ; [#uses=1] %tmp59 = lshr i64 %tmp58, 8 ; [#uses=1] - %tmp63 = load i64, i64* getelementptr ([8 x i64]* @file_mask, i32 0, i32 4) ; [#uses=1] + %tmp63 = load i64, i64* getelementptr ([8 x i64], [8 x i64]* @file_mask, i32 0, i32 4) ; [#uses=1] %tmp64 = or i64 %tmp63, 0 ; [#uses=1] %tmp65 = and i64 %tmp59, %tmp53 ; [#uses=1] %tmp66 = and i64 %tmp65, %tmp64 ; [#uses=1] diff --git a/test/CodeGen/ARM/2007-05-03-BadPostIndexedLd.ll b/test/CodeGen/ARM/2007-05-03-BadPostIndexedLd.ll index f59d081d51d..ca168b68ab0 100644 --- a/test/CodeGen/ARM/2007-05-03-BadPostIndexedLd.ll +++ b/test/CodeGen/ARM/2007-05-03-BadPostIndexedLd.ll @@ -93,7 +93,7 @@ cond_true1272: ; preds = %cond_next1267 %tmp42.i348 = sub i32 0, %tmp2930.i ; [#uses=1] %tmp45.i = getelementptr %struct.TestObj, %struct.TestObj* %tmp1273, i32 0, i32 0 ; [#uses=2] %tmp48.i = load i8*, i8** %tmp45.i ; [#uses=1] - %tmp50.i350 = call i32 (i8*, i8*, ...)* @sprintf( i8* getelementptr ([256 x i8]* @Msg, i32 0, i32 0), i8* getelementptr ([48 x i8]* @.str53615, i32 0, i32 0), i8* null, i8** %tmp45.i, i8* %tmp48.i ) ; [#uses=0] + %tmp50.i350 = call i32 (i8*, i8*, ...)* @sprintf( i8* getelementptr ([256 x i8], [256 x i8]* @Msg, i32 0, i32 0), i8* getelementptr ([48 x i8], [48 x i8]* @.str53615, i32 0, i32 0), i8* null, i8** %tmp45.i, i8* %tmp48.i ) ; [#uses=0] br i1 false, label %cond_true.i632.i, label %Ut_TraceMsg.exit648.i cond_true.i632.i: ; preds = %cond_true1272 diff --git a/test/CodeGen/ARM/2007-08-15-ReuseBug.ll b/test/CodeGen/ARM/2007-08-15-ReuseBug.ll index 7d6396c6f68..76b6221d022 100644 --- a/test/CodeGen/ARM/2007-08-15-ReuseBug.ll +++ b/test/CodeGen/ARM/2007-08-15-ReuseBug.ll @@ -46,7 +46,7 @@ bb102.i: ; preds = %cond_next212.i cond_true110.i: ; preds = %bb102.i %tmp116.i = getelementptr i8*, i8** %argv_addr.2321.0.i, i32 2 ; [#uses=1] %tmp117.i = load i8*, i8** %tmp116.i ; [#uses=1] - %tmp126425.i = call %struct.FILE* @fopen( i8* %tmp117.i, i8* getelementptr ([2 x i8]* @.str44, i32 0, i32 0) ) ; <%struct.FILE*> [#uses=0] + %tmp126425.i = call %struct.FILE* @fopen( i8* %tmp117.i, i8* getelementptr ([2 x i8], [2 x i8]* @.str44, i32 0, i32 0) ) ; <%struct.FILE*> [#uses=0] ret i32 0 cond_next123.i: ; preds = %bb102.i diff --git a/test/CodeGen/ARM/2008-03-07-RegScavengerAssert.ll b/test/CodeGen/ARM/2008-03-07-RegScavengerAssert.ll index 24e664c71fb..5ee8b46bdd1 100644 --- a/test/CodeGen/ARM/2008-03-07-RegScavengerAssert.ll +++ b/test/CodeGen/ARM/2008-03-07-RegScavengerAssert.ll @@ -11,9 +11,9 @@ bb74.i: ; preds = %bb88.i, %bb74.i, %entry bb88.i: ; preds = %bb74.i br i1 false, label %mandel.exit, label %bb74.i mandel.exit: ; preds = %bb88.i - %tmp2 = load volatile double, double* getelementptr ({ double, double }* @accum, i32 0, i32 0), align 8 ; [#uses=1] + %tmp2 = load volatile double, double* getelementptr ({ double, double }, { double, double }* @accum, i32 0, i32 0), align 8 ; [#uses=1] %tmp23 = fptosi double %tmp2 to i32 ; [#uses=1] - %tmp5 = tail call i32 (i8*, ...)* @printf( i8* getelementptr ([4 x i8]* @.str, i32 0, i32 0), i32 %tmp23 ) ; [#uses=0] + %tmp5 = tail call i32 (i8*, ...)* @printf( i8* getelementptr ([4 x i8], [4 x i8]* @.str, i32 0, i32 0), i32 %tmp23 ) ; [#uses=0] ret i32 0 } diff --git a/test/CodeGen/ARM/2008-04-04-ScavengerAssert.ll b/test/CodeGen/ARM/2008-04-04-ScavengerAssert.ll index 6b39a76d0d1..4b1aa19ef06 100644 --- a/test/CodeGen/ARM/2008-04-04-ScavengerAssert.ll +++ b/test/CodeGen/ARM/2008-04-04-ScavengerAssert.ll @@ -46,7 +46,7 @@ bb17.i: ; preds = %cond_next119.i cond_true53.i: ; preds = %bb17.i ret { i16, %struct.rnode* }* null cond_false99.i: ; preds = %bb17.i - %malloccall = tail call i8* @malloc(i32 trunc (i64 mul nuw (i64 ptrtoint (i1** getelementptr (i1** null, i32 1) to i64), i64 2) to i32)) + %malloccall = tail call i8* @malloc(i32 trunc (i64 mul nuw (i64 ptrtoint (i1** getelementptr (i1*, i1** null, i32 1) to i64), i64 2) to i32)) %tmp106.i = bitcast i8* %malloccall to %struct.ch_set* br i1 false, label %bb126.i, label %cond_next119.i cond_next119.i: ; preds = %cond_false99.i, %bb42 diff --git a/test/CodeGen/ARM/2008-04-10-ScavengerAssert.ll b/test/CodeGen/ARM/2008-04-10-ScavengerAssert.ll index 428aa1113a1..bd1f1742a22 100644 --- a/test/CodeGen/ARM/2008-04-10-ScavengerAssert.ll +++ b/test/CodeGen/ARM/2008-04-10-ScavengerAssert.ll @@ -24,7 +24,7 @@ define void @main(i32 %argc, i8** %argv) noreturn { entry: br i1 false, label %cond_next48, label %cond_false674 cond_next48: ; preds = %entry - %tmp61 = call %struct.FILE* @fopen( i8* null, i8* getelementptr ([2 x i8]* @.str127, i32 0, i32 0) ) ; <%struct.FILE*> [#uses=2] + %tmp61 = call %struct.FILE* @fopen( i8* null, i8* getelementptr ([2 x i8], [2 x i8]* @.str127, i32 0, i32 0) ) ; <%struct.FILE*> [#uses=2] br i1 false, label %bb220.i.i.i, label %bb62.preheader.i.i.i bb62.preheader.i.i.i: ; preds = %cond_next48 ret void @@ -53,7 +53,7 @@ bb177.i393.i: ; preds = %bb40.i.i bb192.i.i: ; preds = %bb177.i393.i ret void cond_false373.i.i: ; preds = %bb.i350.i - %tmp376.i.i = call i32 @strcmp( i8* null, i8* getelementptr ([9 x i8]* @.str8115, i32 0, i32 0) ) ; [#uses=0] + %tmp376.i.i = call i32 @strcmp( i8* null, i8* getelementptr ([9 x i8], [9 x i8]* @.str8115, i32 0, i32 0) ) ; [#uses=0] br i1 false, label %cond_true380.i.i, label %cond_next602.i.i cond_true380.i.i: ; preds = %cond_false373.i.i %tmp394.i418.i = add i32 %cell.0.i.i, 1 ; [#uses=1] @@ -73,10 +73,10 @@ bb609.i.i: ; preds = %cond_next602.i.i br label %bb620.i.i bb620.i.i: ; preds = %bb620.i.i, %bb609.i.i %indvar166.i465.i = phi i32 [ %indvar.next167.i.i, %bb620.i.i ], [ 0, %bb609.i.i ] ; [#uses=1] - %tmp640.i.i = call i32 (%struct.FILE*, i8*, ...)* @fscanf( %struct.FILE* %tmp61, i8* getelementptr ([5 x i8]* @.str584, i32 0, i32 0), [1024 x i8]* null ) ; [#uses=0] + %tmp640.i.i = call i32 (%struct.FILE*, i8*, ...)* @fscanf( %struct.FILE* %tmp61, i8* getelementptr ([5 x i8], [5 x i8]* @.str584, i32 0, i32 0), [1024 x i8]* null ) ; [#uses=0] %tmp648.i.i = load i32, i32* null, align 4 ; [#uses=1] %tmp650.i468.i = icmp sgt i32 0, %tmp648.i.i ; [#uses=1] - %tmp624.i469.i = call i32 (%struct.FILE*, i8*, ...)* @fscanf( %struct.FILE* %tmp61, i8* getelementptr ([5 x i8]* @.str584, i32 0, i32 0), [1024 x i8]* null ) ; [#uses=0] + %tmp624.i469.i = call i32 (%struct.FILE*, i8*, ...)* @fscanf( %struct.FILE* %tmp61, i8* getelementptr ([5 x i8], [5 x i8]* @.str584, i32 0, i32 0), [1024 x i8]* null ) ; [#uses=0] %indvar.next167.i.i = add i32 %indvar166.i465.i, 1 ; [#uses=1] br i1 %tmp650.i468.i, label %bb653.i.i.loopexit, label %bb620.i.i bb653.i.i.loopexit: ; preds = %bb620.i.i diff --git a/test/CodeGen/ARM/2008-05-19-LiveIntervalsBug.ll b/test/CodeGen/ARM/2008-05-19-LiveIntervalsBug.ll index c9c78e1f6d8..85ef8302a18 100644 --- a/test/CodeGen/ARM/2008-05-19-LiveIntervalsBug.ll +++ b/test/CodeGen/ARM/2008-05-19-LiveIntervalsBug.ll @@ -21,8 +21,8 @@ entry: br i1 false, label %init_orig_buffers.exit, label %cond_true.i29 cond_true.i29: ; preds = %entry - %tmp17.i = load i32, i32* getelementptr (%struct.ImageParameters* @images, i32 0, i32 20), align 8 ; [#uses=1] - %tmp20.i27 = load i32, i32* getelementptr (%struct.ImageParameters* @images, i32 0, i32 16), align 8 ; [#uses=1] + %tmp17.i = load i32, i32* getelementptr (%struct.ImageParameters, %struct.ImageParameters* @images, i32 0, i32 20), align 8 ; [#uses=1] + %tmp20.i27 = load i32, i32* getelementptr (%struct.ImageParameters, %struct.ImageParameters* @images, i32 0, i32 16), align 8 ; [#uses=1] %tmp8.i.i = select i1 false, i32 1, i32 0 ; [#uses=1] br label %bb.i8.us.i diff --git a/test/CodeGen/ARM/2008-05-19-ScavengerAssert.ll b/test/CodeGen/ARM/2008-05-19-ScavengerAssert.ll index aa61d86e138..3d69e4fefbc 100644 --- a/test/CodeGen/ARM/2008-05-19-ScavengerAssert.ll +++ b/test/CodeGen/ARM/2008-05-19-ScavengerAssert.ll @@ -9,7 +9,7 @@ declare fastcc i32 @get_mem2Dint(i32***, i32, i32) define fastcc void @init_global_buffers() nounwind { entry: - %tmp151 = tail call fastcc i32 @get_mem2Dint( i32*** getelementptr (%struct.Decoders* @decoders, i32 0, i32 0), i32 16, i32 16 ) ; [#uses=1] + %tmp151 = tail call fastcc i32 @get_mem2Dint( i32*** getelementptr (%struct.Decoders, %struct.Decoders* @decoders, i32 0, i32 0), i32 16, i32 16 ) ; [#uses=1] %tmp158 = tail call i8* @calloc( i32 0, i32 4 ) ; [#uses=0] br i1 false, label %cond_true166, label %bb190.preheader diff --git a/test/CodeGen/ARM/2008-08-07-AsmPrintBug.ll b/test/CodeGen/ARM/2008-08-07-AsmPrintBug.ll index 520e800b902..dfbbeb9968c 100644 --- a/test/CodeGen/ARM/2008-08-07-AsmPrintBug.ll +++ b/test/CodeGen/ARM/2008-08-07-AsmPrintBug.ll @@ -8,6 +8,6 @@ define i32 @__gcov_close() nounwind { entry: - load i32, i32* getelementptr (%struct.__gcov_var* @__gcov_var, i32 0, i32 5), align 4 ; :0 [#uses=1] + load i32, i32* getelementptr (%struct.__gcov_var, %struct.__gcov_var* @__gcov_var, i32 0, i32 5), align 4 ; :0 [#uses=1] ret i32 %0 } diff --git a/test/CodeGen/ARM/2009-02-16-SpillerBug.ll b/test/CodeGen/ARM/2009-02-16-SpillerBug.ll index c581222944d..d090da07c50 100644 --- a/test/CodeGen/ARM/2009-02-16-SpillerBug.ll +++ b/test/CodeGen/ARM/2009-02-16-SpillerBug.ll @@ -81,7 +81,7 @@ bb244: ; preds = %bb122, %bb122, %bb122, %bb122, %bb122, %bb122, %bb122, %bb122 br i1 %0, label %bb435, label %bb433 bb394: ; preds = %bb122 - call void (i32, i32, i8*, i32, %struct.FILE_POS*, ...)* @Error(i32 1, i32 3, i8* getelementptr ([23 x i8]* @"\01LC13423", i32 0, i32 0), i32 0, %struct.FILE_POS* @no_file_pos, i8* getelementptr ([13 x i8]* @"\01LC18972", i32 0, i32 0), i8* null) nounwind + call void (i32, i32, i8*, i32, %struct.FILE_POS*, ...)* @Error(i32 1, i32 3, i8* getelementptr ([23 x i8], [23 x i8]* @"\01LC13423", i32 0, i32 0), i32 0, %struct.FILE_POS* @no_file_pos, i8* getelementptr ([13 x i8], [13 x i8]* @"\01LC18972", i32 0, i32 0), i8* null) nounwind br label %bb396 bb396: ; preds = %bb394, %bb131, %bb122, %bb122, %bb122, %bb122, %RESUME diff --git a/test/CodeGen/ARM/2009-05-07-RegAllocLocal.ll b/test/CodeGen/ARM/2009-05-07-RegAllocLocal.ll index 524b5ebddc0..887fb0b37a9 100644 --- a/test/CodeGen/ARM/2009-05-07-RegAllocLocal.ll +++ b/test/CodeGen/ARM/2009-05-07-RegAllocLocal.ll @@ -5,7 +5,7 @@ define i16 @fn16(i16 %arg0.0, <2 x i16> %arg1, i16 %arg2.0) nounwind { entry: store <2 x i16> %arg1, <2 x i16>* null - %0 = call i32 (i8*, ...)* @printf(i8* getelementptr ([30 x i8]* @.str, i32 0, i32 0), i32 0) nounwind ; [#uses=0] + %0 = call i32 (i8*, ...)* @printf(i8* getelementptr ([30 x i8], [30 x i8]* @.str, i32 0, i32 0), i32 0) nounwind ; [#uses=0] ret i16 0 } diff --git a/test/CodeGen/ARM/2009-05-11-CodePlacementCrash.ll b/test/CodeGen/ARM/2009-05-11-CodePlacementCrash.ll index 06456cc9ca4..b616cb3eca5 100644 --- a/test/CodeGen/ARM/2009-05-11-CodePlacementCrash.ll +++ b/test/CodeGen/ARM/2009-05-11-CodePlacementCrash.ll @@ -19,7 +19,7 @@ bb1: ; preds = %bb bb3: ; preds = %bb1, %bb %iftmp.0.0 = phi i32 [ 0, %bb1 ], [ -1, %bb ] ; [#uses=1] - %1 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([7 x i8]* @"\01LC", i32 0, i32 0), i32 0, i32 %iftmp.0.0) nounwind ; [#uses=0] + %1 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([7 x i8], [7 x i8]* @"\01LC", i32 0, i32 0), i32 0, i32 %iftmp.0.0) nounwind ; [#uses=0] %2 = load %struct.List*, %struct.List** null, align 4 ; <%struct.List*> [#uses=2] %phitmp = icmp eq %struct.List* %2, null ; [#uses=1] br i1 %phitmp, label %bb5, label %bb diff --git a/test/CodeGen/ARM/2009-06-02-ISelCrash.ll b/test/CodeGen/ARM/2009-06-02-ISelCrash.ll index 403e3f6509f..0612d51ced5 100644 --- a/test/CodeGen/ARM/2009-06-02-ISelCrash.ll +++ b/test/CodeGen/ARM/2009-06-02-ISelCrash.ll @@ -57,6 +57,6 @@ Fft.exit.i: ; preds = %bb7.i.i br i1 undef, label %bb5.i, label %bb1.outer2.i.i.outer bb5.i: ; preds = %Fft.exit.i - %0 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([15 x i8]* @"\01LC", i32 0, i32 0), double undef, double undef) nounwind ; [#uses=0] + %0 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([15 x i8], [15 x i8]* @"\01LC", i32 0, i32 0), double undef, double undef) nounwind ; [#uses=0] unreachable } diff --git a/test/CodeGen/ARM/2009-06-30-RegScavengerAssert.ll b/test/CodeGen/ARM/2009-06-30-RegScavengerAssert.ll index 243726c9149..72a41f9bfaa 100644 --- a/test/CodeGen/ARM/2009-06-30-RegScavengerAssert.ll +++ b/test/CodeGen/ARM/2009-06-30-RegScavengerAssert.ll @@ -47,14 +47,14 @@ bb11: ; preds = %bb9 tail call void @diff(i8* undef, i8* %3, i32 undef, i32 undef, i32 undef, i32 undef) nounwind %4 = sitofp i32 undef to double ; [#uses=1] %5 = fdiv double %4, 1.000000e+01 ; [#uses=1] - %6 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([29 x i8]* @"\01LC12", i32 0, i32 0), double %5) nounwind ; [#uses=0] + %6 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([29 x i8], [29 x i8]* @"\01LC12", i32 0, i32 0), double %5) nounwind ; [#uses=0] %7 = load i32, i32* @al_len, align 4 ; [#uses=1] %8 = load i32, i32* @no_mat, align 4 ; [#uses=1] %9 = load i32, i32* @no_mis, align 4 ; [#uses=1] %10 = sub i32 %7, %8 ; [#uses=1] %11 = sub i32 %10, %9 ; [#uses=1] - %12 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([33 x i8]* @"\01LC16", i32 0, i32 0), i32 %11) nounwind ; [#uses=0] - %13 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([47 x i8]* @"\01LC17", i32 0, i32 0), i32 undef, i32 %1, i32 undef, i32 undef) nounwind ; [#uses=0] + %12 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([33 x i8], [33 x i8]* @"\01LC16", i32 0, i32 0), i32 %11) nounwind ; [#uses=0] + %13 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([47 x i8], [47 x i8]* @"\01LC17", i32 0, i32 0), i32 undef, i32 %1, i32 undef, i32 undef) nounwind ; [#uses=0] br i1 undef, label %bb15, label %bb12 bb12: ; preds = %bb11 diff --git a/test/CodeGen/ARM/2009-06-30-RegScavengerAssert2.ll b/test/CodeGen/ARM/2009-06-30-RegScavengerAssert2.ll index 17051df96b5..92b1869f20e 100644 --- a/test/CodeGen/ARM/2009-06-30-RegScavengerAssert2.ll +++ b/test/CodeGen/ARM/2009-06-30-RegScavengerAssert2.ll @@ -42,10 +42,10 @@ bb11: ; preds = %bb9 store i32 0, i32* @no_mis, align 4 %4 = getelementptr i8, i8* %B, i32 %0 ; [#uses=1] tail call void @diff(i8* undef, i8* %4, i32 undef, i32 %3, i32 undef, i32 undef) nounwind - %5 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([33 x i8]* @"\01LC11", i32 0, i32 0), i32 %tmp13) nounwind ; [#uses=0] + %5 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([33 x i8], [33 x i8]* @"\01LC11", i32 0, i32 0), i32 %tmp13) nounwind ; [#uses=0] %6 = load i32, i32* @no_mis, align 4 ; [#uses=1] - %7 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([33 x i8]* @"\01LC15", i32 0, i32 0), i32 %6) nounwind ; [#uses=0] - %8 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([47 x i8]* @"\01LC17", i32 0, i32 0), i32 undef, i32 %1, i32 undef, i32 %2) nounwind ; [#uses=0] + %7 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([33 x i8], [33 x i8]* @"\01LC15", i32 0, i32 0), i32 %6) nounwind ; [#uses=0] + %8 = tail call i32 (i8*, ...)* @printf(i8* getelementptr ([47 x i8], [47 x i8]* @"\01LC17", i32 0, i32 0), i32 undef, i32 %1, i32 undef, i32 %2) nounwind ; [#uses=0] br i1 undef, label %bb15, label %bb12 bb12: ; preds = %bb11 diff --git a/test/CodeGen/ARM/2009-07-18-RewriterBug.ll b/test/CodeGen/ARM/2009-07-18-RewriterBug.ll index 2cb267894a8..2146dd33082 100644 --- a/test/CodeGen/ARM/2009-07-18-RewriterBug.ll +++ b/test/CodeGen/ARM/2009-07-18-RewriterBug.ll @@ -1012,7 +1012,7 @@ bb7: ; preds = %bb br i1 %764, label %bb10, label %bb11 bb8: ; preds = %entry - %768 = call i32 @puts(i8* getelementptr ([21 x i8]* @_2E_str7, i32 0, i32 0)) nounwind ; [#uses=0] + %768 = call i32 @puts(i8* getelementptr ([21 x i8], [21 x i8]* @_2E_str7, i32 0, i32 0)) nounwind ; [#uses=0] call void @exit(i32 -1) noreturn nounwind unreachable diff --git a/test/CodeGen/ARM/2009-08-21-PostRAKill3.ll b/test/CodeGen/ARM/2009-08-21-PostRAKill3.ll index 4eba3675790..133fc0588a9 100644 --- a/test/CodeGen/ARM/2009-08-21-PostRAKill3.ll +++ b/test/CodeGen/ARM/2009-08-21-PostRAKill3.ll @@ -14,7 +14,7 @@ entry: br i1 %p, label %bb8, label %bb1 bb1: ; preds = %entry - %malloccall = tail call i8* @malloc(i32 ptrtoint (%struct.Village* getelementptr (%struct.Village* null, i32 1) to i32)) + %malloccall = tail call i8* @malloc(i32 ptrtoint (%struct.Village* getelementptr (%struct.Village, %struct.Village* null, i32 1) to i32)) %0 = bitcast i8* %malloccall to %struct.Village* %exp2 = call double @ldexp(double 1.000000e+00, i32 %level) nounwind ; [#uses=1] %.c = fptosi double %exp2 to i32 ; [#uses=1] diff --git a/test/CodeGen/ARM/2009-10-27-double-align.ll b/test/CodeGen/ARM/2009-10-27-double-align.ll index b37de9dbbdf..b43f2a66500 100644 --- a/test/CodeGen/ARM/2009-10-27-double-align.ll +++ b/test/CodeGen/ARM/2009-10-27-double-align.ll @@ -8,7 +8,7 @@ entry: ;CHECK: [sp, #8] ;CHECK: [sp, #12] ;CHECK: [sp] - tail call void (i8*, ...)* @f(i8* getelementptr ([1 x i8]* @.str, i32 0, i32 0), i32 1, double 2.000000e+00, i32 3, double 4.000000e+00) + tail call void (i8*, ...)* @f(i8* getelementptr ([1 x i8], [1 x i8]* @.str, i32 0, i32 0), i32 1, double 2.000000e+00, i32 3, double 4.000000e+00) ret void } diff --git a/test/CodeGen/ARM/2010-05-17-FastAllocCrash.ll b/test/CodeGen/ARM/2010-05-17-FastAllocCrash.ll index d6febe6750e..5f5489a1ca7 100644 --- a/test/CodeGen/ARM/2010-05-17-FastAllocCrash.ll +++ b/test/CodeGen/ARM/2010-05-17-FastAllocCrash.ll @@ -82,7 +82,7 @@ cond_true1369.preheader: ; preds = %cond_true1254 ret void bb1567: ; preds = %cond_true1254 - %tmp1591 = load i64, i64* getelementptr inbounds (%struct.CHESS_POSITION* @search, i32 0, i32 4) ; [#uses=1] + %tmp1591 = load i64, i64* getelementptr inbounds (%struct.CHESS_POSITION, %struct.CHESS_POSITION* @search, i32 0, i32 4) ; [#uses=1] %tmp1572 = tail call fastcc i32 @FirstOne() ; [#uses=1] %tmp1594 = load i32, i32* undef ; [#uses=1] %tmp1594.upgrd.5 = trunc i32 %tmp1594 to i8 ; [#uses=1] diff --git a/test/CodeGen/ARM/2010-05-18-LocalAllocCrash.ll b/test/CodeGen/ARM/2010-05-18-LocalAllocCrash.ll index 16c49537720..89ad5f50aab 100644 --- a/test/CodeGen/ARM/2010-05-18-LocalAllocCrash.ll +++ b/test/CodeGen/ARM/2010-05-18-LocalAllocCrash.ll @@ -19,7 +19,7 @@ entry: %tmp21 = load i32, i32* undef ; [#uses=1] %0 = mul i32 1, %tmp21 ; [#uses=1] %vla22 = alloca i8, i32 %0, align 1 ; [#uses=1] - call void (...)* @zz(i8* getelementptr inbounds ([1 x i8]* @.str, i32 0, i32 0), i32 2, i32 1) + call void (...)* @zz(i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str, i32 0, i32 0), i32 2, i32 1) br i1 undef, label %if.then, label %if.end36 if.then: ; preds = %entry diff --git a/test/CodeGen/ARM/2010-06-21-LdStMultipleBug.ll b/test/CodeGen/ARM/2010-06-21-LdStMultipleBug.ll index a1ab27e6ea3..9cd61d38b92 100644 --- a/test/CodeGen/ARM/2010-06-21-LdStMultipleBug.ll +++ b/test/CodeGen/ARM/2010-06-21-LdStMultipleBug.ll @@ -13,7 +13,7 @@ define void @TW_oldinput(%struct.FILE* nocapture %fp) nounwind { entry: %xcenter = alloca i32, align 4 ; [#uses=2] - %0 = call i32 (%struct.FILE*, i8*, ...)* @fscanf(%struct.FILE* %fp, i8* getelementptr inbounds ([14 x i8]* @.str2708, i32 0, i32 0), i32* undef, i32* undef, i32* %xcenter, i32* null) nounwind ; [#uses=1] + %0 = call i32 (%struct.FILE*, i8*, ...)* @fscanf(%struct.FILE* %fp, i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str2708, i32 0, i32 0), i32* undef, i32* undef, i32* %xcenter, i32* null) nounwind ; [#uses=1] %1 = icmp eq i32 %0, 4 ; [#uses=1] br i1 %1, label %bb, label %return @@ -137,7 +137,7 @@ bb322: ; preds = %bb248 br i1 undef, label %bb248, label %bb445 bb445: ; preds = %bb322, %bb10, %bb - %49 = call i32 (%struct.FILE*, i8*, ...)* @fscanf(%struct.FILE* %fp, i8* getelementptr inbounds ([14 x i8]* @.str2708, i32 0, i32 0), i32* undef, i32* undef, i32* %xcenter, i32* null) nounwind ; [#uses=1] + %49 = call i32 (%struct.FILE*, i8*, ...)* @fscanf(%struct.FILE* %fp, i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str2708, i32 0, i32 0), i32* undef, i32* undef, i32* %xcenter, i32* null) nounwind ; [#uses=1] %50 = icmp eq i32 %49, 4 ; [#uses=1] br i1 %50, label %bb, label %return diff --git a/test/CodeGen/ARM/2010-06-21-nondarwin-tc.ll b/test/CodeGen/ARM/2010-06-21-nondarwin-tc.ll index 4ca8ef8dc2a..bead8d9781e 100644 --- a/test/CodeGen/ARM/2010-06-21-nondarwin-tc.ll +++ b/test/CodeGen/ARM/2010-06-21-nondarwin-tc.ll @@ -128,7 +128,7 @@ if.end: ; preds = %.if.end_crit_edge, br i1 %cmp19, label %cond.false, label %cond.end cond.false: ; preds = %if.end - tail call void @__assert_fail(i8* getelementptr inbounds ([45 x i8]* @.str51, i32 0, i32 0), i8* getelementptr inbounds ([47 x i8]* @.str8, i32 0, i32 0), i32 1141, i8* getelementptr inbounds ([116 x i8]* @__PRETTY_FUNCTION__._ZNK4llvm7VarInit12getFieldInitERNS_6RecordEPKNS_9RecordValERKSs, i32 0, i32 0)) noreturn + tail call void @__assert_fail(i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str51, i32 0, i32 0), i8* getelementptr inbounds ([47 x i8], [47 x i8]* @.str8, i32 0, i32 0), i32 1141, i8* getelementptr inbounds ([116 x i8], [116 x i8]* @__PRETTY_FUNCTION__._ZNK4llvm7VarInit12getFieldInitERNS_6RecordEPKNS_9RecordValERKSs, i32 0, i32 0)) noreturn unreachable cond.end: ; preds = %if.end diff --git a/test/CodeGen/ARM/2010-06-29-SubregImpDefs.ll b/test/CodeGen/ARM/2010-06-29-SubregImpDefs.ll index c7ef46c89ff..03362a8e51f 100644 --- a/test/CodeGen/ARM/2010-06-29-SubregImpDefs.ll +++ b/test/CodeGen/ARM/2010-06-29-SubregImpDefs.ll @@ -8,7 +8,7 @@ entry: %0 = shufflevector <2 x i64> undef, <2 x i64> zeroinitializer, <2 x i32> ; <<2 x i64>> [#uses=1] store <2 x i64> %0, <2 x i64>* undef, align 16 %val4723 = load <8 x i16>, <8 x i16>* undef ; <<8 x i16>> [#uses=1] - call void @PrintShortX(i8* getelementptr inbounds ([21 x i8]* @.str271, i32 0, i32 0), <8 x i16> %val4723, i32 0) nounwind + call void @PrintShortX(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str271, i32 0, i32 0), <8 x i16> %val4723, i32 0) nounwind ret i32 undef } diff --git a/test/CodeGen/ARM/2010-07-26-GlobalMerge.ll b/test/CodeGen/ARM/2010-07-26-GlobalMerge.ll index d1259d5bdb6..4c5d8d9af2f 100644 --- a/test/CodeGen/ARM/2010-07-26-GlobalMerge.ll +++ b/test/CodeGen/ARM/2010-07-26-GlobalMerge.ll @@ -9,7 +9,7 @@ target triple = "thumbv7-apple-darwin10.0.0" @d = internal global i32 0, align 4 ; [#uses=6] @_ZTVN10__cxxabiv117__class_type_infoE = external global i8* ; [#uses=1] @_ZTS1A = internal constant [3 x i8] c"1A\00" ; <[3 x i8]*> [#uses=1] -@_ZTI1A = internal constant %0 { i8* bitcast (i8** getelementptr inbounds (i8** @_ZTVN10__cxxabiv117__class_type_infoE, i32 2) to i8*), i8* getelementptr inbounds ([3 x i8]* @_ZTS1A, i32 0, i32 0) } ; <%0*> [#uses=1] +@_ZTI1A = internal constant %0 { i8* bitcast (i8** getelementptr inbounds (i8*, i8** @_ZTVN10__cxxabiv117__class_type_infoE, i32 2) to i8*), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @_ZTS1A, i32 0, i32 0) } ; <%0*> [#uses=1] @.str2 = private constant [18 x i8] c"c == %d, d == %d\0A\00" ; <[18 x i8]*> [#uses=1] @.str3 = private constant [16 x i8] c"A(const A&) %d\0A\00" ; <[16 x i8]*> [#uses=1] @.str4 = private constant [9 x i8] c"~A() %d\0A\00" ; <[9 x i8]*> [#uses=1] @@ -31,7 +31,7 @@ define internal void @_ZN1AD1Ev(%struct.A* nocapture %this) nounwind ssp align 2 entry: %tmp.i = getelementptr inbounds %struct.A, %struct.A* %this, i32 0, i32 0 ; [#uses=1] %tmp2.i = load i32, i32* %tmp.i ; [#uses=1] - %call.i = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([9 x i8]* @.str4, i32 0, i32 0), i32 %tmp2.i) nounwind ; [#uses=0] + %call.i = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str4, i32 0, i32 0), i32 %tmp2.i) nounwind ; [#uses=0] %tmp3.i = load i32, i32* @d ; [#uses=1] %inc.i = add nsw i32 %tmp3.i, 1 ; [#uses=1] store i32 %inc.i, i32* @d @@ -42,11 +42,11 @@ declare void @__cxa_throw(i8*, i8*, i8*) define i32 @main() ssp { entry: - %puts.i = tail call i32 @puts(i8* getelementptr inbounds ([14 x i8]* @str, i32 0, i32 0)) ; [#uses=0] + %puts.i = tail call i32 @puts(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @str, i32 0, i32 0)) ; [#uses=0] %exception.i = tail call i8* @__cxa_allocate_exception(i32 4) nounwind ; [#uses=2] %tmp2.i.i.i = bitcast i8* %exception.i to i32* ; [#uses=1] store i32 1, i32* %tmp2.i.i.i - %call.i.i.i = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([8 x i8]* @.str5, i32 0, i32 0), i32 1) nounwind ; [#uses=0] + %call.i.i.i = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str5, i32 0, i32 0), i32 1) nounwind ; [#uses=0] invoke void @__cxa_throw(i8* %exception.i, i8* bitcast (%0* @_ZTI1A to i8*), i8* bitcast (void (%struct.A*)* @_ZN1AD1Ev to i8*)) noreturn to label %.noexc unwind label %lpad @@ -55,16 +55,16 @@ entry: try.cont: ; preds = %lpad %0 = tail call i8* @__cxa_get_exception_ptr(i8* %exn) nounwind ; [#uses=0] - %call.i.i = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([16 x i8]* @.str3, i32 0, i32 0), i32 2) nounwind ; [#uses=0] + %call.i.i = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str3, i32 0, i32 0), i32 2) nounwind ; [#uses=0] %1 = tail call i8* @__cxa_begin_catch(i8* %exn) nounwind ; [#uses=0] - %puts = tail call i32 @puts(i8* getelementptr inbounds ([8 x i8]* @str1, i32 0, i32 0)) ; [#uses=0] - %call.i.i3 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([9 x i8]* @.str4, i32 0, i32 0), i32 2) nounwind ; [#uses=0] + %puts = tail call i32 @puts(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @str1, i32 0, i32 0)) ; [#uses=0] + %call.i.i3 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str4, i32 0, i32 0), i32 2) nounwind ; [#uses=0] %tmp3.i.i = load i32, i32* @d ; [#uses=1] %inc.i.i4 = add nsw i32 %tmp3.i.i, 1 ; [#uses=1] store i32 %inc.i.i4, i32* @d tail call void @__cxa_end_catch() %tmp13 = load i32, i32* @d ; [#uses=1] - %call14 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([18 x i8]* @.str2, i32 0, i32 0), i32 2, i32 %tmp13) ; [#uses=0] + %call14 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str2, i32 0, i32 0), i32 2, i32 %tmp13) ; [#uses=0] %tmp16 = load i32, i32* @d ; [#uses=1] %cmp = icmp ne i32 %tmp16, 2 ; [#uses=1] %conv = zext i1 %cmp to i32 ; [#uses=1] diff --git a/test/CodeGen/ARM/2011-04-26-SchedTweak.ll b/test/CodeGen/ARM/2011-04-26-SchedTweak.ll index 132b78e153b..ee6d79c39f2 100644 --- a/test/CodeGen/ARM/2011-04-26-SchedTweak.ll +++ b/test/CodeGen/ARM/2011-04-26-SchedTweak.ll @@ -48,7 +48,7 @@ bb1: %tmp10 = zext i32 %tmp6 to i64 %tmp11 = zext i32 %tmp5 to i64 %tmp12 = mul nsw i64 %tmp10, %tmp11 - %tmp13 = call i32 @foo(i8* getelementptr inbounds ([6 x i8]* @.str1, i32 0, i32 0), i64 %tmp12, i32 %tmp5) nounwind + %tmp13 = call i32 @foo(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str1, i32 0, i32 0), i64 %tmp12, i32 %tmp5) nounwind br label %bb8 bb4: diff --git a/test/CodeGen/ARM/2011-11-28-DAGCombineBug.ll b/test/CodeGen/ARM/2011-11-28-DAGCombineBug.ll index c2cafaac6be..d820d688fde 100644 --- a/test/CodeGen/ARM/2011-11-28-DAGCombineBug.ll +++ b/test/CodeGen/ARM/2011-11-28-DAGCombineBug.ll @@ -15,14 +15,14 @@ define hidden void @foo() { ; CHECK: ldr.w ; CHECK-NOT: ldm entry: - %tmp13 = load i32, i32* getelementptr inbounds (%struct.InformationBlock* @infoBlock, i32 0, i32 1, i32 0, i32 0), align 1 - %tmp15 = load i32, i32* getelementptr inbounds (%struct.InformationBlock* @infoBlock, i32 0, i32 1, i32 0, i32 1), align 1 - %tmp17 = load i32, i32* getelementptr inbounds (%struct.InformationBlock* @infoBlock, i32 0, i32 1, i32 0, i32 2), align 1 - %tmp19 = load i32, i32* getelementptr inbounds (%struct.InformationBlock* @infoBlock, i32 0, i32 1, i32 0, i32 3), align 1 - %tmp = load i32, i32* getelementptr inbounds (%struct.InformationBlock* @infoBlock, i32 0, i32 2, i32 0, i32 0), align 1 - %tmp3 = load i32, i32* getelementptr inbounds (%struct.InformationBlock* @infoBlock, i32 0, i32 2, i32 0, i32 1), align 1 - %tmp4 = load i32, i32* getelementptr inbounds (%struct.InformationBlock* @infoBlock, i32 0, i32 2, i32 0, i32 2), align 1 - %tmp5 = load i32, i32* getelementptr inbounds (%struct.InformationBlock* @infoBlock, i32 0, i32 2, i32 0, i32 3), align 1 + %tmp13 = load i32, i32* getelementptr inbounds (%struct.InformationBlock, %struct.InformationBlock* @infoBlock, i32 0, i32 1, i32 0, i32 0), align 1 + %tmp15 = load i32, i32* getelementptr inbounds (%struct.InformationBlock, %struct.InformationBlock* @infoBlock, i32 0, i32 1, i32 0, i32 1), align 1 + %tmp17 = load i32, i32* getelementptr inbounds (%struct.InformationBlock, %struct.InformationBlock* @infoBlock, i32 0, i32 1, i32 0, i32 2), align 1 + %tmp19 = load i32, i32* getelementptr inbounds (%struct.InformationBlock, %struct.InformationBlock* @infoBlock, i32 0, i32 1, i32 0, i32 3), align 1 + %tmp = load i32, i32* getelementptr inbounds (%struct.InformationBlock, %struct.InformationBlock* @infoBlock, i32 0, i32 2, i32 0, i32 0), align 1 + %tmp3 = load i32, i32* getelementptr inbounds (%struct.InformationBlock, %struct.InformationBlock* @infoBlock, i32 0, i32 2, i32 0, i32 1), align 1 + %tmp4 = load i32, i32* getelementptr inbounds (%struct.InformationBlock, %struct.InformationBlock* @infoBlock, i32 0, i32 2, i32 0, i32 2), align 1 + %tmp5 = load i32, i32* getelementptr inbounds (%struct.InformationBlock, %struct.InformationBlock* @infoBlock, i32 0, i32 2, i32 0, i32 3), align 1 %insert21 = insertvalue [4 x i32] undef, i32 %tmp13, 0 %insert23 = insertvalue [4 x i32] %insert21, i32 %tmp15, 1 %insert25 = insertvalue [4 x i32] %insert23, i32 %tmp17, 2 diff --git a/test/CodeGen/ARM/2012-02-01-CoalescerBug.ll b/test/CodeGen/ARM/2012-02-01-CoalescerBug.ll index 2495b306ab0..b0411384b96 100644 --- a/test/CodeGen/ARM/2012-02-01-CoalescerBug.ll +++ b/test/CodeGen/ARM/2012-02-01-CoalescerBug.ll @@ -10,7 +10,7 @@ target triple = "armv7-none-linux-gnueabi" @foo = external global %0, align 16 define arm_aapcs_vfpcc void @bar(float, i1 zeroext, i1 zeroext) nounwind { - %4 = load <4 x float>, <4 x float>* getelementptr inbounds (%0* @foo, i32 0, i32 0), align 16 + %4 = load <4 x float>, <4 x float>* getelementptr inbounds (%0, %0* @foo, i32 0, i32 0), align 16 %5 = extractelement <4 x float> %4, i32 0 %6 = extractelement <4 x float> %4, i32 1 %7 = extractelement <4 x float> %4, i32 2 diff --git a/test/CodeGen/ARM/2012-10-04-FixedFrame-vs-byval.ll b/test/CodeGen/ARM/2012-10-04-FixedFrame-vs-byval.ll index 203ba4db361..ef06f59b0f4 100644 --- a/test/CodeGen/ARM/2012-10-04-FixedFrame-vs-byval.ll +++ b/test/CodeGen/ARM/2012-10-04-FixedFrame-vs-byval.ll @@ -14,6 +14,6 @@ define void @test_byval_usage_scheduling(i32 %n1, i32 %n2, %struct_t* byval %val entry: %a = getelementptr inbounds %struct_t, %struct_t* %val, i32 0, i32 0 %0 = load double, double* %a - %call = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([12 x i8]* @.str, i32 0, i32 0), double %0) + %call = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i32 0, i32 0), double %0) ret void } diff --git a/test/CodeGen/ARM/2013-04-21-AAPCS-VA-C.1.cp.ll b/test/CodeGen/ARM/2013-04-21-AAPCS-VA-C.1.cp.ll index 0e0537ec5bf..427519f8a84 100644 --- a/test/CodeGen/ARM/2013-04-21-AAPCS-VA-C.1.cp.ll +++ b/test/CodeGen/ARM/2013-04-21-AAPCS-VA-C.1.cp.ll @@ -15,7 +15,7 @@ entry: %conv = sext i16 %b to i32 %conv1 = sext i8 %E to i32 %call = tail call i32 (i8*, ...)* @printf( - i8* getelementptr inbounds ([13 x i8]* @.str, i32 0, i32 0), ; --> R0 + i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i32 0, i32 0), ; --> R0 i32 %a, ; --> R1 i32 %conv, ; --> R2 double %C, ; --> SP, NCRN := R4 diff --git a/test/CodeGen/ARM/Windows/read-only-data.ll b/test/CodeGen/ARM/Windows/read-only-data.ll index 0438d68b55c..c387d1d5137 100644 --- a/test/CodeGen/ARM/Windows/read-only-data.ll +++ b/test/CodeGen/ARM/Windows/read-only-data.ll @@ -6,7 +6,7 @@ declare arm_aapcs_vfpcc void @callee(i8*) define arm_aapcs_vfpcc void @function() { entry: - call arm_aapcs_vfpcc void @callee(i8* getelementptr inbounds ([7 x i8]* @.str, i32 0, i32 0)) + call arm_aapcs_vfpcc void @callee(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i32 0, i32 0)) ret void } diff --git a/test/CodeGen/ARM/arm-ttype-target2.ll b/test/CodeGen/ARM/arm-ttype-target2.ll index 4d61cb5bb3a..754a16d9087 100644 --- a/test/CodeGen/ARM/arm-ttype-target2.ll +++ b/test/CodeGen/ARM/arm-ttype-target2.ll @@ -2,7 +2,7 @@ @_ZTVN10__cxxabiv117__class_type_infoE = external global i8* @_ZTS3Foo = linkonce_odr constant [5 x i8] c"3Foo\00" -@_ZTI3Foo = linkonce_odr unnamed_addr constant { i8*, i8* } { i8* bitcast (i8** getelementptr inbounds (i8** @_ZTVN10__cxxabiv117__class_type_infoE, i32 2) to i8*), i8* getelementptr inbounds ([5 x i8]* @_ZTS3Foo, i32 0, i32 0) } +@_ZTI3Foo = linkonce_odr unnamed_addr constant { i8*, i8* } { i8* bitcast (i8** getelementptr inbounds (i8*, i8** @_ZTVN10__cxxabiv117__class_type_infoE, i32 2) to i8*), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @_ZTS3Foo, i32 0, i32 0) } define i32 @main() { entry: diff --git a/test/CodeGen/ARM/cache-intrinsic.ll b/test/CodeGen/ARM/cache-intrinsic.ll index 6048917ee9a..a041d075751 100644 --- a/test/CodeGen/ARM/cache-intrinsic.ll +++ b/test/CodeGen/ARM/cache-intrinsic.ll @@ -10,10 +10,10 @@ define i32 @main() { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval - %call = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([4 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([32 x i8]* @buffer, i32 0, i32 0)) - %call1 = call i8* @strcpy(i8* getelementptr inbounds ([32 x i8]* @buffer, i32 0, i32 0), i8* getelementptr inbounds ([25 x i8]* @.str1, i32 0, i32 0)) #3 - call void @llvm.clear_cache(i8* getelementptr inbounds ([32 x i8]* @buffer, i32 0, i32 0), i8* getelementptr inbounds (i8* getelementptr inbounds ([32 x i8]* @buffer, i32 0, i32 0), i32 32)) #3 - %call2 = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([4 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([32 x i8]* @buffer, i32 0, i32 0)) + %call = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([32 x i8], [32 x i8]* @buffer, i32 0, i32 0)) + %call1 = call i8* @strcpy(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @buffer, i32 0, i32 0), i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str1, i32 0, i32 0)) #3 + call void @llvm.clear_cache(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @buffer, i32 0, i32 0), i8* getelementptr inbounds (i8, i8* getelementptr inbounds ([32 x i8], [32 x i8]* @buffer, i32 0, i32 0), i32 32)) #3 + %call2 = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([32 x i8], [32 x i8]* @buffer, i32 0, i32 0)) ret i32 0 } diff --git a/test/CodeGen/ARM/crash-O0.ll b/test/CodeGen/ARM/crash-O0.ll index 8855bb99aaf..f92af999be5 100644 --- a/test/CodeGen/ARM/crash-O0.ll +++ b/test/CodeGen/ARM/crash-O0.ll @@ -21,8 +21,8 @@ entry: %letter = alloca i8 ; [#uses=0] %prodvers = alloca [256 x i8] ; <[256 x i8]*> [#uses=1] %buildver = alloca [256 x i8] ; <[256 x i8]*> [#uses=0] - call void @llvm.memcpy.p0i8.p0i8.i32(i8* undef, i8* getelementptr inbounds ([256 x i8]* @.str523, i32 0, i32 0), i32 256, i32 1, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i32(i8* undef, i8* getelementptr inbounds ([256 x i8], [256 x i8]* @.str523, i32 0, i32 0), i32 256, i32 1, i1 false) %prodvers2 = bitcast [256 x i8]* %prodvers to i8* ; [#uses=1] - call void @llvm.memcpy.p0i8.p0i8.i32(i8* %prodvers2, i8* getelementptr inbounds ([256 x i8]* @.str523, i32 0, i32 0), i32 256, i32 1, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i32(i8* %prodvers2, i8* getelementptr inbounds ([256 x i8], [256 x i8]* @.str523, i32 0, i32 0), i32 256, i32 1, i1 false) unreachable } diff --git a/test/CodeGen/ARM/cse-call.ll b/test/CodeGen/ARM/cse-call.ll index eff5de5a242..4e61a3495b8 100644 --- a/test/CodeGen/ARM/cse-call.ll +++ b/test/CodeGen/ARM/cse-call.ll @@ -23,8 +23,8 @@ while.body37: ; preds = %while.body37, %entr br i1 false, label %while.end42, label %while.body37 while.end42: ; preds = %while.body37, %entry - %. = select i1 undef, i8* getelementptr inbounds ([200 x i8]* @F_floatmul.man1, i32 0, i32 0), i8* getelementptr inbounds ([200 x i8]* @F_floatmul.man2, i32 0, i32 0) - %.92 = select i1 undef, i8* getelementptr inbounds ([200 x i8]* @F_floatmul.man2, i32 0, i32 0), i8* getelementptr inbounds ([200 x i8]* @F_floatmul.man1, i32 0, i32 0) + %. = select i1 undef, i8* getelementptr inbounds ([200 x i8], [200 x i8]* @F_floatmul.man1, i32 0, i32 0), i8* getelementptr inbounds ([200 x i8], [200 x i8]* @F_floatmul.man2, i32 0, i32 0) + %.92 = select i1 undef, i8* getelementptr inbounds ([200 x i8], [200 x i8]* @F_floatmul.man2, i32 0, i32 0), i8* getelementptr inbounds ([200 x i8], [200 x i8]* @F_floatmul.man1, i32 0, i32 0) tail call void bitcast (void (...)* @S_trimzeros to void (i8*)*)(i8* %.92) nounwind %call47 = tail call i32 @strlen(i8* %.) nounwind unreachable diff --git a/test/CodeGen/ARM/cse-ldrlit.ll b/test/CodeGen/ARM/cse-ldrlit.ll index e76e47eea30..4f369d0a78e 100644 --- a/test/CodeGen/ARM/cse-ldrlit.ll +++ b/test/CodeGen/ARM/cse-ldrlit.ll @@ -9,11 +9,11 @@ declare void @bar(i32*) define void @foo() { - %flag = load i32, i32* getelementptr inbounds([16 x i32]* @var, i32 0, i32 1) + %flag = load i32, i32* getelementptr inbounds([16 x i32], [16 x i32]* @var, i32 0, i32 1) %tst = icmp eq i32 %flag, 0 br i1 %tst, label %true, label %false true: - tail call void @bar(i32* getelementptr inbounds([16 x i32]* @var, i32 0, i32 4)) + tail call void @bar(i32* getelementptr inbounds([16 x i32], [16 x i32]* @var, i32 0, i32 4)) ret void false: ret void diff --git a/test/CodeGen/ARM/debug-info-branch-folding.ll b/test/CodeGen/ARM/debug-info-branch-folding.ll index 6d6b90503ea..bd2ae80e3a4 100644 --- a/test/CodeGen/ARM/debug-info-branch-folding.ll +++ b/test/CodeGen/ARM/debug-info-branch-folding.ll @@ -28,10 +28,10 @@ for.body9: ; preds = %for.body9, %entry for.end54: ; preds = %for.body9 %tmp115 = extractelement <4 x float> %add19, i32 1 %conv6.i75 = fpext float %tmp115 to double, !dbg !45 - %call.i82 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([13 x i8]* @.str, i32 0, i32 0), double undef, double %conv6.i75, double undef, double undef) nounwind, !dbg !45 + %call.i82 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i32 0, i32 0), double undef, double %conv6.i75, double undef, double undef) nounwind, !dbg !45 %tmp116 = extractelement <4 x float> %add20, i32 1 %conv6.i76 = fpext float %tmp116 to double, !dbg !45 - %call.i83 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([13 x i8]* @.str, i32 0, i32 0), double undef, double %conv6.i76, double undef, double undef) nounwind, !dbg !45 + %call.i83 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i32 0, i32 0), double undef, double %conv6.i76, double undef, double undef) nounwind, !dbg !45 ret i32 0, !dbg !49 } diff --git a/test/CodeGen/ARM/debug-info-d16-reg.ll b/test/CodeGen/ARM/debug-info-d16-reg.ll index 30815b339dc..0667e0f5649 100644 --- a/test/CodeGen/ARM/debug-info-d16-reg.ll +++ b/test/CodeGen/ARM/debug-info-d16-reg.ll @@ -16,7 +16,7 @@ entry: tail call void @llvm.dbg.value(metadata double %val, i64 0, metadata !20, metadata !MDExpression()), !dbg !26 tail call void @llvm.dbg.value(metadata i8 %c, i64 0, metadata !21, metadata !MDExpression()), !dbg !26 %0 = zext i8 %c to i32, !dbg !27 - %1 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([11 x i8]* @.str, i32 0, i32 0), i8* %ptr, double %val, i32 %0) nounwind, !dbg !27 + %1 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i32 0, i32 0), i8* %ptr, double %val, i32 %0) nounwind, !dbg !27 ret i32 0, !dbg !29 } @@ -26,7 +26,7 @@ entry: tail call void @llvm.dbg.value(metadata double %val, i64 0, metadata !17, metadata !MDExpression()), !dbg !30 tail call void @llvm.dbg.value(metadata i8 %c, i64 0, metadata !18, metadata !MDExpression()), !dbg !30 %0 = zext i8 %c to i32, !dbg !31 - %1 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([11 x i8]* @.str, i32 0, i32 0), i8* %ptr, double %val, i32 %0) nounwind, !dbg !31 + %1 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i32 0, i32 0), i8* %ptr, double %val, i32 %0) nounwind, !dbg !31 ret i32 0, !dbg !33 } @@ -41,7 +41,7 @@ entry: %0 = sitofp i32 %argc to double, !dbg !35 %1 = fadd double %0, 5.555552e+05, !dbg !35 tail call void @llvm.dbg.value(metadata double %1, i64 0, metadata !24, metadata !MDExpression()), !dbg !35 - %2 = tail call i32 @puts(i8* getelementptr inbounds ([6 x i8]* @.str1, i32 0, i32 0)) nounwind, !dbg !36 + %2 = tail call i32 @puts(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str1, i32 0, i32 0)) nounwind, !dbg !36 %3 = getelementptr inbounds i8, i8* bitcast (i32 (i32, i8**)* @main to i8*), i32 %argc, !dbg !37 %4 = trunc i32 %argc to i8, !dbg !37 %5 = add i8 %4, 97, !dbg !37 @@ -49,7 +49,7 @@ entry: tail call void @llvm.dbg.value(metadata double %1, i64 0, metadata !20, metadata !MDExpression()) nounwind, !dbg !38 tail call void @llvm.dbg.value(metadata i8 %5, i64 0, metadata !21, metadata !MDExpression()) nounwind, !dbg !38 %6 = zext i8 %5 to i32, !dbg !39 - %7 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([11 x i8]* @.str, i32 0, i32 0), i8* %3, double %1, i32 %6) nounwind, !dbg !39 + %7 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i32 0, i32 0), i8* %3, double %1, i32 %6) nounwind, !dbg !39 %8 = tail call i32 @printer(i8* %3, double %1, i8 zeroext %5) nounwind, !dbg !40 ret i32 0, !dbg !41 } diff --git a/test/CodeGen/ARM/debug-info-qreg.ll b/test/CodeGen/ARM/debug-info-qreg.ll index 7e6cc9750d5..398f652cf02 100644 --- a/test/CodeGen/ARM/debug-info-qreg.ll +++ b/test/CodeGen/ARM/debug-info-qreg.ll @@ -27,7 +27,7 @@ for.end54: ; preds = %for.body9 tail call void @llvm.dbg.value(metadata <4 x float> %add19, i64 0, metadata !27, metadata !MDExpression()), !dbg !39 %tmp115 = extractelement <4 x float> %add19, i32 1 %conv6.i75 = fpext float %tmp115 to double, !dbg !45 - %call.i82 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([13 x i8]* @.str, i32 0, i32 0), double undef, double %conv6.i75, double undef, double undef) nounwind, !dbg !45 + %call.i82 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i32 0, i32 0), double undef, double %conv6.i75, double undef, double undef) nounwind, !dbg !45 ret i32 0, !dbg !49 } diff --git a/test/CodeGen/ARM/debug-info-s16-reg.ll b/test/CodeGen/ARM/debug-info-s16-reg.ll index e3f9f231d79..d08ec035be1 100644 --- a/test/CodeGen/ARM/debug-info-s16-reg.ll +++ b/test/CodeGen/ARM/debug-info-s16-reg.ll @@ -19,7 +19,7 @@ entry: tail call void @llvm.dbg.value(metadata i8 %c, i64 0, metadata !12, metadata !MDExpression()), !dbg !26 %conv = fpext float %val to double, !dbg !27 %conv3 = zext i8 %c to i32, !dbg !27 - %call = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([11 x i8]* @.str, i32 0, i32 0), i8* %ptr, double %conv, i32 %conv3) nounwind optsize, !dbg !27 + %call = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i32 0, i32 0), i8* %ptr, double %conv, i32 %conv3) nounwind optsize, !dbg !27 ret i32 0, !dbg !29 } @@ -32,7 +32,7 @@ entry: tail call void @llvm.dbg.value(metadata i8 %c, i64 0, metadata !16, metadata !MDExpression()), !dbg !32 %conv = fpext float %val to double, !dbg !33 %conv3 = zext i8 %c to i32, !dbg !33 - %call = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([11 x i8]* @.str, i32 0, i32 0), i8* %ptr, double %conv, i32 %conv3) nounwind optsize, !dbg !33 + %call = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i32 0, i32 0), i8* %ptr, double %conv, i32 %conv3) nounwind optsize, !dbg !33 ret i32 0, !dbg !35 } @@ -44,7 +44,7 @@ entry: %add = fadd double %conv, 5.555552e+05, !dbg !38 %conv1 = fptrunc double %add to float, !dbg !38 tail call void @llvm.dbg.value(metadata float %conv1, i64 0, metadata !22, metadata !MDExpression()), !dbg !38 - %call = tail call i32 @puts(i8* getelementptr inbounds ([6 x i8]* @.str1, i32 0, i32 0)) nounwind optsize, !dbg !39 + %call = tail call i32 @puts(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str1, i32 0, i32 0)) nounwind optsize, !dbg !39 %add.ptr = getelementptr i8, i8* bitcast (i32 (i32, i8**)* @main to i8*), i32 %argc, !dbg !40 %add5 = add nsw i32 %argc, 97, !dbg !40 %conv6 = trunc i32 %add5 to i8, !dbg !40 @@ -53,7 +53,7 @@ entry: tail call void @llvm.dbg.value(metadata i8 %conv6, i64 0, metadata !12, metadata !MDExpression()) nounwind, !dbg !43 %conv.i = fpext float %conv1 to double, !dbg !44 %conv3.i = and i32 %add5, 255, !dbg !44 - %call.i = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([11 x i8]* @.str, i32 0, i32 0), i8* %add.ptr, double %conv.i, i32 %conv3.i) nounwind optsize, !dbg !44 + %call.i = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i32 0, i32 0), i8* %add.ptr, double %conv.i, i32 %conv3.i) nounwind optsize, !dbg !44 %call14 = tail call i32 @printer(i8* %add.ptr, float %conv1, i8 zeroext %conv6) optsize, !dbg !45 ret i32 0, !dbg !46 } diff --git a/test/CodeGen/ARM/dwarf-eh.ll b/test/CodeGen/ARM/dwarf-eh.ll index 228d8b9e40e..c890206b353 100644 --- a/test/CodeGen/ARM/dwarf-eh.ll +++ b/test/CodeGen/ARM/dwarf-eh.ll @@ -15,7 +15,7 @@ target triple = "armv5e--netbsd-eabi" @_ZTVN10__cxxabiv117__class_type_infoE = external global i8* @_ZTS9exception = linkonce_odr constant [11 x i8] c"9exception\00" -@_ZTI9exception = linkonce_odr unnamed_addr constant { i8*, i8* } { i8* bitcast (i8** getelementptr inbounds (i8** @_ZTVN10__cxxabiv117__class_type_infoE, i32 2) to i8*), i8* getelementptr inbounds ([11 x i8]* @_ZTS9exception, i32 0, i32 0) } +@_ZTI9exception = linkonce_odr unnamed_addr constant { i8*, i8* } { i8* bitcast (i8** getelementptr inbounds (i8*, i8** @_ZTVN10__cxxabiv117__class_type_infoE, i32 2) to i8*), i8* getelementptr inbounds ([11 x i8], [11 x i8]* @_ZTS9exception, i32 0, i32 0) } define void @f() uwtable { %1 = alloca i8* diff --git a/test/CodeGen/ARM/dyn-stackalloc.ll b/test/CodeGen/ARM/dyn-stackalloc.ll index 1b64a01aee1..5b963fd64de 100644 --- a/test/CodeGen/ARM/dyn-stackalloc.ll +++ b/test/CodeGen/ARM/dyn-stackalloc.ll @@ -51,7 +51,7 @@ define void @t2(%struct.comment* %vc, i8* %tag, i8* %contents) { %tmp9 = call i8* @strcpy(i8* %tmp6, i8* %tag) %tmp6.len = call i32 @strlen(i8* %tmp6) %tmp6.indexed = getelementptr i8, i8* %tmp6, i32 %tmp6.len - call void @llvm.memcpy.p0i8.p0i8.i32(i8* %tmp6.indexed, i8* getelementptr inbounds ([2 x i8]* @str215, i32 0, i32 0), i32 2, i32 1, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i32(i8* %tmp6.indexed, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @str215, i32 0, i32 0), i32 2, i32 1, i1 false) %tmp15 = call i8* @strcat(i8* %tmp6, i8* %contents) call fastcc void @comment_add(%struct.comment* %vc, i8* %tmp6) ret void diff --git a/test/CodeGen/ARM/fast-isel-GEP-coalesce.ll b/test/CodeGen/ARM/fast-isel-GEP-coalesce.ll index a52cd830195..d759d2d52c3 100644 --- a/test/CodeGen/ARM/fast-isel-GEP-coalesce.ll +++ b/test/CodeGen/ARM/fast-isel-GEP-coalesce.ll @@ -14,7 +14,7 @@ entry: ; ARM: t1 ; THUMB: t1 %addr = alloca i32*, align 4 - store i32* getelementptr inbounds ([2 x [2 x [2 x [2 x [2 x i32]]]]]* @arr, i32 0, i32 1, i32 1, i32 1, i32 1, i32 1), i32** %addr, align 4 + store i32* getelementptr inbounds ([2 x [2 x [2 x [2 x [2 x i32]]]]], [2 x [2 x [2 x [2 x [2 x i32]]]]]* @arr, i32 0, i32 1, i32 1, i32 1, i32 1, i32 1), i32** %addr, align 4 ; ARM: add r0, r0, #124 ; THUMB: adds r0, #124 %0 = load i32*, i32** %addr, align 4 @@ -26,7 +26,7 @@ entry: ; ARM: t2 ; THUMB: t2 %addr = alloca i32*, align 4 - store i32* getelementptr inbounds ([3 x [3 x %struct.A]]* @A, i32 0, i32 2, i32 2, i32 3, i32 1, i32 2, i32 2), i32** %addr, align 4 + store i32* getelementptr inbounds ([3 x [3 x %struct.A]], [3 x [3 x %struct.A]]* @A, i32 0, i32 2, i32 2, i32 3, i32 1, i32 2, i32 2), i32** %addr, align 4 ; ARM: movw [[R:r[0-9]+]], #1148 ; ARM: add r0, r{{[0-9]+}}, [[R]] ; THUMB: addw r0, r0, #1148 @@ -39,7 +39,7 @@ entry: ; ARM: t3 ; THUMB: t3 %addr = alloca i32*, align 4 - store i32* getelementptr inbounds ([3 x [3 x %struct.A]]* @A, i32 0, i32 0, i32 1, i32 1, i32 0, i32 1), i32** %addr, align 4 + store i32* getelementptr inbounds ([3 x [3 x %struct.A]], [3 x [3 x %struct.A]]* @A, i32 0, i32 0, i32 1, i32 1, i32 0, i32 1), i32** %addr, align 4 ; ARM: add r0, r0, #140 ; THUMB: adds r0, #140 %0 = load i32*, i32** %addr, align 4 @@ -51,7 +51,7 @@ entry: ; ARM: t4 ; THUMB: t4 %addr = alloca i32*, align 4 - store i32* getelementptr inbounds ([2 x [2 x [2 x %struct.B]]]* @B, i32 0, i32 0, i32 0, i32 1, i32 1, i32 0, i32 0, i32 1, i32 3, i32 1, i32 2, i32 1), i32** %addr, align 4 + store i32* getelementptr inbounds ([2 x [2 x [2 x %struct.B]]], [2 x [2 x [2 x %struct.B]]]* @B, i32 0, i32 0, i32 0, i32 1, i32 1, i32 0, i32 0, i32 1, i32 3, i32 1, i32 2, i32 1), i32** %addr, align 4 ; ARM-NOT: movw r{{[0-9]}}, #1060 ; ARM-NOT: add r{{[0-9]}}, r{{[0-9]}}, #4 ; ARM-NOT: add r{{[0-9]}}, r{{[0-9]}}, #132 diff --git a/test/CodeGen/ARM/fast-isel-align.ll b/test/CodeGen/ARM/fast-isel-align.ll index 3d98dcc1fb2..39085db9531 100644 --- a/test/CodeGen/ARM/fast-isel-align.ll +++ b/test/CodeGen/ARM/fast-isel-align.ll @@ -51,7 +51,7 @@ entry: ; ARM: @word_aligned_f64_store ; THUMB: @word_aligned_f64_store %add = fadd double %a, %b - store double %add, double* getelementptr inbounds (%struct.anon.0* @foo_unpacked, i32 0, i32 0), align 4 + store double %add, double* getelementptr inbounds (%struct.anon.0, %struct.anon.0* @foo_unpacked, i32 0, i32 0), align 4 ; ARM: vstr d16, [r0] ; THUMB: vstr d16, [r0] ret void diff --git a/test/CodeGen/ARM/fast-isel-intrinsic.ll b/test/CodeGen/ARM/fast-isel-intrinsic.ll index 58f34f6ab1a..6b434b74ca7 100644 --- a/test/CodeGen/ARM/fast-isel-intrinsic.ll +++ b/test/CodeGen/ARM/fast-isel-intrinsic.ll @@ -39,7 +39,7 @@ define void @t1() nounwind ssp { ; THUMB-LONG: movt r3, :upper16:L_memset$non_lazy_ptr ; THUMB-LONG: ldr r3, [r3] ; THUMB-LONG: blx r3 - call void @llvm.memset.p0i8.i32(i8* getelementptr inbounds ([60 x i8]* @message1, i32 0, i32 5), i8 64, i32 10, i32 4, i1 false) + call void @llvm.memset.p0i8.i32(i8* getelementptr inbounds ([60 x i8], [60 x i8]* @message1, i32 0, i32 5), i8 64, i32 10, i32 4, i1 false) ret void } @@ -78,7 +78,7 @@ define void @t2() nounwind ssp { ; THUMB-LONG: movt r3, :upper16:L_memcpy$non_lazy_ptr ; THUMB-LONG: ldr r3, [r3] ; THUMB-LONG: blx r3 - call void @llvm.memcpy.p0i8.p0i8.i32(i8* getelementptr inbounds ([60 x i8]* @temp, i32 0, i32 4), i8* getelementptr inbounds ([60 x i8]* @temp, i32 0, i32 16), i32 17, i32 4, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i32(i8* getelementptr inbounds ([60 x i8], [60 x i8]* @temp, i32 0, i32 4), i8* getelementptr inbounds ([60 x i8], [60 x i8]* @temp, i32 0, i32 16), i32 17, i32 4, i1 false) ret void } @@ -115,7 +115,7 @@ define void @t3() nounwind ssp { ; THUMB-LONG: movt r3, :upper16:L_memmove$non_lazy_ptr ; THUMB-LONG: ldr r3, [r3] ; THUMB-LONG: blx r3 - call void @llvm.memmove.p0i8.p0i8.i32(i8* getelementptr inbounds ([60 x i8]* @temp, i32 0, i32 4), i8* getelementptr inbounds ([60 x i8]* @temp, i32 0, i32 16), i32 10, i32 1, i1 false) + call void @llvm.memmove.p0i8.p0i8.i32(i8* getelementptr inbounds ([60 x i8], [60 x i8]* @temp, i32 0, i32 4), i8* getelementptr inbounds ([60 x i8], [60 x i8]* @temp, i32 0, i32 16), i32 10, i32 1, i1 false) ret void } @@ -142,7 +142,7 @@ define void @t4() nounwind ssp { ; THUMB: ldrh r1, [r0, #24] ; THUMB: strh r1, [r0, #12] ; THUMB: bx lr - call void @llvm.memcpy.p0i8.p0i8.i32(i8* getelementptr inbounds ([60 x i8]* @temp, i32 0, i32 4), i8* getelementptr inbounds ([60 x i8]* @temp, i32 0, i32 16), i32 10, i32 4, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i32(i8* getelementptr inbounds ([60 x i8], [60 x i8]* @temp, i32 0, i32 4), i8* getelementptr inbounds ([60 x i8], [60 x i8]* @temp, i32 0, i32 16), i32 10, i32 4, i1 false) ret void } @@ -179,7 +179,7 @@ define void @t5() nounwind ssp { ; THUMB: ldrh r1, [r0, #24] ; THUMB: strh r1, [r0, #12] ; THUMB: bx lr - call void @llvm.memcpy.p0i8.p0i8.i32(i8* getelementptr inbounds ([60 x i8]* @temp, i32 0, i32 4), i8* getelementptr inbounds ([60 x i8]* @temp, i32 0, i32 16), i32 10, i32 2, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i32(i8* getelementptr inbounds ([60 x i8], [60 x i8]* @temp, i32 0, i32 4), i8* getelementptr inbounds ([60 x i8], [60 x i8]* @temp, i32 0, i32 16), i32 10, i32 2, i1 false) ret void } @@ -234,14 +234,14 @@ define void @t6() nounwind ssp { ; THUMB: ldrb r1, [r0, #25] ; THUMB: strb r1, [r0, #13] ; THUMB: bx lr - call void @llvm.memcpy.p0i8.p0i8.i32(i8* getelementptr inbounds ([60 x i8]* @temp, i32 0, i32 4), i8* getelementptr inbounds ([60 x i8]* @temp, i32 0, i32 16), i32 10, i32 1, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i32(i8* getelementptr inbounds ([60 x i8], [60 x i8]* @temp, i32 0, i32 4), i8* getelementptr inbounds ([60 x i8], [60 x i8]* @temp, i32 0, i32 16), i32 10, i32 1, i1 false) ret void } ; rdar://13202135 define void @t7() nounwind ssp { ; Just make sure this doesn't assert when we have an odd length and an alignment of 2. - call void @llvm.memcpy.p0i8.p0i8.i32(i8* getelementptr inbounds ([60 x i8]* @temp, i32 0, i32 4), i8* getelementptr inbounds ([60 x i8]* @temp, i32 0, i32 16), i32 3, i32 2, i1 false) + call void @llvm.memcpy.p0i8.p0i8.i32(i8* getelementptr inbounds ([60 x i8], [60 x i8]* @temp, i32 0, i32 4), i8* getelementptr inbounds ([60 x i8], [60 x i8]* @temp, i32 0, i32 16), i32 3, i32 2, i1 false) ret void } diff --git a/test/CodeGen/ARM/global-merge-1.ll b/test/CodeGen/ARM/global-merge-1.ll index 20b4ba5bceb..5db4b0086ec 100644 --- a/test/CodeGen/ARM/global-merge-1.ll +++ b/test/CodeGen/ARM/global-merge-1.ll @@ -29,25 +29,25 @@ target triple = "thumbv7-apple-ios3.0.0" ; Function Attrs: nounwind ssp define internal void @initialize() #0 { %1 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #3 - store i32 %1, i32* getelementptr inbounds ([5 x i32]* @bar, i32 0, i32 0), align 4, !tbaa !1 + store i32 %1, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i32 0, i32 0), align 4, !tbaa !1 %2 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #3 - store i32 %2, i32* getelementptr inbounds ([5 x i32]* @baz, i32 0, i32 0), align 4, !tbaa !1 + store i32 %2, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i32 0, i32 0), align 4, !tbaa !1 %3 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #3 - store i32 %3, i32* getelementptr inbounds ([5 x i32]* @bar, i32 0, i32 1), align 4, !tbaa !1 + store i32 %3, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i32 0, i32 1), align 4, !tbaa !1 %4 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #3 - store i32 %4, i32* getelementptr inbounds ([5 x i32]* @baz, i32 0, i32 1), align 4, !tbaa !1 + store i32 %4, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i32 0, i32 1), align 4, !tbaa !1 %5 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #3 - store i32 %5, i32* getelementptr inbounds ([5 x i32]* @bar, i32 0, i32 2), align 4, !tbaa !1 + store i32 %5, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i32 0, i32 2), align 4, !tbaa !1 %6 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #3 - store i32 %6, i32* getelementptr inbounds ([5 x i32]* @baz, i32 0, i32 2), align 4, !tbaa !1 + store i32 %6, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i32 0, i32 2), align 4, !tbaa !1 %7 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #3 - store i32 %7, i32* getelementptr inbounds ([5 x i32]* @bar, i32 0, i32 3), align 4, !tbaa !1 + store i32 %7, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i32 0, i32 3), align 4, !tbaa !1 %8 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #3 - store i32 %8, i32* getelementptr inbounds ([5 x i32]* @baz, i32 0, i32 3), align 4, !tbaa !1 + store i32 %8, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i32 0, i32 3), align 4, !tbaa !1 %9 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #3 - store i32 %9, i32* getelementptr inbounds ([5 x i32]* @bar, i32 0, i32 4), align 4, !tbaa !1 + store i32 %9, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i32 0, i32 4), align 4, !tbaa !1 %10 = tail call i32 bitcast (i32 (...)* @calc to i32 ()*)() #3 - store i32 %10, i32* getelementptr inbounds ([5 x i32]* @baz, i32 0, i32 4), align 4, !tbaa !1 + store i32 %10, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i32 0, i32 4), align 4, !tbaa !1 ret void } @@ -59,16 +59,16 @@ define internal void @calculate() #0 { %2 = load <4 x i32>, <4 x i32>* bitcast ([5 x i32]* @baz to <4 x i32>*), align 4 %3 = mul <4 x i32> %2, %1 store <4 x i32> %3, <4 x i32>* bitcast ([5 x i32]* @foo to <4 x i32>*), align 4 - %4 = load i32, i32* getelementptr inbounds ([5 x i32]* @bar, i32 0, i32 4), align 4, !tbaa !1 - %5 = load i32, i32* getelementptr inbounds ([5 x i32]* @baz, i32 0, i32 4), align 4, !tbaa !1 + %4 = load i32, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @bar, i32 0, i32 4), align 4, !tbaa !1 + %5 = load i32, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @baz, i32 0, i32 4), align 4, !tbaa !1 %6 = mul nsw i32 %5, %4 - store i32 %6, i32* getelementptr inbounds ([5 x i32]* @foo, i32 0, i32 4), align 4, !tbaa !1 + store i32 %6, i32* getelementptr inbounds ([5 x i32], [5 x i32]* @foo, i32 0, i32 4), align 4, !tbaa !1 ret void } ; Function Attrs: nounwind readnone ssp define internal i32* @returnFoo() #2 { - ret i32* getelementptr inbounds ([5 x i32]* @foo, i32 0, i32 0) + ret i32* getelementptr inbounds ([5 x i32], [5 x i32]* @foo, i32 0, i32 0) } attributes #0 = { nounwind ssp "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "no-frame-pointer-elim-non-leaf" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "stack-protector-buffer-size"="8" "unsafe-fp-math"="false" "use-soft-float"="false" } diff --git a/test/CodeGen/ARM/hello.ll b/test/CodeGen/ARM/hello.ll index d2685854dba..08e6104bbcf 100644 --- a/test/CodeGen/ARM/hello.ll +++ b/test/CodeGen/ARM/hello.ll @@ -10,7 +10,7 @@ @str = internal constant [12 x i8] c"Hello World\00" define i32 @main() { - %tmp = call i32 @puts( i8* getelementptr ([12 x i8]* @str, i32 0, i64 0) ) ; [#uses=0] + %tmp = call i32 @puts( i8* getelementptr ([12 x i8], [12 x i8]* @str, i32 0, i64 0) ) ; [#uses=0] ret i32 0 } diff --git a/test/CodeGen/ARM/ifconv-regmask.ll b/test/CodeGen/ARM/ifconv-regmask.ll index 11ad6f23544..2144ca6e407 100644 --- a/test/CodeGen/ARM/ifconv-regmask.ll +++ b/test/CodeGen/ARM/ifconv-regmask.ll @@ -7,7 +7,7 @@ ; Function Attrs: nounwind ssp define i32 @sfu() { entry: - %bf.load = load i32, i32* getelementptr inbounds (%union.opcode* @opcode, i32 0, i32 0), align 4 + %bf.load = load i32, i32* getelementptr inbounds (%union.opcode, %union.opcode* @opcode, i32 0, i32 0), align 4 %bf.lshr = lshr i32 %bf.load, 26 %bf.clear = and i32 %bf.lshr, 7 switch i32 %bf.clear, label %return [ diff --git a/test/CodeGen/ARM/indirectbr-2.ll b/test/CodeGen/ARM/indirectbr-2.ll index 318880a83d9..044fb5610a6 100644 --- a/test/CodeGen/ARM/indirectbr-2.ll +++ b/test/CodeGen/ARM/indirectbr-2.ll @@ -27,7 +27,7 @@ define i32 @func() nounwind ssp { %9 = load i32, i32* %8 %10 = add i32 %9, ptrtoint (i8* blockaddress(@func, %4) to i32) %11 = inttoptr i32 %10 to i8* - %12 = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([45 x i8]* @0, i32 0, i32 0)) + %12 = call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([45 x i8], [45 x i8]* @0, i32 0, i32 0)) indirectbr i8* %11, [label %13, label %14] ;