Skip to content
  1. Dec 12, 2012
  2. Dec 11, 2012
  3. Dec 10, 2012
  4. Dec 09, 2012
    • Aaron Ballman's avatar
    • Chandler Carruth's avatar
      6bb5c06e
    • Chandler Carruth's avatar
      Add a test case that I've been using to clarify the bitfield layout for · e8f7a959
      Chandler Carruth authored
      both LE and BE targets.
      
      AFAICT, Clang get's this correct for PPC64. I've compared it to GCC 4.8
      output for PPC64 (thanks Roman!) and to my limited ability to read power
      assembly, it looks functionally equivalent. It would be really good to
      fill in the assertions on this test case for x86-32, PPC32, ARM, etc.,
      but I've reached the limit of my time and energy... Hopefully other
      folks can chip in as it would be good to have this in place to test any
      subsequent changes.
      
      To those who care about PPC64 performance, a side note: there is some
      *obnoxiously* bad code generated for these test cases. It would be worth
      someone's time to sit down and teach the PPC backend to pattern match
      these IR constructs better. It appears that things like '(shr %foo,
      <imm>)' turn into 'rldicl R, R, 64-<imm>, <imm>' or some such. They
      don't even get combined with other 'rldicl' instructions *immediately
      adjacent*. I'll add a couple of these patterns to the README, but
      I think it would be better to look at all the patterns produced by this
      and other bitfield access code, and systematically build up a collection
      of patterns that efficiently reduce them to the minimal code.
      
      llvm-svn: 169693
      e8f7a959
    • Chandler Carruth's avatar
      Fix the bitfield record layout in codegen for big endian targets. · fd8eca20
      Chandler Carruth authored
      This was an egregious bug due to the several iterations of refactorings
      that took place. Size no longer meant what it original did by the time
      I finished, but this line of code never got updated. Unfortunately we
      had essentially zero tests for this in the regression test suite. =[
      
      I've added a PPC64 run over the bitfield test case I've been primarily
      using. I'm still looking at adding more tests and making sure this is
      the *correct* bitfield access code on PPC64 linux, but it looks pretty
      close to me, and it is *worlds* better than before this patch as it no
      longer asserts! =] More commits to follow with at least additional tests
      and maybe more fixes.
      
      Sorry for the long breakage due to this....
      
      llvm-svn: 169691
      fd8eca20
    • Richard Smith's avatar
      Fix overload resolution for the initialization of a multi-dimensional · 0db1ea5f
      Richard Smith authored
      array from a braced-init-list. There seems to be a core wording wart
      here (it suggests we should be testing whether the elements of the init
      list are implicitly convertible to the array element type, not whether
      there is an implicit conversion sequence) but our prior behavior appears
      to be a bug, not a deliberate effort to implement the standard as written.
      
      llvm-svn: 169690
      0db1ea5f
    • Richard Smith's avatar
      PR14550: If a system header contains a bogus constexpr function definition, · f86b5dc7
      Richard Smith authored
      don't mark the function as invalid, since we suppress the error.
      
      llvm-svn: 169689
      f86b5dc7
    • Richard Smith's avatar
  5. Dec 08, 2012
    • Benjamin Kramer's avatar
      Escape % in the TextDiagnosticBuffer so they aren't interpreted twice when fed... · 2fec65d3
      Benjamin Kramer authored
      Escape % in the TextDiagnosticBuffer so they aren't interpreted twice when fed into the diagnostic formatting machinery again.
      
      Fixes PR14543.
      
      llvm-svn: 169677
      2fec65d3
    • David Chisnall's avatar
      long double should be 64 bits on FreeBSD/MIPS64. It possibly should be on · a87d8599
      David Chisnall authored
      Linux too, as I think we inherited it from there.  The ABI spec says 128-bit,
      although I think SGI's compiler on IRIX may be the only thing ever to support
      this.
      
      llvm-svn: 169674
      a87d8599
    • Richard Smith's avatar
      Finish implementing 'selected constructor' rules for triviality in C++11. In · 6b02d46d
      Richard Smith authored
      the cases where we can't determine whether special members would be trivial
      while building the class, we eagerly declare those special members. The impact
      of this is bounded, since it does not trigger implicit declarations of special
      members in classes which merely *use* those classes.
      
      In order to determine whether we need to apply this rule, we also need to
      eagerly declare move operations and destructors in cases where they might be
      deleted. If a move operation were supposed to be deleted, it would instead
      be suppressed, and we could need overload resolution to determine if we fall
      back to a trivial copy operation. If a destructor were implicitly deleted,
      it would cause the move constructor of any derived classes to be suppressed.
      
      As discussed on cxx-abi-dev, C++11's selected constructor rules are also
      retroactively applied as a defect resolution in C++03 mode, in order to
      identify that class B has a non-trivial copy constructor (since it calls
      A's constructor template, not A's copy constructor):
      
      struct A { template<typename T> A(T &); };
      struct B { mutable A a; };
      
      llvm-svn: 169673
      6b02d46d
    • DeLesley Hutchins's avatar
      0cfa1a5a
    • Richard Smith's avatar
      Properly compute triviality for explicitly-defaulted or deleted special members. · 92f241f1
      Richard Smith authored
      Remove pre-standard restriction on explicitly-defaulted copy constructors with
      'incorrect' parameter types, and instead just make those special members
      non-trivial as the standard requires.
      
      This required making CXXRecordDecl correctly handle classes which have both a
      trivial and a non-trivial special member of the same kind.
      
      This also fixes PR13217 by reimplementing DiagnoseNontrivial in terms of the
      new triviality computation technology.
      
      llvm-svn: 169667
      92f241f1
Loading