SuccessChanges

Summary

  1. [JumpThreading] Add a test for D85023; NFC (details)
  2. [JumpThreading] Consider freeze as a zero-cost instruction (details)
  3. [llvm-rc] Allow string table values split into multiple string literals (details)
Commit 3401f9706be14f9c103542c8b6034a1126b9859e by aqjune
[JumpThreading] Add a test for D85023; NFC
The file was addedllvm/test/Transforms/JumpThreading/thread-two-bbs-threshold.ll
Commit e0d99e9aaf51dac0555655cbf17909377ed37a27 by aqjune
[JumpThreading] Consider freeze as a zero-cost instruction

This is a simple patch that makes freeze as a zero-cost instruction, as bitcast already is.

Reviewed By: efriedma

Differential Revision: https://reviews.llvm.org/D85023
The file was modifiedllvm/test/Transforms/JumpThreading/thread-two-bbs-threshold.ll
The file was modifiedllvm/lib/Transforms/Scalar/JumpThreading.cpp
Commit b989fcbae6f179ad887d19ceef83ace1c00b87cc by martin
[llvm-rc] Allow string table values split into multiple string literals

This can practically easily be a product of combining strings with
macros in resource files.

This fixes https://github.com/mstorsjo/llvm-mingw/issues/140.

As string literals within llvm-rc are handled as StringRefs, each
referencing an uninterpreted slice of the input file, with actual
interpretation of the input string (codepage handling, unescaping etc)
done only right before writing them out to disk, it's hard to
concatenate them other than just bundling them up in a vector,
without rearchitecting a large part of llvm-rc.

This matches how the same already is supported in VersionInfoValue,
with a std::vector<IntOrString> Values.

MS rc.exe only supports concatenated string literals in version info
values (already supported), string tables (implemented in this patch)
and user data resources (easily implemented in a separate patch, but
hasn't been requested by any end user yet), while GNU windres supports
string immediates split into multiple strings anywhere (e.g. like
(100 ICON "myicon" ".ico"). Not sure if concatenation in other
statements actually is used in the wild though, in resource files
normally built by GNU windres.

Differential Revision: https://reviews.llvm.org/D85183
The file was modifiedllvm/tools/llvm-rc/ResourceScriptParser.cpp
The file was modifiedllvm/tools/llvm-rc/ResourceScriptStmt.h
The file was modifiedllvm/test/tools/llvm-rc/Inputs/tag-stringtable-basic.rc
The file was modifiedllvm/tools/llvm-rc/ResourceFileWriter.cpp
The file was modifiedllvm/tools/llvm-rc/ResourceFileWriter.h
The file was modifiedllvm/tools/llvm-rc/ResourceScriptStmt.cpp