[all-commits] [llvm/llvm-project] 6ab2bc: [mlir:Bytecode] Add support for encoding resources
River Riddle via All-commits
all-commits at lists.llvm.org
Tue Sep 13 11:39:50 PDT 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 6ab2bcffe45e660a68493e6a7cd04b6f05da51dc
https://github.com/llvm/llvm-project/commit/6ab2bcffe45e660a68493e6a7cd04b6f05da51dc
Author: River Riddle <riddleriver at gmail.com>
Date: 2022-09-13 (Tue, 13 Sep 2022)
Changed paths:
M mlir/docs/BytecodeFormat.md
M mlir/include/mlir/Bytecode/BytecodeImplementation.h
M mlir/include/mlir/Bytecode/BytecodeWriter.h
M mlir/include/mlir/IR/AsmState.h
M mlir/lib/AsmParser/Parser.cpp
M mlir/lib/Bytecode/Encoding.h
M mlir/lib/Bytecode/Reader/BytecodeReader.cpp
M mlir/lib/Bytecode/Writer/BytecodeWriter.cpp
M mlir/lib/Bytecode/Writer/IRNumbering.cpp
M mlir/lib/Bytecode/Writer/IRNumbering.h
M mlir/lib/IR/AsmPrinter.cpp
M mlir/lib/IR/BuiltinDialectBytecode.cpp
M mlir/test/Bytecode/invalid/invalid-structure.mlir
A mlir/test/Bytecode/resources.mlir
Log Message:
-----------
[mlir:Bytecode] Add support for encoding resources
Resources are encoded in two separate sections similarly to
attributes/types, one for the actual data and one for the data
offsets. Unlike other sections, the resource sections are optional
given that in many cases they won't be present. For testing,
bytecode serialization is added for DenseResourceElementsAttr.
Differential Revision: https://reviews.llvm.org/D132729
Commit: 34300ee3697e32926e998d1036925d0f59ffae02
https://github.com/llvm/llvm-project/commit/34300ee3697e32926e998d1036925d0f59ffae02
Author: River Riddle <riddleriver at gmail.com>
Date: 2022-09-13 (Tue, 13 Sep 2022)
Changed paths:
M mlir/include/mlir/Bytecode/BytecodeWriter.h
M mlir/include/mlir/IR/AsmState.h
M mlir/lib/Bytecode/Writer/BytecodeWriter.cpp
M mlir/lib/IR/AsmPrinter.cpp
M mlir/lib/Tools/mlir-lsp-server/MLIRServer.cpp
M mlir/lib/Tools/mlir-opt/MlirOptMain.cpp
M mlir/test/IR/file-metadata-resources.mlir
M mlir/test/IR/invalid-file-metadata.mlir
Log Message:
-----------
[mlir] Add fallback support for parsing/printing unknown external resources
This is necessary/useful for building generic tooling that can roundtrip external
resources without needing to explicitly handle them. For example, this allows
for viewing the resources encoded within a bytecode file without having to
explicitly know how to process them (e.g. making it easier to interact with a
reproducer encoded in bytecode).
Differential Revision: https://reviews.llvm.org/D133460
Commit: 9e0900cbf1cbc2b8366df66a562bf031c8a2b8db
https://github.com/llvm/llvm-project/commit/9e0900cbf1cbc2b8366df66a562bf031c8a2b8db
Author: River Riddle <riddleriver at gmail.com>
Date: 2022-09-13 (Tue, 13 Sep 2022)
Changed paths:
M mlir/lib/IR/AttributeDetail.h
M mlir/unittests/IR/AttributeTest.cpp
Log Message:
-----------
[mlir] Fix DenseElementsAttr treatment of bool splat of "true"
Boolean splats currently can't roundtrip via the "raw" DenseElementsAttr
API. This is because internally we treat true splats in some cases as "1"(one bit set)
and in other cases as "0xFF"(all bits set). This commit cleans up this handling to
consistently use 0xFF (all bits set) as the value for a splat of true.
Differential Revision: https://reviews.llvm.org/D133743
Commit: 5fb1bbe6d49e08af5d47ce4d9498d650e6628dad
https://github.com/llvm/llvm-project/commit/5fb1bbe6d49e08af5d47ce4d9498d650e6628dad
Author: River Riddle <riddleriver at gmail.com>
Date: 2022-09-13 (Tue, 13 Sep 2022)
Changed paths:
M mlir/include/mlir/Bytecode/BytecodeImplementation.h
M mlir/lib/Bytecode/Reader/BytecodeReader.cpp
M mlir/lib/Bytecode/Writer/BytecodeWriter.cpp
M mlir/lib/Bytecode/Writer/IRNumbering.cpp
M mlir/lib/IR/BuiltinDialectBytecode.cpp
M mlir/test/Dialect/Builtin/Bytecode/attrs.mlir
Log Message:
-----------
[mlir] Add bytecode encodings for the builtin ElementsAttr attributes
This adds bytecode support for DenseArrayAttr, DenseIntOrFpElementsAttr,
DenseStringElementsAttr, and SparseElementsAttr.
Differential Revision: https://reviews.llvm.org/D133744
Compare: https://github.com/llvm/llvm-project/compare/e166d2e00bc0...5fb1bbe6d49e
More information about the All-commits
mailing list