[all-commits] [llvm/llvm-project] c54122: [NFC][mlir][AsmPrinter] Don't compute resourceStr ...
Xiang Li via All-commits
all-commits at lists.llvm.org
Fri May 2 07:41:36 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: c54122fe538f0edbf5a7a6f2a62bf4973a00262c
https://github.com/llvm/llvm-project/commit/c54122fe538f0edbf5a7a6f2a62bf4973a00262c
Author: Xiang Li <python3kgae at outlook.com>
Date: 2025-05-02 (Fri, 02 May 2025)
Changed paths:
M mlir/lib/IR/AsmPrinter.cpp
M mlir/test/IR/pretty-resources-print.mlir
Log Message:
-----------
[NFC][mlir][AsmPrinter] Don't compute resourceStr when --mlir-elide-resource-strings-if-larger=0 (#138275)
When skipping the printing of large DenseResourceElementsAttr with
--mlir-elide-resource-strings-if-larger,
we need to compute resourceStr to check if the string is small enough to
print.
With --mlir-elide-resource-strings-if-larger set to 0, nothing should be
printed, but we still compute the size.
This change will allow an early return when
--mlir-elide-resource-strings-if-larger=0, making the print process
faster.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list