Skip to content
  1. Feb 01, 2012
    • Chad Rosier's avatar
      Tidy up. · e273cb08
      Chad Rosier authored
      llvm-svn: 149521
      e273cb08
    • Howard Hinnant's avatar
      Teach exception_cleanup_func about dependent exceptions. · d0bfbb33
      Howard Hinnant authored
      llvm-svn: 149520
      d0bfbb33
    • Johnny Chen's avatar
      Add @expectedFailure decorators. · 3cfb9c67
      Johnny Chen authored
      llvm-svn: 149519
      3cfb9c67
    • Howard Hinnant's avatar
      Treat all exceptions except that the ones that this library throws as foreign.... · 8aa78517
      Howard Hinnant authored
      Treat all exceptions except that the ones that this library throws as foreign.  Even other C++ exceptions.
      
      llvm-svn: 149518
      8aa78517
    • Douglas Gregor's avatar
      6b8ef34f
    • Douglas Gregor's avatar
      Introduce the lambda scope before determining explicit captures, which · cdd11d4e
      Douglas Gregor authored
      cleans up and improves a few things:
        - We get rid of the ugly dance of computing all of the captures in
        data structures that clone those of CapturingScopeInfo, centralizing
        the logic for accessing/updating these data structures
        - We re-use the existing capture logic for 'this', which actually
        works now.
      
      Cleaned up some diagnostic wording in minor ways as well.
      
      llvm-svn: 149516
      cdd11d4e
    • Howard Hinnant's avatar
      Nothing but polishing comments. · 62efe0b0
      Howard Hinnant authored
      llvm-svn: 149515
      62efe0b0
    • Anna Zaks's avatar
      [analyzer] Testing: add 2 new checkers to the buildbot script. · 97981bde
      Anna Zaks authored
      llvm-svn: 149514
      97981bde
    • Howard Hinnant's avatar
      Move an error detector to a better place. · 4ca103d1
      Howard Hinnant authored
      llvm-svn: 149513
      4ca103d1
    • NAKAMURA Takumi's avatar
      test/Driver/target.c: Relax expression for "gcc.exe" on win32. · 2235e6da
      NAKAMURA Takumi authored
      llvm-svn: 149510
      2235e6da
    • Dylan Noblesmith's avatar
      cmake: make BUILD_SHARED_LIBS a visible option · af9be0b6
      Dylan Noblesmith authored
      It could only be specified on the commandline, and wouldn't show
      up as an option in the GUI or when invoked via `cmake -i` at all.
      
      This also tells CMake that it's a BOOL, rather than "UNINITIALIZED".
      
      llvm-svn: 149506
      af9be0b6
    • NAKAMURA Takumi's avatar
      test/CodeGen/X86/avx-minmax.ll: Relax expressions for Win32 targets. YMM... · fe8186f8
      NAKAMURA Takumi authored
      test/CodeGen/X86/avx-minmax.ll: Relax expressions for Win32 targets. YMM arguments are passed as indirect on Win32 x64.
      
      llvm-svn: 149505
      fe8186f8
    • Dylan Noblesmith's avatar
      include clang's config.h unconditionally · 86780e90
      Dylan Noblesmith authored
      And remove HAVE_CLANG_CONFIG_H, now that the header is generated
      in the autoconf build, too. (clang r149497 / llvm r149498)
      
      Also include the config.h header after all other headers, per
      the LLVM coding standards.
      
      It also turns out WindowsToolChain.cpp wasn't using the config
      header at all, so that include's just deleted now.
      
      llvm-svn: 149504
      86780e90
    • Tobias Grosser's avatar
      ScopInfo: Simplify some isl code · c327932c
      Tobias Grosser authored
      llvm-svn: 149503
      c327932c
    • Tobias Grosser's avatar
      CodeGeneration: Rephrase comment slightly · 5772e65b
      Tobias Grosser authored
      llvm-svn: 149502
      5772e65b
    • Tobias Grosser's avatar
      CodeGeneration: Order includes alphabetically · bda1f8f8
      Tobias Grosser authored
      llvm-svn: 149501
      bda1f8f8
    • NAKAMURA Takumi's avatar
      test/Modules/compiler_builtins.m: Appease Cygwin to add -D__need_wint_t. · d8f100f3
      NAKAMURA Takumi authored
      On Cygwin, at first, <stddef.h> is included without __need_wint_t.
      Next, <stddef.h> is included with __need_wint_t, though Modules feature would not process <stddef.h> twice.
      Then, wint_t is not found in system headers.
      
      llvm-svn: 149500
      d8f100f3
    • NAKAMURA Takumi's avatar
    • Dylan Noblesmith's avatar
      autoconf: generate clang's private config.h header · 57f439cb
      Dylan Noblesmith authored
      The CMake build already generated one. Follows clang r149497.
      
      This brings us one step closer to compiling and configuring clang
      separately from LLVM using the autoconf build, too.
      
      (I lack the right version of autoconf et al. to regen, but it
      was a simple change, so I just updated configure manually.)
      
      llvm-svn: 149498
      57f439cb
    • Dylan Noblesmith's avatar
      autoconf: add private config.h to clang · 96f0db0f
      Dylan Noblesmith authored
      This already exists in the CMake build, which is part of what makes
      building clang separately from llvm via cmake possible. This cleans up
      that discrepancy between the build systems (and sets the groundwork
      for configuring clang separately, too).
      
      llvm-svn: 149497
      96f0db0f
    • Dylan Noblesmith's avatar
      cmake: don't install config.h · c20ccdd7
      Dylan Noblesmith authored
      This header is private and shouldn't be used by clients.
      
      llvm-svn: 149496
      c20ccdd7
    • Dylan Noblesmith's avatar
      Frontend: fix comment typos · 9759e9b1
      Dylan Noblesmith authored
      llvm-svn: 149495
      9759e9b1
    • Elena Demikhovsky's avatar
      Passing AVX 256-bit structures in Win64 was wrong. · 824eed70
      Elena Demikhovsky authored
      Fixed Win64 calling conventions.
      
      llvm-svn: 149494
      824eed70
    • Elena Demikhovsky's avatar
      Shortened code in shuffle masks · 34cca175
      Elena Demikhovsky authored
      llvm-svn: 149493
      34cca175
    • Alexander Potapenko's avatar
      Disable wrapping memcpy() on Mac OS Lion, where it · c97434ec
      Alexander Potapenko authored
      actually falls back to memmove.
      In this case we still need to initialize real_memcpy, so we set it to
      real_memmove
      We check for MACOS_VERSION_SNOW_LEOPARD, because currently only Snow
      Leopard and Lion are supported.
      
      llvm-svn: 149492
      c97434ec
    • Alexander Potapenko's avatar
      Disables testing memcpy() on Mac OS 10.7, · f504602a
      Alexander Potapenko authored
      where memcpy() in fact aliases memmove() and thus calling it with
      overlapping parameters is not an error.
      
      llvm-svn: 149491
      f504602a
    • Richard Smith's avatar
      constexpr: check for overflow in pointer subtraction. · 1b470417
      Richard Smith authored
      This is a mess. According to the C++11 standard, pointer subtraction only has
      undefined behavior if the difference of the array indices does not fit into a
      ptrdiff_t.
      
      However, common implementations effectively perform a char* subtraction first,
      and then divide the result by the element size, which can cause overflows in
      some cases. Those cases are not considered to be undefined behavior by this
      change; perhaps they should be.
      
      llvm-svn: 149490
      1b470417
    • Greg Clayton's avatar
      Added many more python convenience accessors: · 6b2bd939
      Greg Clayton authored
      You can now access a frame in a thread using:
      
      lldb.SBThread.frame[int] -> lldb.SBFrame object for a frame in a thread
      
      Where "int" is an integer index. You can also access a list object with all of
      the frames using:
      
      lldb.SBThread.frames => list() of lldb.SBFrame objects
      
      All SB objects that give out SBAddress objects have properties named "addr"
      
      lldb.SBInstructionList now has the following convenience accessors for len() and
      instruction access using an index:
      
      insts = lldb.frame.function.instructions
      for idx in range(len(insts)):
          print insts[idx]
          
      Instruction lists can also lookup an isntruction using a lldb.SBAddress as the key:
      
      pc_inst = lldb.frame.function.instructions[lldb.frame.addr]
      
      lldb.SBProcess now exposes:
      
      lldb.SBProcess.is_alive => BOOL Check if a process is exists and is alive
      lldb.SBProcess.is_running => BOOL check if a process is running (or stepping):
      lldb.SBProcess.is_running => BOOL check if a process is currently stopped or crashed:
      lldb.SBProcess.thread[int] => lldb.SBThreads for a given "int" zero based index
      lldb.SBProcess.threads => list() containing all lldb.SBThread objects in a process
      
      SBInstruction now exposes:
      lldb.SBInstruction.mnemonic => python string for instruction mnemonic
      lldb.SBInstruction.operands => python string for instruction operands
      lldb.SBInstruction.command => python string for instruction comment
      
      SBModule now exposes:
      
      lldb.SBModule.uuid => uuid.UUID(), an UUID object from the "uuid" python module
      lldb.SBModule.symbol[int] => lldb.Symbol, lookup symbol by zero based index
      lldb.SBModule.symbol[str] => list() of lldb.Symbol objects that match "str"
      lldb.SBModule.symbol[re] => list() of lldb.Symbol objecxts that match the regex
      lldb.SBModule.symbols => list() of all symbols in a module
      
        
      SBAddress objects can now access the current load address with the "lldb.SBAddress.load_addr"
      property. The current "lldb.target" will be used to try and resolve the load address.
      
      Load addresses can also be set using this accessor:
      
      addr = lldb.SBAddress()
      addd.load_addr = 0x123023
      
      Then you can check the section and offset to see if the address got resolved.
      
      SBTarget now exposes:
      
      lldb.SBTarget.module[int] => lldb.SBModule from zero based module index
      lldb.SBTarget.module[str] => lldb.SBModule by basename or fullpath or uuid string
      lldb.SBTarget.module[uuid.UUID()] => lldb.SBModule whose UUID matches
      lldb.SBTarget.module[re] => list() of lldb.SBModule objects that match the regex
      lldb.SBTarget.modules => list() of all lldb.SBModule objects in the target
      
      SBSymbol now exposes:
      
      lldb.SBSymbol.name => python string for demangled symbol name
      lldb.SBSymbol.mangled => python string for mangled symbol name or None if there is none
      lldb.SBSymbol.type => lldb.eSymbolType enum value
      lldb.SBSymbol.addr => SBAddress object that represents the start address for this symbol (if there is one)
      lldb.SBSymbol.end_addr => SBAddress for the end address of the symbol  (if there is one)
      lldb.SBSymbol.prologue_size => pythin int containing The size of the prologue in bytes
      lldb.SBSymbol.instructions => SBInstructionList containing all instructions for this symbol
      
      SBFunction now also has these new properties in addition to what is already has:
      lldb.SBFunction.addr => SBAddress object that represents the start address for this function
      lldb.SBFunction.end_addr => SBAddress for the end address of the function
      lldb.SBFunction.instructions => SBInstructionList containing all instructions for this function
      
      SBFrame now exposes the SBAddress for the frame:
      lldb.SBFrame.addr => SBAddress which is the section offset address for the current frame PC
      
      These are all in addition to what was already added. Documentation and website
      updates coming soon.
      
      llvm-svn: 149489
      6b2bd939
    • Elena Demikhovsky's avatar
      Optimization for "truncate" operation on AVX. · 0e48c70b
      Elena Demikhovsky authored
      Truncating v4i64 -> v4i32 and v8i32 -> v8i16 may be done with set of shuffles.
      
      llvm-svn: 149485
      0e48c70b
    • Stepan Dyatkovskiy's avatar
      Compatability fix for SwitchInst refactoring. · 5fecf544
      Stepan Dyatkovskiy authored
      The purpose of refactoring is to hide operand roles from SwitchInst user (programmer). If you want to play with operands directly, probably you will need lower level methods than SwitchInst ones (TerminatorInst or may be User). After this patch we can reorganize SwitchInst operands and successors as we want.
      
      What was done:
      
      1. Changed semantics of index inside the getCaseValue method:
      getCaseValue(0) means "get first case", not a condition. Use getCondition() if you want to resolve the condition. I propose don't mix SwitchInst case indexing with low level indexing (TI successors indexing, User's operands indexing), since it may be dangerous.
      2. By the same reason findCaseValue(ConstantInt*) returns actual number of case value. 0 means first case, not default. If there is no case with given value, ErrorIndex will returned.
      3. Added getCaseSuccessor method. I propose to avoid usage of TerminatorInst::getSuccessor if you want to resolve case successor BB. Use getCaseSuccessor instead, since internal SwitchInst organization of operands/successors is hidden and may be changed in any moment.
      4. Added resolveSuccessorIndex and resolveCaseIndex. The main purpose of these methods is to see how case successors are really mapped in TerminatorInst.
      4.1 "resolveSuccessorIndex" was created if you need to level down from SwitchInst to TerminatorInst. It returns TerminatorInst's successor index for given case successor.
      4.2 "resolveCaseIndex" converts low level successors index to case index that curresponds to the given successor.
      
      Note: There are also related compatability fix patches for dragonegg, klee, llvm-gcc-4.0, llvm-gcc-4.2, safecode, clang.
      llvm-svn: 149482
      5fecf544
    • Stepan Dyatkovskiy's avatar
      SwitchInst refactoring. · 513aaa56
      Stepan Dyatkovskiy authored
      The purpose of refactoring is to hide operand roles from SwitchInst user (programmer). If you want to play with operands directly, probably you will need lower level methods than SwitchInst ones (TerminatorInst or may be User). After this patch we can reorganize SwitchInst operands and successors as we want.
      
      What was done:
      
      1. Changed semantics of index inside the getCaseValue method:
      getCaseValue(0) means "get first case", not a condition. Use getCondition() if you want to resolve the condition. I propose don't mix SwitchInst case indexing with low level indexing (TI successors indexing, User's operands indexing), since it may be dangerous.
      2. By the same reason findCaseValue(ConstantInt*) returns actual number of case value. 0 means first case, not default. If there is no case with given value, ErrorIndex will returned.
      3. Added getCaseSuccessor method. I propose to avoid usage of TerminatorInst::getSuccessor if you want to resolve case successor BB. Use getCaseSuccessor instead, since internal SwitchInst organization of operands/successors is hidden and may be changed in any moment.
      4. Added resolveSuccessorIndex and resolveCaseIndex. The main purpose of these methods is to see how case successors are really mapped in TerminatorInst.
      4.1 "resolveSuccessorIndex" was created if you need to level down from SwitchInst to TerminatorInst. It returns TerminatorInst's successor index for given case successor.
      4.2 "resolveCaseIndex" converts low level successors index to case index that curresponds to the given successor.
      
      Note: There are also related compatability fix patches for dragonegg, klee, llvm-gcc-4.0, llvm-gcc-4.2, safecode, clang.
      llvm-svn: 149481
      513aaa56
    • Andrew Trick's avatar
      Add pass printer passes in the right place. · cbc845f9
      Andrew Trick authored
      The pass pointer should never be referenced after sending it to
      schedulePass(), which may delete the pass. To fix this bug I had to
      clean up the design leading to more goodness.
      
      You may notice now that any non-analysis pass is printed. So things like loop-simplify and lcssa show up, while target lib, target data, alias analysis do not show up. Normally, analysis don't mutate the IR, but you can now check this by using both -print-after and -print-before. The effects of analysis will now show up in between the two.
      
      The llc path is still in bad shape. But I'll be improving it in my next checkin. Meanwhile, print-machineinstrs still works the same way. With print-before/after, many llc passes that were not printed before now are, some of these should be converted to analysis. A few very important passes, isel and scheduler, are not properly initialized, so not printed.
      
      llvm-svn: 149480
      cbc845f9
    • Andrew Trick's avatar
      whitespace · 96c21592
      Andrew Trick authored
      llvm-svn: 149479
      96c21592
    • Craig Topper's avatar
    • Argyrios Kyrtzidis's avatar
      Revert r149363 which was part a series of commits that were reverted in llvm · a11b35a9
      Argyrios Kyrtzidis authored
      commit 149470. This fixes test/CodeGen/PR3589-freestanding-libcalls.c.
      
      Original log:
      
          ConstantArray::get() (for strings) is going away, use
          ConstantDataArray::getString instead.
      
          Many instances of ConstantArray::get() could be moved to
          use more efficient ConstantDataArray methods that avoid a ton
          of intermediate Constant*'s for each element (e.g.
          GetConstantArrayFromStringLiteral).  I don't plan on doing this
          in the short-term though.
      
      llvm-svn: 149477
      a11b35a9
    • Argyrios Kyrtzidis's avatar
    • NAKAMURA Takumi's avatar
    • Eric Christopher's avatar
      For pass-by-value record arguments to functions emit a forward decl · ee4ab939
      Eric Christopher authored
      instead of the entire class definition.
      
      llvm-svn: 149474
      ee4ab939
    • Richard Smith's avatar
      c8042323
    • Hal Finkel's avatar
      A few of the changes suggested in code review (by Nick Lewycky) · 8a3aebe5
      Hal Finkel authored
      llvm-svn: 149472
      8a3aebe5
Loading