1. Apr 04, 2014
    • Reid Kleckner's avatar
      -fms-extensions: Error out on #pragma init_seg · d3923aaa
      Reid Kleckner authored
      By ignoring this pragma with a warning, we're essentially miscompiling
      the user's program.  WebKit / Blink use this pragma to disable dynamic
      initialization and finalization of some static data, and running the
      dtors crashes the program.
      
      Error out for now, so that /fallback compiles the TU correctly with
      MSVC.  This pragma should be implemented some time this month, and we
      can remove this hack.
      
      llvm-svn: 205554
      d3923aaa
    • Tobias Grosser's avatar
      Note of last Polly phone call · d7c5e516
      Tobias Grosser authored
      llvm-svn: 205553
      d7c5e516
    • Rui Ueyama's avatar
      Remove "virtual" and add "override". · e8fa7c07
      Rui Ueyama authored
      Seems clang-modernize couldn't add "override" to nested classes, so
      doing it by hand. Also removed unused virtual member function that
      is not overriding anything, that seems to have been added by mistake.
      
      llvm-svn: 205552
      e8fa7c07
    • Eric Christopher's avatar
      Attempt to XFAIL this on mingw and cygwin hosts. The line table on · 5bdaea85
      Eric Christopher authored
      these is very much off and is more than just the branch
      from this bug incorrect:
      
      Address            Line   Column File   ISA Discriminator Flags
      ------------------ ------ ------ ------ --- ------------- -------------
      0x30830a0100000002      3      0      1   0             0  is_stmt
      0x30830a0100000008      3      0      1   0             0  is_stmt end_sequence
      
      llvm-svn: 205551
      5bdaea85
    • Rui Ueyama's avatar
      Remove "this->". · 2b2ac91f
      Rui Ueyama authored
      For most member function calls we do not use "this->" in this file.
      Remove the rest for consistency.
      
      llvm-svn: 205550
      2b2ac91f
    • Tobias Grosser's avatar
      Add a paragraph describing how to configure the python interpreter. · ca61be3a
      Tobias Grosser authored
      
      
      Contributed-by: default avatar <cib123@googlemail.com>
      llvm-svn: 205549
      ca61be3a
    • Roman Divacky's avatar
      Revert r205436: · 6150990d
      Roman Divacky authored
              Extend the SSE2 comment lexing to AVX2. Only 16byte align when not on AVX2.
      
              This provides some 3% speedup when preprocessing gcc.c as a single file.
      
      
      The patch is wrong, it always uses SSE2, and when I fix that there's no speedup
      at all. I am not sure where the 3% came from previously.
      
      --Thi lie, and those below, will be ignored--
      
      M    Lex/Lexer.cpp
      
      llvm-svn: 205548
      6150990d
    • Eli Bendersky's avatar
      Fix PR19270 - type mismatch caused by invalid optimization. · 9966b26d
      Eli Bendersky authored
      Patch by Jingyue Wu.
      
      llvm-svn: 205547
      9966b26d
    • Eric Christopher's avatar
      Loosen up check so that we can pass on platforms that generate · bc79fddb
      Eric Christopher authored
      slightly more verbose than needed line tables, e.g.:
      
      Address            Line   Column File   ISA Discriminator Flags
      ------------------ ------ ------ ------ --- ------------- -------------
      0x0000000000000000      1      0      1   0             0  is_stmt
      0x0000000000000000      1      0      1   0             0  is_stmt prologue_end
      0x0000000000000010      2      0      1   0             0  is_stmt
      0x0000000000000018      4      0      1   0             0  is_stmt
      
      these should probably be looked at, but it isn't affecting the correctness
      of the testcase.
      
      llvm-svn: 205546
      bc79fddb
    • Saleem Abdulrasool's avatar
      ARM: update even more tests · 717c9919
      Saleem Abdulrasool authored
      More updating of tests to be explicit about the target triple rather than
      relying on the default target triple supporting ARM mode.
      
      Indicate to lit that object emission is not yet available for Windows on ARM.
      
      llvm-svn: 205545
      717c9919
    • Jim Ingham's avatar
      Get "dis -c -s" working again. · 2f4693aa
      Jim Ingham authored
      pr19324
      
      llvm-svn: 205544
      2f4693aa
    • Faisal Vali's avatar
      Teach getTemplateInstantiationPattern to deal with generic lambdas. · b90b211e
      Faisal Vali authored
      No functionality change.
      
      When determining the pattern for instantiating a generic lambda call operator specialization - we must not go drilling down for the 'prototype' (i.e. as written) pattern - rather we must use our partially transformed  pattern (whose DeclRefExprs are wired correctly to any enclosing lambda's decls that should be mapped correctly in a local instantiation scope) that is the templated pattern of the specialization's primary template (even though the primary template might be instantiated from a 'prototype' member-template).  Previously, the drilling down was haltted by marking the instantiated-from primary template as a member-specialization (incorrectly). 
      
      This prompted Richard to remark (http://llvm-reviews.chandlerc.com/D1784?id=4687#inline-10272) 
      "It's a bit nasty to (essentially) set this bit incorrectly. Can you put the check into getTemplateInstantiationPattern instead?"
      
      In my reckless youth, I chose to ignore that comment.  With the passage of time, I have come to learn the value of bowing to the will of the angry Gods ;) 
      
      llvm-svn: 205543
      b90b211e
    • Dmitri Gribenko's avatar
      265f2f04
    • Saleem Abdulrasool's avatar
      ARM: fixup more tests to specify the target more explicitly · 7258735f
      Saleem Abdulrasool authored
      This changes the tests that were targeting ARM EABI to explicitly specify the
      environment rather than relying on the default.  This breaks with the new
      Windows on ARM support when running the tests on Windows where the default
      environment is no longer EABI.
      
      Take the opportunity to avoid a pointless redirect (helps when trying to debug
      with providing a command line invocation which can be copy and pasted) and
      removing a few greps in favour of FileCheck.
      
      llvm-svn: 205541
      7258735f
  2. Apr 03, 2014
    • Tim Northover's avatar
      ARM: tell LLVM about zext properties of ldrexb/ldrexh · 01b4aa94
      Tim Northover authored
      Implementing this via ComputeMaskedBits has two advantages:
        + It actually works. DAGISel doesn't deal with the chains properly
          in the previous pattern-based solution, so they never trigger.
        + The information can be used in other DAG combines, as well as the
          trivial "get rid of truncs". For example if the trunc is in a
          different basic block.
      
      rdar://problem/16227836
      
      llvm-svn: 205540
      01b4aa94
    • Ed Maste's avatar
      Add explict dependencies on swig .i files for cmake builds · 0dcccf7b
      Ed Maste authored
      llvm.org/pr19316
      
      llvm-svn: 205539
      0dcccf7b
    • Daniel Sanders's avatar
      [mips] Add negative tests confirm that supported ISA's don't allow... · a934837e
      Daniel Sanders authored
      [mips] Add negative tests confirm that supported ISA's don't allow instructions added in later ISA's
      
      Summary:
      test/MC/Mips/<isa1>/invalid-<isa2>.s
          Test that <isa1> does not support <isa2>'s instructions.
      test/MC/Mips/<isa1>/invalid-<isa2>-xfail.s
          Things that should be invalid but currently aren't. Will XPASS if any
          become invalid.
      
      Reviewers: matheusalmeida
      
      Reviewed By: matheusalmeida
      
      Differential Revision: http://llvm-reviews.chandlerc.com/D3262
      
      llvm-svn: 205538
      a934837e
    • Daniel Sanders's avatar
      [mips] Implement ehb, ssnop, and pause in assembler · 442f1a12
      Daniel Sanders authored
      Summary: Add negative tests for pause
      
      Reviewers: matheusalmeida
      
      Reviewed By: matheusalmeida
      
      Differential Revision: http://llvm-reviews.chandlerc.com/D3246
      
      llvm-svn: 205537
      442f1a12
    • Logan Chien's avatar
      Code cleanup (re-indent) · 749763ea
      Logan Chien authored
      llvm-svn: 205536
      749763ea
    • Tim Northover's avatar
      ARM: skip cmpxchg failure barrier if ordering is monotonic. · 70450c59
      Tim Northover authored
      The terminal barrier of a cmpxchg expansion will be either Acquire or
      SequentiallyConsistent. In either case it can be skipped if the
      operation has Monotonic requirements on failure.
      
      rdar://problem/15996804
      
      llvm-svn: 205535
      70450c59
    • Alexey Samsonov's avatar
      [TSan] Fix a rare deadlock on multithreaded fork. · 425314a6
      Alexey Samsonov authored
      If a multi-threaded program calls fork(), TSan ignores all memory accesses
      in the child to prevent deadlocks in TSan runtime. This is OK, as child is
      probably going to call exec() as soon as possible. However, a rare deadlocks
      could be caused by ThreadIgnoreBegin() function itself.
      
      ThreadIgnoreBegin() remembers the current stack trace and puts it into the
      StackDepot to report a warning later if a thread exited with ignores enabled.
      Using StackDepotPut in a child process is dangerous: it locks a mutex on
      a slow path, which could be already locked in a parent process.
      
      The fix is simple: just don't put current stack traces to StackDepot in
      ThreadIgnoreBegin() and ThreadIgnoreSyncBegin() functions if we're
      running after a multithreaded fork. We will not report any
      "thread exited with ignores enabled" errors in this case anyway.
      
      Submitting this without a testcase, as I believe the standalone reproducer
      is pretty hard to construct.
      
      llvm-svn: 205534
      425314a6
    • Samuel Benzaquen's avatar
      Revert "Add support for named values in the parser." · 5548eadb
      Samuel Benzaquen authored
      This was submitted before it was ready.
      
      This reverts commit 62060a01e095cf35eb9ca42a333752d12714f35c.
      
      llvm-svn: 205533
      5548eadb
    • Zoran Jovanovic's avatar
      Implementation of 16-bit microMIPS instructions MFHI and MFLO. · cabf0f41
      Zoran Jovanovic authored
      Differential Revision: http://llvm-reviews.chandlerc.com/D3141
      
      llvm-svn: 205532
      cabf0f41
    • Alexey Samsonov's avatar
      [TSan] Fix a typo ThreadIgnoreSyncEnd. Found by inspection · b4525218
      Alexey Samsonov authored
      llvm-svn: 205531
      b4525218
    • Daniel Sanders's avatar
      [mips] Add initial (experimental) MIPS-IV support. · f7b32291
      Daniel Sanders authored
      Summary:
      Adds the 'mips4' processor and a simple test of the ELF e_flags.
      
      Patch by David Chisnall
      His work was sponsored by: DARPA, AFRL
      
      I made one small change to the testcase so that it uses
      mips64-unknown-linux instead of mips4-unknown-linux.
      
      This patch indirectly adds FeatureCondMov to FeatureMips64. This is ok
      because it's supposed to be there anyway and it turns out that
      FeatureCondMov is not a predicate of any instructions at the moment
      (this is a bug that hasn't been noticed because there are no targets
      without the conditional move instructions yet).
      
      CC: theraven
      
      Differential Revision: http://llvm-reviews.chandlerc.com/D3244
      
      llvm-svn: 205530
      f7b32291
    • Eric Christopher's avatar
      Fix for PR 19261: · bfb38bad
      Eric Christopher authored
      llc doesn't generate nodes for unconditional fall-through branches for targets
      without FastISel implementation (X86 has it, but can be disabled by
      "-fast-isel=false") in SelectionDAGBuilder::visitBr().
      
      So for line 4 in the following testcase
      
      1: void foo(int i){
      2:   switch(i){
      3:   default:
      4:     break;
      5:   }
      6:   return;
      7: }
      
      there is no corresponding line in .debug_line section, and a debugger
      cannot set a breakpoint at line 4.
      
      Fix this by always emitting a branch when we're not optimizing and add a
      testcase to ensure that there's code on every line we'd want to break.
      
      Patch by Daniil Fukalov.
      
      llvm-svn: 205529
      bfb38bad
    • Zoran Jovanovic's avatar
      MicroMIPS specific little endian fixup data byte ordering. · 842f20ef
      Zoran Jovanovic authored
      Differential Revision: http://llvm-reviews.chandlerc.com/D3245
      
      llvm-svn: 205528
      842f20ef
    • Daniel Jasper's avatar
      clang-format: Prefer an additional line-break over hanging indent. · 5c33265c
      Daniel Jasper authored
      Don't allow the RHS of an operator to be split over multiple
      lines unless there is a line-break right after the operator.
      
      Before:
        if (aaaa && bbbbb || // break
                        cccc) {
        }
      
      After:
        if (aaaa &&
            bbbbb || // break
                cccc) {
        }
      
      In most cases, this seems to increase readability.
      
      llvm-svn: 205527
      5c33265c
    • Daniel Jasper's avatar
      x · 2b7556ec
      Daniel Jasper authored
      llvm-svn: 205526
      2b7556ec
    • Tim Northover's avatar
      ARM: expand atomic ldrex/strex loops in IR · c882eb07
      Tim Northover authored
      The previous situation where ATOMIC_LOAD_WHATEVER nodes were expanded
      at MachineInstr emission time had grown to be extremely large and
      involved, to account for the subtly different code needed for the
      various flavours (8/16/32/64 bit, cmpxchg/add/minmax).
      
      Moving this transformation into the IR clears up the code
      substantially, and makes future optimisations much easier:
      
      1. an atomicrmw followed by using the *new* value can be more
         efficient. As an IR pass, simple CSE could handle this
         efficiently.
      2. Making use of cmpxchg success/failure orderings only has to be done
         in one (simpler) place.
      3. The common "cmpxchg; did we store?" idiom can be exposed to
         optimisation.
      
      I intend to gradually improve this situation within the ARM backend
      and make sure there are no hidden issues before moving the code out
      into CodeGen to be shared with (at least ARM64/AArch64, though I think
      PPC & Mips could benefit too).
      
      llvm-svn: 205525
      c882eb07
    • Stepan Dyatkovskiy's avatar
      PR19320: · 6207a4da
      Stepan Dyatkovskiy authored
      The trouble as in ARMAsmParser, in ParseInstruction method. It assumes that ARM::R12 + 1 == ARM::SP.
      It is wrong, since ARM::<Register> codes are generated by tablegen and actually could be any random numbers.
      
      llvm-svn: 205524
      6207a4da
    • Silviu Baranga's avatar
      [ARM] When generating a vpaddl node the input lane type is not always the type of the · a3106e68
      Silviu Baranga authored
      add operation since extract_vector_elt can perform an extend operation. Get the input lane
      type from the vector on which we're performing the vpaddl operation on and extend or
      truncate it to the output type of the original add node.
      
      llvm-svn: 205523
      a3106e68
    • Sasa Stankovic's avatar
      [mips] Extend MipsMCExpr class to handle %higher(sym1 - sym2 + const) and · 06c47803
      Sasa Stankovic authored
      %highest(sym1 - sym2 + const) relocations. Remove "ABS_" from VK_Mips_HI
      and VK_Mips_LO enums in MipsMCExpr, to be consistent with VK_Mips_HIGHER
      and VK_Mips_HIGHEST.
      
      This change also deletes test file test/MC/Mips/higher_highest.ll and moves
      its CHECK's to the new test file test/MC/Mips/higher-highest-addressing.s.
      The deleted file tests that R_MIPS_HIGHER and R_MIPS_HIGHEST relocations are
      emitted in the .o file. Since it uses -force-mips-long-branch option, it was
      created when MipsLongBranch's implementation was emitting R_MIPS_HIGHER and
      R_MIPS_HIGHEST relocations in the .o file. It was disabled when MipsLongBranch
      started to directly calculate offsets.
      
      Differential Revision: http://llvm-reviews.chandlerc.com/D3230
      
      llvm-svn: 205522
      06c47803
    • Stephen Canon's avatar
      Improved semantics for implicit scalar -> extvector conversions. · 3ba640d7
      Stephen Canon authored
      llvm-svn: 205521
      3ba640d7
    • Tim Northover's avatar
      ARM64: add regression test for r205519. · 5b06f275
      Tim Northover authored
      llvm-svn: 205520
      5b06f275
    • Tim Northover's avatar
      ARM64: always use i64 for the RHS of shift operations · 2ad88d3a
      Tim Northover authored
      Switching between i32 and i64 based on the LHS type is a good idea in
      theory, but pre-legalisation uses i64 regardless of our choice,
      leading to potential ISel errors.
      
      Should fix PR19294.
      
      llvm-svn: 205519
      2ad88d3a
    • Tim Northover's avatar
      RTTI Uniqueness: remove __name_for_load function. · caccac10
      Tim Northover authored
      It's identical to name() these days. (At one point it avoided masking
      of the RTTI uniqueness bit because ARM64 ignored it architecturally,
      but no longer).
      
      llvm-svn: 205518
      caccac10
    • Daniel Jasper's avatar
      clang-format: Understand that "auto" is a type. · cc7bf7fd
      Daniel Jasper authored
      Before:
        MACRO(auto * a);
      
      After:
        MACRO(auto *a);
      
      llvm-svn: 205517
      cc7bf7fd
    • Oliver Stannard's avatar
      ARM: Use __STACK_LIMIT symbol for segmented stacks · 92e0fc04
      Oliver Stannard authored
      We cannot use STACK_LIMIT, as it is not reserved for the compiler
      by the C spec.
      
      llvm-svn: 205516
      92e0fc04
    • Andrew Trick's avatar
      Stack map docs. Remove some stray markup. · da97149f
      Andrew Trick authored
      llvm-svn: 205515
      da97149f