1. Jun 08, 2014
    • David Majnemer's avatar
      MS ABI: Simplify microsoft mangling of template instantiations · c986fcc9
      David Majnemer authored
      Use mangled template instantiation name as key for back references.
      Templates have their own context for back references, so their mangling
      is always the same regardless of context. This avoids mangling template
      instantiations twice.
      
      Patch by Agustín Bergé!
      
      llvm-svn: 210416
      c986fcc9
    • Saleem Abdulrasool's avatar
      MC: fix text section characteristics for WoA · 70a0206e
      Saleem Abdulrasool authored
      link.exe requires that the text section has the IMAGE_SCN_MEM_16BIT flag set.
      Otherwise, it will treat the function as ARM.  If this occurs, then jumps to the
      function will fail, switching from thumb to ARM mode execution.
      
      With this change, it is possible to link using the MSVC linker as well.
      
      llvm-svn: 210415
      70a0206e
    • Reed Kotler's avatar
      Do materialize for floating point · 491c33e9
      Reed Kotler authored
      Summary:
      start to do simple constants
      
      finish simplestore
      
      add test case
      
      format
      
      Merge branch 'master' into 1756_8
      
      Add basic functionality for assignment of ints. This creates a lot of core infrastructure in which to add, with little effort, quite a bit more to mips fast-isel
      
      Merge branch 'master' into 1756_8
      
      Add basic functionality for assignment of ints. This creates a lot of core infrastructure in which to add, with little effort, quite a bit more to mips fast-isel
      
      in progress
      
      finish integer materialize
      
      test cases
      
      test cases
      
      in progress
      
      Finish up fast-isel materialize for ints.
      
      Finish materialize for ints
      
      test cases
      
      simplestorei.ll
      
      Merge branch 'master' into 1756_8
      
      fix fp constants for fast-isel
      
      Merge branch '1758_1' of dmz-portal.mips.com:llvm into 1758_1
      
      in progress
      
      lastest for fp materialization
      
      clean up
      
      Merge branch 'master' into 1758_1
      
      formatting
      
      add test case
      
      finish test case
      
      Merge branch 'master' into 1758_2
      
      Test Plan:
      simplestore.ll
      
      simplestore.ll
      
      Reviewers: dsanders
      
      Reviewed By: dsanders
      
      Differential Revision: http://reviews.llvm.org/D3659
      
      llvm-svn: 210414
      491c33e9
    • Reed Kotler's avatar
      start to clean up buildMI calls in mips fast-isel · fb77bc98
      Reed Kotler authored
      Summary: Merge branch 'master' into 1758_6
      
      Test Plan:
      No functionality change. Run "make check" and run test-suite.
      Because our servers are not yet running again I have not yet run test-suite.
      I will further review myself before submission.
      
      Reviewers: dsanders
      
      Reviewed By: dsanders
      
      Differential Revision: http://reviews.llvm.org/D3819
      
      llvm-svn: 210413
      fb77bc98
    • Alp Toker's avatar
      Re-enable ARM ELF tests · 6de91b56
      Alp Toker authored
      r210408 inadvertently disabled them when X86 is not selected.
      
      llvm-svn: 210412
      6de91b56
    • Alp Toker's avatar
      Fix build when no native target is enabled · 7bfa48b1
      Alp Toker authored
      The JITTests and MCJITTests unit test targets require a native arch with JIT
      support, otherwise fail to link.
      
      llvm-svn: 210411
      7bfa48b1
    • Reed Kotler's avatar
      include MipsGenFastISel.inc · 9fe25f35
      Reed Kotler authored
      Summary:
      Included this file which is needed to enable tablegen generated functionality
      for fast mips-isel
      
      Test Plan:
      This has no visible functionality by itself but just adding the include
      file creates some issues so I have it as a separate patch.
      
      Reviewers: dsanders
      
      Reviewed By: dsanders
      
      Differential Revision: http://reviews.llvm.org/D3812
      
      llvm-svn: 210410
      9fe25f35
    • Saleem Abdulrasool's avatar
      test: add test case for SVN r210406 · f0806cd7
      Saleem Abdulrasool authored
      Add missing test case for constructor section selection.  Thanks David Blaikie!
      
      llvm-svn: 210409
      f0806cd7
    • Saleem Abdulrasool's avatar
      test: move some tests into ARM directory · 46f1d9fb
      Saleem Abdulrasool authored
      Rather than requiring ARM support for the ELF tests (which is odd), move the
      tests that require ARM into a subdirectory to use lit to disable them if the
      support is not present.  Play this game to prevent disabling the ELF tests on
      the Windows build bots as they have caught issues in the past with interactions
      between various platforms.
      
      llvm-svn: 210408
      46f1d9fb
    • Saleem Abdulrasool's avatar
      MC: make ELF .type handling more GNU AS compatible · 13b414a3
      Saleem Abdulrasool authored
      GAS documents the .type directive as having an optional comma following the key
      symbol name when using the STT_<TYPE_IN_UPPER_CASE> form.  However, it treats
      the comma as optional in all cases.  This makes the IAS support both forms of
      inputs.  Furthermore, the prefixed forms take either the upper case name or the
      lower case alias.
      
      The tests are split into two separate sets as the hash character serves as a
      comment character on x86, which is tested in the second set by using arm-elf
      which uses the at symbol as a comment character.
      
      llvm-svn: 210407
      13b414a3
    • Saleem Abdulrasool's avatar
      MC: fix ctor/dtor section for windows-itanium · ed7fc4b7
      Saleem Abdulrasool authored
      This adjusts the section setup for the windows-itanium environment.  This
      environment does not report to be a known windows msvc environment, even though
      it is (nearly) identical to the MSVC environment for C code.
      
      llvm-svn: 210406
      ed7fc4b7
    • Saleem Abdulrasool's avatar
      MC: whitespace, grouping for COFF section setup · a35f04aa
      Saleem Abdulrasool authored
      Add some whitespace, combine two sequential conditionals into a single one.
      Reformat some section definitions to maintain uniformity in the function.
      NFC.
      
      llvm-svn: 210405
      a35f04aa
    • Alp Toker's avatar
      DeclObjC: Fix comments about bad API · 84c42408
      Alp Toker authored
      What's going on here isn't overriding but rather the sketchy practice of member
      hiding (shadowing of base members).
      
      llvm-svn: 210404
      84c42408
    • Alp Toker's avatar
      Avoid dubious IdentifierInfo::getNameStart() uses · 541d5070
      Alp Toker authored
      These cases in particular were incurring an extra strlen() when we already knew
      the length. They appear to be leftovers from when the interfaces worked with C
      strings that have continued to compile due to the implicit StringRef ctor.
      
      llvm-svn: 210403
      541d5070
    • Alp Toker's avatar
      StringRefize TargetInfo::getABI() · 4925ba7f
      Alp Toker authored
      llvm-svn: 210402
      4925ba7f
    • Alp Toker's avatar
      Fix typos · 5c536394
      Alp Toker authored
      llvm-svn: 210401
      5c536394
    • Alp Toker's avatar
      Build fix: remove initializeJumpInstrTablesPass() call from LTO · 17dd8efe
      Alp Toker authored
      This was incurring an unsatisfied dependency on CodeGen from LTO breaking
      shared builds:
      
      Undefined symbols for architecture x86_64:
        "llvm::initializeJumpInstrTablesPass(llvm::PassRegistry&)", referenced from:
            llvm::LTOCodeGenerator::initializeLTOPasses() in LTOCodeGenerator.cpp.o
      ld: symbol(s) not found for architecture x86_64
      clang: error: linker command failed with exit code 1 (use -v to see invocation)
      
      Removed as a temporary measure pending feedback from the author.
      
      llvm-svn: 210400
      17dd8efe
    • Saleem Abdulrasool's avatar
      ARM: correct assertion for long-calls on WoA · 90386ad6
      Saleem Abdulrasool authored
      COFF/PE, so the relocation model is never static.  Loosen the assertion
      accordingly.  The relocation can still be emitted properly, as it will be
      converted to an IMAGE_REL_ARM_ADDR32 which will be resolved by the loader
      taking the base relocation into account.  This is necessary to permit the
      emission of long calls which can be controlled via the -mlong-calls option in
      the driver.
      
      llvm-svn: 210399
      90386ad6
    • Saleem Abdulrasool's avatar
      Driver: add -m{,no-}long-calls support · aea65e9b
      Saleem Abdulrasool authored
      This mirrors the GCC option for the ARM backend.  This option enables the
      backend option "-enable-arm-long-calls".  The default behaviour is that this is
      disabled due to the slight overhead of the generated calls.
      
      If the target of jumps are greater than 64M range of offset-based jumps, then
      the target address must be loaded into a register to make an indirect jump.  The
      backend support for this has been present, but was not previously controllable
      by the proper flag.
      
      llvm-svn: 210398
      aea65e9b
    • Saleem Abdulrasool's avatar
      tools: add a high level explanation for WoA EH data · c86b54c8
      Saleem Abdulrasool authored
      Add a brief explanation of the data section layout for the unwind data that the
      Windows on ARM EH models.  This is simply to provide a rough idea of the layout
      of the code involved in the decoding of the unwinding.  Details on the involved
      data structures are available in the associated support header.  The bulk of it
      is related to printing out the byte-code to help validate generation of WoA EH.
      
      No functional change.
      
      llvm-svn: 210397
      c86b54c8
  2. Jun 07, 2014
    • Peter Zotov's avatar
      [OCaml] Commit missing parts of r210395 · c86d1c1e
      Peter Zotov authored
      llvm-svn: 210396
      c86d1c1e
    • Peter Zotov's avatar
      [OCaml] Introduce an llmdkind abstract type. · 7ce15f76
      Peter Zotov authored
      Patch by Gabriel Radanne.
      
      While this commit technically breaks API, no code should have supplied
      the integer IDs directly, and thus no code should break.
      
      llvm-svn: 210395
      7ce15f76
    • Simon Atanasyan's avatar
    • Rafael Espindola's avatar
      Revert 209903 and 210040. · 4ba22f08
      Rafael Espindola authored
      The messages were
      
       "PR19753: Optimize comparisons with "ashr exact" of a constanst."
       "Added support to optimize comparisons with "lshr exact" of a constant."
      
      They were not correctly handling signed/unsigned operation differences,
      causing pr19958.
      
      llvm-svn: 210393
      4ba22f08
    • Arnold Schwaighofer's avatar
      Unbreak release builds. · 553aa7b5
      Arnold Schwaighofer authored
      This test case relies on basic block labels.
      
      llvm-svn: 210392
      553aa7b5
    • Bill Schmidt's avatar
      [PPC64LE] Implement little-endian semantics for vec_unpack[hl] · d7c53a91
      Bill Schmidt authored
      The PowerPC vector-unpack-high and vector-unpack-low instructions
      are defined architecturally with a big-endian bias, in that the vector
      element numbering is assumed to be "left to right" regardless of
      whether the processor is in big-endian or little-endian mode.  This
      effectively reverses the meaning of "high" and "low."  Such a
      definition is unnatural for little-endian code generation.
      
      To facilitate ease of porting, the vec_unpackh and vec_unpackl
      interfaces are designed to use natural element ordering, so that
      elements are numbered according to little-endian design principles
      when code is generated for a little-endian target.  The desired
      semantics can be achieved by using the opposite instruction for
      little-endian mode.  That is, when a call to vec_unpackh appears in
      the code, a vector-unpack-low is generated, and when a call to
      vec_unpackl appears in the code, a vector-unpack-high is generated.
      
      The correctness of this code is tested by the new unpack.c test
      added in a previous patch, as well as the modifications to
      builtins-ppc-altivec.c in the present patch.
      
      Note that these interfaces were originally incorrectly implemented
      when they take a vector pixel argument.  This patch corrects this
      implementation for both big- and little-endian code generation.
      
      llvm-svn: 210391
      d7c53a91
    • Andrew Trick's avatar
      Fix the MachineScheduler's logic for updating ready times for in-order. · 7f1ebbeb
      Andrew Trick authored
      Now the scheduler updates a node's ready time as soon as it is
      scheduled, before releasing dependent nodes. There was a reason I
      didn't do this initially but it no longer applies.
      
      A53 is in-order and was running into an issue where nodes where added
      to the readyQ too early. That's now fixed.
      
      This also makes it easier for custom scheduling strategies to build
      heuristics based on the actual cycles that the node was scheduled at.
      
      The only impact on OOO (sandybridge/cyclone) is that ready times will
      be slightly more accurate. I didn't measure any significant regressions.
      
      llvm-svn: 210390
      7f1ebbeb
    • Bill Schmidt's avatar
      [PPC64LE] Update test for vec_sum2s interface · 86f673a0
      Bill Schmidt authored
      Commit r210384 prematurely included changes to the little-endian
      implementation of the vec_sum2s interface.  This patch modifies
      test/CodeGen/builtins-ppc-altivec.c to test those changes.
      
      llvm-svn: 210389
      86f673a0
    • Nick Lewycky's avatar
    • Richard Trieu's avatar
      Fix my poor grammar from r210372 · 731b5019
      Richard Trieu authored
      llvm-svn: 210387
      731b5019
    • Eric Christopher's avatar
      Replace the use of TargetMachine with a tiny bool variable. · 28783da0
      Eric Christopher authored
      llvm-svn: 210386
      28783da0
    • Eric Christopher's avatar
      Remove all local variables from X86SelectionDAGInfo, the DAG has · e5add682
      Eric Christopher authored
      all of the ones we were stashing away on startup.
      
      llvm-svn: 210385
      e5add682
    • Bill Schmidt's avatar
      [PPC64LE] Update builtins-ppc-altivec.c for PPC64 and PPC64LE · 7f0a5c51
      Bill Schmidt authored
      The Altivec builtin test case test/CodeGen/builtins-ppc-altivec.c has
      always been executed only for 32-bit PowerPC.  These tests are equally
      valid for 64-bit PowerPC.  This patch updates the test to be run for
      three targets:  powerpc-unknown-unknown, powerpc64-unknown-unknown,
      and powerpc64le-unknown-unknown.  The expected code generation changes
      for some of the Altivec builtins for little endian, so this patch adds
      new CHECK-LE variants to the test for the powerpc64le target.
      
      These tests satisfy the testing requirements for some previous patches
      committed over the last couple of days for lib/Headers/altivec.h:
      r210279 for vec_perm, r210337 for vec_mul[eo], and r210340 for
      vec_pack.
      
      llvm-svn: 210384
      7f0a5c51
    • Saleem Abdulrasool's avatar
      ADT: introduce isWindowsItaniumEnvironment · c3610376
      Saleem Abdulrasool authored
      Add an isWindowsItaniumEnvironment function to Triple to mirror the other
      Windows environments.  This is simply a utility function to check if we are
      targeting windows-itanium rather than windows-msvc.
      
      llvm-svn: 210383
      c3610376
    • Reid Kleckner's avatar
      Delay lookup of simple default template arguments under -fms-compatibility · df6e4a06
      Reid Kleckner authored
      MSVC delays parsing of default arguments until instantiation.  If the
      default argument is never used, it is never parsed.  We don't model
      this.
      
      Instead, if lookup of a type name fails in a template argument context,
      we form a DependentNameType, which will be looked up at instantiation
      time.
      
      This fixes errors about 'CControlWinTraits' in atlwin.h.
      
      Reviewers: rsmith
      
      Differential Revision: http://reviews.llvm.org/D3995
      
      llvm-svn: 210382
      df6e4a06
    • Marshall Clow's avatar
      Testing infastructure: A template for char_traits where all the functions are... · 57e06dfb
      Marshall Clow authored
      Testing infastructure: A template for char_traits where all the functions are constexpr, and a comparison predicate which counts how many times it's been called.
      
      llvm-svn: 210381
      57e06dfb
    • Marshall Clow's avatar
      c3699147
    • David Blaikie's avatar
      DebugInfo: Use the scope of the function declaration, if any, to name a function in DWARF pubnames · 3dca5990
      David Blaikie authored
      This ensures that member functions, for example, are entered into
      pubnames with their fully qualified name, rather than inside the global
      namespace.
      
      llvm-svn: 210379
      3dca5990
    • David Blaikie's avatar
      DebugInfo: pubnames: include file-local (static or anonymous namespace)... · 553eb4a8
      David Blaikie authored
      DebugInfo: pubnames: include file-local (static or anonymous namespace) variables and anonymous namespaces themselves.
      
      Still some issues with name qualification, FIXMEs added to test cases
      and fixes will come next.
      
      llvm-svn: 210378
      553eb4a8
    • Warren Hunt's avatar
      [MS-ABI] Implement dynamic_cast · b57b4b09
      Warren Hunt authored
      This patch implements call lower from dynamic_cast to __RTDynamicCast 
      and __RTCastToVoid.  Test cases are included.  A feature of note is that 
      helper function getPolymorphicOffset is placed in such a way that it can 
      be used by EmitTypeid (to be implemented in a later patch) without being 
      moved.  Details are included as comments directly in the code.
      
      llvm-svn: 210377
      b57b4b09