1. Aug 11, 2023
    • Aaron Ballman's avatar
      [C2x] Support -std=c23 and -std=gnu23 · 13629b14
      Aaron Ballman authored
      C2x was finalized at the June 2023 WG14 meeting. The DIS is out for
      balloting and the comment period for that closes later this year/early
      next year. While that does leave an opportunity for more changes to the
      standard during the DIS ballot resolution process, only editorial
      changes are anticipated and as a result, the C committee considers C2x
      to be final. The committee took a straw poll on what we'd prefer the
      informal name of the standard be, and we decided it should be called
      C23 regardless of what year ISO publishes it.
      
      However, because the final publication is not out, this patch does not
      add the language standard alias for the -std=iso9899:<year> spelling of
      the standard mode; that will be added once ISO finally publishes the
      document and the year chosen will match the publication date.
      
      This also changes the value of __STDC_VERSION__ from the placeholder
      value 202000L to the final value 202311L.
      
      Subsequent patches will start renaming things from c2x to c23, cleaning
      up documentation, etc.
      
      Differential Revision: https://reviews.llvm.org/D157606
      13629b14
    • Valentin Clement's avatar
      [flang][openacc][NFC] Rename createRegisterFunc and refactor · 69a337e2
      Valentin Clement authored
      Depends on D157530
      
      Reviewed By: razvanlupusoru
      
      Differential Revision: https://reviews.llvm.org/D157555
      69a337e2
    • Valentin Clement's avatar
      [flang][openacc] Set exit op for device_resident to acc.delete · c54bb3d2
      Valentin Clement authored
      The exit operation for the declare device_resident in function/subroutine
      is set to delete. Make is consistent and set it also for global declare.
      
      Reviewed By: razvanlupusoru
      
      Differential Revision: https://reviews.llvm.org/D157537
      c54bb3d2
    • Valentin Clement's avatar
      [flang][openacc] Generate declare pre/post dealloc function · 672a2c4a
      Valentin Clement authored
      Generate the function dealing with the action on deallocation (pre/post) of
      a declare variable.
      
      Reviewed By: razvanlupusoru
      
      Differential Revision: https://reviews.llvm.org/D157530
      672a2c4a
    • Volodymyr Sapsai's avatar
      [modules] Fix error about the same module being defined in different .pcm... · 97dfaf4c
      Volodymyr Sapsai authored
      [modules] Fix error about the same module being defined in different .pcm files when using VFS overlays.
      
      Fix errors like
      > module 'MultiPath' is defined in both 'path/to/modules.cache/3JR48BPRU7BCG/MultiPath-1352QHUF8RNMU.pcm' and 'path/to/modules.cache/3JR48BPRU7BCG/MultiPath-20HNSLLIUDDV1.pcm'
      
      To avoid building extra identical modules `-ivfsoverlay` option is not a
      part of the hash like "/3JR48BPRU7BCG/". And it is build system's
      responsibility to provide `-ivfsoverlay` options that don't cause
      observable differences.  We also need to make sure the hash like
      "-1352QHUF8RNMU" is not affected by `-ivfsoverlay`. As this hash is
      defined by the module map path, use the path prior to any VFS
      remappings.
      
      rdar://111921464
      
      Differential Revision: https://reviews.llvm.org/D156749
      97dfaf4c
    • Elliot Whitney's avatar
      [flang] Add two new semantics tests for `critical-construct` · d0abde03
      Elliot Whitney authored
      Add two new semantics tests for `critical-construct` that test
      addition standard conforming and non stardard conforming statements
      
      Reviewed By: ktras
      
      Differential Revision: https://reviews.llvm.org/D157521
      d0abde03
    • Jan Svoboda's avatar
      [clang][modules] Respect "-fmodule-name=" when serializing included files into a PCH · bbdb0c7e
      Jan Svoboda authored
      Clang writes the set of textually included files into AST files, so that importers know to avoid including those files again and instead deserialize their contents from the AST on-demand.
      
      Logic for determining the set of included files files only considers headers that are either non-modular or that are modular but with `HeaderFileInfo::isCompilingModuleHeader` set. Logic for computing that bit is different than the one that determines whether to include a header textually with the "-fmodule-name=Mod" option. That can lead to header from module "Mod" being included textually in a PCH, but be omitted in the serialized set of included files. This can then allow such header to be textually included from importer of the PCH, wreaking havoc.
      
      This patch fixes that by aligning the logic for computing `HeaderFileInfo::isCompilingModuleHeader` with the logic for deciding whether to include modular header textually.
      
      As far as I can tell, this bug has been in Clang for forever. It got accidentally "fixed" by D114095 (that changed the logic for determining the set of included files) and got broken again in D155131 (which is essentially a revert of the former).
      
      rdar://113520515
      
      Reviewed By: benlangmuir
      
      Differential Revision: https://reviews.llvm.org/D157559
      bbdb0c7e
    • Alina Sbirlea's avatar
      89fa0dd1
    • Justin Bogner's avatar
      [Driver][DXC] Treat stdin as HLSL · 0d459b71
      Justin Bogner authored
      Differential Revision: https://reviews.llvm.org/D157562
      0d459b71
    • fridtjof's avatar
      [libclang] Expose arguments of clang::annotate · 5aa06b18
      fridtjof authored
      This enables easy consumption of arbitrary data added
      to this annotation in addition to the annotation category,
      which was already exposed.
      
      Differential Revision: https://reviews.llvm.org/D151373
      5aa06b18
    • Craig Topper's avatar
      [RISCV] Stop performFP_TO_INTCombine from folding with ISD::FRINT. · 2df9328f
      Craig Topper authored
      FRINT was added to matchRoundingOp after this function was written.
      So FRINT was not tested originally.
      
      For vectors, folding this causes us to create a CSR swap that tries
      to write 7 to FRM. This is an illegal value and will cause the CSR
      write to fail.
      
      While this might be a legal fold we could do, I'm disabling it for
      now so we can backport to LLVM 17 with the least risk.
      
      Differential Revision: https://reviews.llvm.org/D157583
      2df9328f
    • Florian Hahn's avatar
      [docs] Graduate VectorizationPlan.rst from proposal. · d32e68ae
      Florian Hahn authored
      VPlan has become an integral part of the inner loop vectorizer pipeline
      that has been actively developed over the previous years. Let's move
      VectorizationPlan.rst from the proposal stage to bring the docs in line
      and to avoid confusion when reading the docs.
      
      Reviewed By: rengolin
      
      Differential Revision: https://reviews.llvm.org/D157593
      d32e68ae
  2. Aug 10, 2023