Skip to content
  1. Feb 12, 2013
  2. Feb 11, 2013
  3. Jan 02, 2013
    • Chandler Carruth's avatar
      Move all of the header files which are involved in modelling the LLVM IR · 9fb823bb
      Chandler Carruth authored
      into their new header subdirectory: include/llvm/IR. This matches the
      directory structure of lib, and begins to correct a long standing point
      of file layout clutter in LLVM.
      
      There are still more header files to move here, but I wanted to handle
      them in separate commits to make tracking what files make sense at each
      layer easier.
      
      The only really questionable files here are the target intrinsic
      tablegen files. But that's a battle I'd rather not fight today.
      
      I've updated both CMake and Makefile build systems (I think, and my
      tests think, but I may have missed something).
      
      I've also re-sorted the includes throughout the project. I'll be
      committing updates to Clang, DragonEgg, and Polly momentarily.
      
      llvm-svn: 171366
      9fb823bb
  4. Dec 18, 2012
    • Jakob Stoklund Olesen's avatar
      Tighten up the splice() API for bundled instructions. · 78eaf05f
      Jakob Stoklund Olesen authored
      Remove the instr_iterator versions of the splice() functions. It doesn't
      seem useful to be able to splice sequences of instructions that don't
      consist of full bundles.
      
      The normal splice functions that take MBB::iterator arguments are not
      changed, and they can move whole bundles around without any problems.
      
      llvm-svn: 170456
      78eaf05f
    • Jakob Stoklund Olesen's avatar
      Tighten the insert() API for bundled instructions. · 422e07b0
      Jakob Stoklund Olesen authored
      The normal insert() function takes an MBB::iterator position, and
      inserts a stand-alone MachineInstr as before.
      
      The insert() function that takes an MBB::instr_iterator position can
      insert instructions inside a bundle, and will now update the bundle
      flags correctly when that happens.
      
      When the insert position is between two bundles, it is unclear whether
      the instruction should be appended to the previous bundle, prepended to
      the next bundle, or stand on its own. The MBB::insert() function doesn't
      bundle the instruction in that case, use the MIBundleBuilder class for
      that.
      
      llvm-svn: 170437
      422e07b0
    • Jakob Stoklund Olesen's avatar
      Tighten up the erase/remove API for bundled instructions. · ccfb5fb4
      Jakob Stoklund Olesen authored
      Most code is oblivious to bundles and uses the MBB::iterator which only
      visits whole bundles. MBB::erase() operates on whole bundles at a time
      as before.
      
      MBB::remove() now refuses to remove bundled instructions. It is not safe
      to remove all instructions in a bundle without deleting them since there
      is no way of returning pointers to all the removed instructions.
      
      MBB::remove_instr() and MBB::erase_instr() will now update bundle flags
      correctly, lifting individual instructions out of bundles while leaving
      the remaining bundle intact.
      
      The MachineInstr convenience functions are updated so
      
        eraseFromParent() erases a whole bundle as before
        eraseFromBundle() erases a single instruction, leaving the rest of its bundle.
        removeFromParent() refuses to operate on bundled instructions, and
        removeFromBundle() lifts a single instruction out of its bundle.
      
      These functions will no longer accidentally split or coalesce bundles -
      bundle flags are updated to preserve the existing bundling, and explicit
      bundleWith* / unbundleFrom* functions should be used to change the
      instruction bundling.
      
      This API update is still a work in progress. I am going to update APIs
      first so they maintain bundle flags automatically when possible. Then
      I'll add stricter verification of the bundle flags.
      
      llvm-svn: 170384
      ccfb5fb4
  5. Dec 03, 2012
    • Chandler Carruth's avatar
      Use the new script to sort the includes of every file under lib. · ed0881b2
      Chandler Carruth authored
      Sooooo many of these had incorrect or strange main module includes.
      I have manually inspected all of these, and fixed the main module
      include to be the nearest plausible thing I could find. If you own or
      care about any of these source files, I encourage you to take some time
      and check that these edits were sensible. I can't have broken anything
      (I strictly added headers, and reordered them, never removed), but they
      may not be the headers you'd really like to identify as containing the
      API being implemented.
      
      Many forward declarations and missing includes were added to a header
      files to allow them to parse cleanly when included first. The main
      module rule does in fact have its merits. =]
      
      llvm-svn: 169131
      ed0881b2
  6. Nov 20, 2012
  7. Oct 26, 2012
  8. Oct 08, 2012
  9. Sep 12, 2012
    • James Molloy's avatar
      Add a function computeRegisterLiveness() to MachineBasicBlock. This uses... · c747cdae
      James Molloy authored
      Add a function computeRegisterLiveness() to MachineBasicBlock. This uses analyzePhysReg() from r163694 to heuristically try and determine the liveness state of a physical register upon arrival at a particular instruction in a block.
      
      The search for liveness is clipped to a specific number of instructions around the target MachineInstr, in order to avoid degenerating into an O(N^2) algorithm. It tries to use various clues about how instructions around (both before and after) a given MachineInstr use that register, to determine its state at the MachineInstr.
      
      llvm-svn: 163695
      c747cdae
    • Manman Ren's avatar
      Release build: guard dump functions with · 19f49ac6
      Manman Ren authored
      "#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)"
      
      No functional change. Update r163339.
      
      llvm-svn: 163653
      19f49ac6
  10. Sep 06, 2012
  11. Aug 22, 2012
  12. Aug 21, 2012
    • Jakob Stoklund Olesen's avatar
      Fix a quadratic algorithm in MachineBranchProbabilityInfo. · 6bae2a57
      Jakob Stoklund Olesen authored
      The getSumForBlock function was quadratic in the number of successors
      because getSuccWeight would perform a linear search for an already known
      iterator.
      
      This patch was originally committed as r161460, but reverted again
      because of assertion failures. Now that duplicate Machine CFG edges have
      been eliminated, this works properly.
      
      llvm-svn: 162233
      6bae2a57
  13. Aug 14, 2012
  14. Aug 10, 2012
    • Jakob Stoklund Olesen's avatar
      Update edge weights correctly in replaceSuccessor(). · 8c28ac9e
      Jakob Stoklund Olesen authored
      When replacing Old with New, it can happen that New is already a
      successor. Add the old and new edge weights instead of creating a
      duplicate edge.
      
      llvm-svn: 161653
      8c28ac9e
    • Jakob Stoklund Olesen's avatar
      Move use list management into MachineRegisterInfo. · c4102d49
      Jakob Stoklund Olesen authored
      Register MachineOperands are kept in linked lists accessible via MRI's
      reg_iterator interfaces. The linked list management was handled partly
      by MachineOperand methods, partly by MRI methods.
      
      Move all of the list management into MRI, delete
      MO::AddRegOperandToRegInfo() and MO::RemoveRegOperandFromRegInfo().
      
      Be more explicit about handling the cases where an MRI pointer isn't
      available.
      
      llvm-svn: 161632
      c4102d49
  15. Aug 08, 2012
  16. Jul 30, 2012
  17. Jul 19, 2012
  18. Jun 15, 2012
  19. Apr 24, 2012
  20. Apr 17, 2012
    • Chandler Carruth's avatar
      Fix updateTerminator to be resiliant to degenerate terminators where · 1f5580b6
      Chandler Carruth authored
      both fallthrough and a conditional branch target the same successor.
      Gracefully delete the conditional branch and introduce any unconditional
      branch needed to reach the actual successor. This fixes memory
      corruption in 2009-06-15-RegScavengerAssert.ll and possibly other tests.
      
      Also, while I'm here fix a latent bug I spotted by inspection. I never
      applied the same fundamental fix to this fallthrough successor finding
      logic that I did to the logic used when there are no conditional
      branches. As a consequence it would have selected landing pads had they
      be aligned in just the right way here. I don't have a test case as
      I spotted this by inspection, and the previous time I found this
      required have of TableGen's source code to produce it. =/ I hate backend
      bugs. ;]
      
      Thanks to Jim Grosbach for helping me reason through this and reviewing
      the fix.
      
      llvm-svn: 154867
      1f5580b6
  21. Mar 28, 2012
  22. Mar 07, 2012
  23. Feb 10, 2012
  24. Feb 09, 2012
  25. Jan 26, 2012
  26. Dec 20, 2011
  27. Dec 14, 2011
    • Evan Cheng's avatar
      - Add MachineInstrBundle.h and MachineInstrBundle.cpp. This includes a function · 7fae11b2
      Evan Cheng authored
        to finalize MI bundles (i.e. add BUNDLE instruction and computing register def
        and use lists of the BUNDLE instruction) and a pass to unpack bundles.
      - Teach more of MachineBasic and MachineInstr methods to be bundle aware.
      - Switch Thumb2 IT block to MI bundles and delete the hazard recognizer hack to
        prevent IT blocks from being broken apart.
      
      llvm-svn: 146542
      7fae11b2
  28. Dec 07, 2011
    • Evan Cheng's avatar
      Add bundle aware API for querying instruction properties and switch the code · 7f8e563a
      Evan Cheng authored
      generator to it. For non-bundle instructions, these behave exactly the same
      as the MC layer API.
      
      For properties like mayLoad / mayStore, look into the bundle and if any of the
      bundled instructions has the property it would return true.
      For properties like isPredicable, only return true if *all* of the bundled
      instructions have the property.
      For properties like canFoldAsLoad, isCompare, conservatively return false for
      bundles.
      
      llvm-svn: 146026
      7f8e563a
  29. Dec 06, 2011
Loading